Struct three_d::renderer::DeferredPipeline[][src]

pub struct DeferredPipeline {
    pub debug_type: DebugType,
    pub lighting_model: LightingModel,
    // some fields omitted
}
Expand description

Deferred render pipeline which can render objects (implementing the Geometry trait) with materials (implementing the DeferredMaterial trait) and lighting. Supports different types of lighting models by changing the DeferredPipeline::lighting_model field. Deferred rendering draws the geometry information into a buffer in the DeferredPipeline::geometry_pass and use that information in the DeferredPipeline::light_pass. This means that the lighting is only calculated once per pixel since the depth testing is happening in the geometry pass. Note: Deferred rendering does not support blending and therefore does not support transparency!

Fields

debug_type: DebugType

Set this to visualize the positions, normals etc. for debug purposes.

lighting_model: LightingModel

Implementations

Constructor.

Render the given geometry and material parameters to a buffer. This function must not be called in a render target render function and needs to be followed by a call to DeferredPipeline::light_pass.

Uses the geometry and surface material parameters written in the last DeferredPipeline::geometry_pass call and all of the given lights to render the objects. Must be called in a render target render function, for example in the callback function of Screen::write.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more