Skip to main content

EncoderTargets

Trait EncoderTargets 

Source
pub trait EncoderTargets {
    // Required methods
    fn planes(
        &mut self,
        buffer: &LentBuffer,
        size: RenderSize,
    ) -> Result<LentPlanes, String>;
    fn finished(&mut self, buffer: &LentBuffer) -> Result<(), String>;
}
Expand description

Makes lent encoder buffers render targets on the GPU renderer’s device: the platform’s half of rendering frames in place, as SurfaceImport is of decoding them.

Required Methods§

Source

fn planes( &mut self, buffer: &LentBuffer, size: RenderSize, ) -> Result<LentPlanes, String>

The planes of buffer as render targets for a frame of size.

§Errors

A buffer that cannot be a render target there; the export then reads frames back.

Source

fn finished(&mut self, buffer: &LentBuffer) -> Result<(), String>

Waits until the GPU finished the frame rendered into buffer’s planes.

§Errors

A wait that failed or ran out of time.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§