Struct rin_scene::scene::DeferredScene[][src]

pub struct DeferredScene { /* fields omitted */ }

Implementations

impl DeferredScene[src]

pub fn event_stream(&mut self) -> StreamRc<'static, Event>[src]

pub fn priority_stream(&mut self, priority: usize) -> StreamRc<'static, Event>[src]

pub fn set_non_attended(
    &mut self,
    priority: usize,
    non_attended: StreamRc<'static, Event>
)
[src]

pub fn send_stream<T: Clone + Debug + 'static>(
    &self
) -> (Sender<T>, Stream<'static, T>)
[src]

pub fn add_resource<T: Send + 'static>(&mut self, resource: T)[src]

Add a new resource

pub fn add_resource_thread_local<T: 'static>(&mut self, resource: T)[src]

Add a new resource that can’t be sent across threads

pub fn add_resource_as_trait<T, U: ?Sized, F, FMut>(
    &mut self,
    resource: (T, F, FMut)
) where
    T: 'static + Send,
    U: 'static + Send,
    F: Fn(&T) -> &U + 'static,
    FMut: Fn(&mut T) -> &mut U + 'static, 
[src]

Add a new resource accessible as a trait

pub fn add_resource_as_trait_thread_local<T, U: ?Sized, F, FMut>(
    &mut self,
    resource: (T, F, FMut)
) where
    T: 'static,
    U: 'static,
    F: Fn(&T) -> &U + 'static,
    FMut: Fn(&mut T) -> &mut U + 'static, 
[src]

Add a new thread local resource accessible as a trait

pub fn new_entity(&mut self) -> EntityBuilder<'_>[src]

pub fn add_system<S>(&mut self, system: S) -> &mut DeferredScene where
    S: System + 'static, 
[src]

Adds a Send System that will be run in the order it was added.

Send systems will run in parallel with other Send systems and with thread local systems added in between barriers.

pub fn add_system_once<S>(&mut self, system: S) -> &mut DeferredScene where
    S: SystemOnce + 'static, 
[src]

Adds a SendOnce System that will be run only once in the order it was added.

SendOnce systems will run in parallel with other Send systems and with thread local systems added in between barriers.

pub fn add_system_with_data<S, D>(
    &mut self,
    system: S,
    data: D
) -> &mut DeferredScene where
    S: FnMut(&mut D, Entities<'_>, Resources<'_>) + Send + 'static,
    D: Send + 'static, 
[src]

pub fn add_system_thread_local<S>(&mut self, system: S) -> &mut DeferredScene where
    S: SystemThreadLocal + 'static, 
[src]

Adds a non Send System that will be run in the order it was added.

SystemThreadLocal will always run in the main thread but can run in parallel with Send systems.

pub fn add_system_once_thread_local<S>(
    &mut self,
    system: S
) -> &mut DeferredScene where
    S: SystemOnceThreadLocal + 'static, 
[src]

Adds a non Send System that will be run in the order it was added.

SystemThreadLocal will always run in the main thread but can run in parallel with Send systems.

pub fn add_system_thread_local_with_data<S, D>(
    &mut self,
    system: S,
    data: D
) -> &mut DeferredScene where
    S: FnMut(&mut D, EntitiesThreadLocal<'_>, ResourcesThreadLocal<'_>) + 'static,
    D: 'static, 
[src]

pub fn add_creation_system<S>(&mut self, system: S) -> &mut DeferredScene where
    S: CreationSystem + 'static, 
[src]

Adds a CreationSystem that will be run in the order it was added.

CreationSystems run alone with no other system running in parallel.

pub fn add_debug_system<S>(&mut self, system: S) -> &mut DeferredScene where
    S: SystemDebug + 'static, 
[src]

Adds a SystemDebug that will be run in the order it was added.

SystemDebug run alone with no other system running in parallel.

pub fn add_system_with<S>(&mut self, system: S) -> SystemBuilder<'_, '_, S> where
    S: System + 'static, 
[src]

Adds a Send System with a Builder that allows to set some of the system properties like the name it’ll show up with in stats, or run conditions.

Send systems will run in parallel with other Send systems and with thread local systems added in between barriers.

pub fn add_system_thread_local_with<S>(
    &mut self,
    system: S
) -> SystemBuilderThreadLocal<'_, '_, S> where
    S: SystemThreadLocal + 'static, 
[src]

Adds a SystemThreadLocal with a Builder that allows to set some of the system properties like the name it’ll show up with in stats, if it has gpu stats or it’s run conditions.

SystemThreadLocal will always run in the main thread but can run in parallel with Send systems.

pub fn add_creation_system_with<S>(
    &mut self,
    system: S
) -> SystemBuilderCreation<'_, '_, S> where
    S: CreationSystem + 'static, 
[src]

Adds a CreationSystem with a Builder that allows to set some of the system properties like the name it’ll show up with in stats, if it has gpu stats or it’s run conditions.

CreationSystems run alone with no other system running in parallel.

pub fn add_update_system<U>(&mut self, system: U) -> &mut DeferredScene where
    U: UpdateSystem + 'static, 
[src]

pub fn add_update_system_thread_local<U>(
    &mut self,
    system: U
) -> &mut DeferredScene where
    U: UpdateSystemThreadLocal + 'static, 
[src]

pub fn add_render_system<R>(&mut self, system: R) -> &mut DeferredScene where
    R: RenderSystem + 'static, 
[src]

pub fn add_barrier<B: Barrier + 'static>(&mut self) -> &mut DeferredScene[src]

Delimits all the systems that will run in parallel.

Only systems between barriers (or creation and debug systems) will run in parallel with each other.

Barriers allow to create groups of systems that run in parallel including thread local systems that run one by one in the main thread but in parallel with Send systems.

pub fn register_material<M: FullMaterial + 'static>(
    &mut self,
    name: &str,
    material: M
) -> MaterialRef
[src]

