Skip to content

Commit

Permalink
pbr: simplify imports
Browse files Browse the repository at this point in the history
  • Loading branch information
cart committed Jul 17, 2020
1 parent e2d2b41 commit 2a6e75a
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 5 deletions.
4 changes: 4 additions & 0 deletions crates/bevy_input/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ pub mod system;

pub use input::*;

pub mod prelude {
pub use crate::{keyboard::KeyCode, mouse::MouseButton, Input};
}

use bevy_app::prelude::*;
use keyboard::{keyboard_input_system, KeyCode, KeyboardInput, KeyboardInputState};
use mouse::{
Expand Down
7 changes: 5 additions & 2 deletions crates/bevy_pbr/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ pub mod light;
pub mod material;
pub mod nodes;
pub mod pipelines;
pub mod render_graph;

mod forward_pbr_render_graph;
pub use forward_pbr_render_graph::*;
pub mod prelude {
pub use crate::{entity::*, light::Light, material::StandardMaterial};
}

use bevy_app::prelude::*;
use bevy_asset::AddAsset;
Expand All @@ -14,6 +16,7 @@ use bevy_render::{render_graph::RenderGraph, shader};
use bevy_type_registry::RegisterType;
use light::Light;
use material::StandardMaterial;
use render_graph::ForwardPbrRenderGraphBuilder;

/// NOTE: this isn't PBR yet. consider this name "aspirational" :)
#[derive(Default)]
Expand Down
2 changes: 1 addition & 1 deletion crates/bevy_pbr/src/nodes/lights_node.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use crate::{
light::{Light, LightRaw},
uniform,
render_graph::uniform,
};
use bevy_core::{AsBytes, Byteable};
use bevy_ecs::{Commands, IntoQuerySystem, Local, Query, Res, ResMut, Resources, System, World};
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions src/prelude.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ pub use crate::{
audio::prelude::*,
core::prelude::*,
ecs::prelude::*,
input::{keyboard::KeyCode, mouse::MouseButton, Input},
input::prelude::*,
math::prelude::*,
pbr::{entity::*, light::Light, material::StandardMaterial},
pbr::prelude::*,
property::{DynamicProperties, Properties, PropertiesVal, Property, PropertyVal},
render::prelude::*,
scene::{Scene, SceneSpawner},
Expand Down

0 comments on commit 2a6e75a

Please sign in to comment.