Enum flo_render::RenderAction[][src]

pub enum RenderAction {
    SetTransform(Matrix),
    CreateVertex2DBuffer(VertexBufferIdVec<Vertex2D>),
    CreateIndexBuffer(IndexBufferIdVec<u16>),
    FreeVertexBuffer(VertexBufferId),
    FreeIndexBuffer(IndexBufferId),
    BlendMode(BlendMode),
    CreateRenderTarget(RenderTargetIdTextureIdusizeusizeRenderTargetType),
    FreeRenderTarget(RenderTargetId),
    SelectRenderTarget(RenderTargetId),
    RenderToFrameBuffer,
    ShowFrameBuffer,
    DrawFrameBuffer(RenderTargetIdi32i32),
    CreateTextureBgra(TextureIdusizeusize),
    FreeTexture(TextureId),
    Clear(Rgba8),
    UseShader(ShaderType),
    DrawTriangles(VertexBufferIdRange<usize>),
    DrawIndexedTriangles(VertexBufferIdIndexBufferIdusize),
}

Represents an action for a render target

Variants

SetTransform(Matrix)

Sets the transformation matrix to use for future renderings

CreateVertex2DBuffer(VertexBufferIdVec<Vertex2D>)

Creates a vertex buffer with the specified 2D vertices in it (replacing any existing buffer)

CreateIndexBuffer(IndexBufferIdVec<u16>)

Creates an index buffer with the specified 2D vertices in it (replacing any existing buffer)

FreeVertexBuffer(VertexBufferId)

Frees an existing vertex buffer

FreeIndexBuffer(IndexBufferId)

Frees an existing index buffer

BlendMode(BlendMode)

Sets the blend mode for future drawing operations (SourceOver is the default)

Creates a new render target of the specified size, as the specified texture

FreeRenderTarget(RenderTargetId)

Frees up an existing render target

SelectRenderTarget(RenderTargetId)

Send future rendering instructions to the specified render target

RenderToFrameBuffer

Send future rendering instructions to the main frame buffer

ShowFrameBuffer

Display the current frame buffer on-screen

DrawFrameBuffer(RenderTargetIdi32i32)

Renders the specified framebuffer to the current framebuffer

CreateTextureBgra(TextureIdusizeusize)

Creates an 8-bit BGRA texture of the specified size

FreeTexture(TextureId)

Frees up an existing texture

Clear(Rgba8)

Clears the current render target to the specified colour

UseShader(ShaderType)

Uses the specified shader

DrawTriangles(VertexBufferIdRange<usize>)

Renders triangles from a vertex buffer (with no texture)

Parameters are the range of vertices to use

DrawIndexedTriangles(VertexBufferIdIndexBufferIdusize)

Renders triangles using an index buffer

Trait Implementations

impl Clone for RenderAction[src]

impl Debug for RenderAction[src]

impl PartialEq<RenderAction> for RenderAction[src]

impl StructuralPartialEq for RenderAction[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.