Register a new material

Takes ownership of the passed material and returns a handle to it that can be used to set it as a model material

pub fn register_shadow_material<M: FullMaterial + 'static>(
    &mut self,
    name: &str,
    material: M
) -> ShadowMaterialRef
[src]

Register a new material

Takes ownership of the passed material and returns a handle to it that can be used to set it as a model material

pub fn find_material(&self, name: &str) -> Option<MaterialRef>[src]

Find a material by name if it exists

pub fn register_texture(&mut self, texture: Texture) -> TextureRef[src]

Register a texture to be used when setting up materials

pub fn register_texture_from_data_format<T: 'static>(
    &mut self,
    format: LoadDataFormat,
    creation_flags: TextureCreationFlags,
    data: &[T]
) -> Result<TextureRef, Error>
[src]

Create a texture and register it from the image pixels and a format specification

pub fn register_cubemap(&mut self, cubemap: CubeMap) -> CubemapRef[src]

pub fn register_image<I: Image + Clone>(
    &mut self,
    img: &I,
    creation_flags: TextureCreationFlags
) -> Result<TextureRef, Error>
[src]

Create and register a texture from a loaded image

pub fn register_named_texture_from_data_format<T: 'static>(
    &mut self,
    name: &str,
    creation_flags: TextureCreationFlags,
    format: LoadDataFormat,
    data: &[T]
) -> Result<TextureRef, Error>
[src]

Create a texture and register it with a name from the image pixels and a format specification

pub fn register_named_image<I: Image + Clone>(
    &mut self,
    name: &str,
    img: &I,
    creation_flags: TextureCreationFlags
) -> Result<TextureRef, Error>
[src]

Create and register a texture with a name from a loaded image

pub fn register_sampler(&mut self, sampler: Sampler) -> SamplerRef[src]

Register a texture sampler (a texture + parameters of how it has to be used)

pub fn register_named_sampler(
    &mut self,
    name: &str,
    sampler: Sampler
) -> SamplerRef
[src]

Register a texture sampler with a name (a texture + parameters of how it has to be used)

pub fn find_texture(&self, name: &str) -> Option<TextureRef>[src]

Find a texture by it’s name

pub fn find_cubemap(&self, name: &str) -> Option<CubemapRef>[src]

Find a texture by it’s name

pub fn find_sampler(&self, name: &str) -> Option<SamplerRef>[src]

Find a texture by it’s name

pub fn load_image<P>(
    &mut self,
    path: P,
    flags: TextureCreationFlags
) -> Result<TextureRef> where
    P: AsRef<Path>, 
[src]

pub fn load_cubemap<P>(
    &mut self,
    path: P,
    flags: TextureCreationFlags
) -> Result<CubemapRef> where
    P: AsRef<Path>, 
[src]

pub fn load_equirectangular_cubemap<P>(
    &mut self,
    path: P,
    flags: TextureCreationFlags,
    color_format: ColorFormat
) -> Result<CubemapRef> where
    P: AsRef<Path>, 
[src]

pub fn load_equirectangular_levels_cubemap<P>(
    &mut self,
    paths: &[P],
    flags: TextureCreationFlags,
    color_format: ColorFormat
) -> Result<CubemapRef> where
    P: AsRef<Path>, 
[src]

pub fn register_vertex_type<T>(&mut self) where
    T: 'static + VertexFormat + Send + Clone + Copy + Debug
[src]

Explicitly register a vertex type

Vertex types are usually registered the first time we add a Geometry of that vertex type to the scene using register_mesh but in some special cases we might want to add geometries directly to an entity. In those cases it’s necesary to call this method in order to register the corresponding components and create the renderer systems that allow to render this type of geometry

pub fn register_mesh<T>(&mut self, geom: Mesh<T>) -> GeometryRef where
    T: 'static + VertexFormat + Send + Clone + Copy + Debug
[src]

pub fn register_named_mesh<T>(
    &mut self,
    geom: Mesh<T>,
    name: &str
) -> GeometryRef where
    T: 'static + VertexFormat + Send + Clone + Copy + Debug
[src]

pub fn add_model(&mut self, name: &str) -> ModelBuilder<'_>[src]

pub fn add_component_to<'a, C: ComponentSend>(
    &mut self,
    entity: &Entity,
    component: C
) where
    <C as Component>::Storage: Storage<'s, C>,
    <<C as Component>::Storage as Storage<'a, C>>::Get: DebugParameter
[src]

Adds a Send Component to an already existing Entity.

pub fn add_component_to_thread_local<'a, C: ComponentThreadLocal>(
    &mut self,
    entity: &Entity,
    component: C
) where
    <C as Component>::Storage: Storage<'s, C>,
    <<C as Component>::Storage as Storage<'a, C>>::Get: DebugParameter
[src]

Adds a non Send Component to an already existing Entity.

pub fn component_for<C: Component>(&self, entity: &Entity) -> Option<Ptr<'_, C>> where
    <C as Component>::Storage: Storage<'s, C>, 
[src]

Returns a component for writing for the passed entity

pub fn resource<R: 'static>(&self) -> Option<ReadGuardRef<'_, R>>[src]

Auto Trait Implementations

impl !RefUnwindSafe for DeferredScene

impl !Send for DeferredScene

impl !Sync for DeferredScene

impl Unpin for DeferredScene

impl !UnwindSafe for DeferredScene

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Any for T where
    T: Any
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Downcast for T where
    T: Any
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<V> IntoPnt<V> for V[src]

impl<V> IntoVec<V> for V[src]

impl<T> Pointable for T[src]

type Init = T

The type for initializers.

impl<T> Same<T> for T[src]

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 
[src]

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]