Struct gfx_graphics::GfxGraphics [] [src]

pub struct GfxGraphics<'a, R, C> where
    R: Resources + 'a,
    C: CommandBuffer<R> + 'a,
    R::Buffer: 'a,
    R::Shader: 'a,
    R::Program: 'a,
    R::Texture: 'a,
    R::Sampler: 'a, 
{ pub encoder: &'a mut Encoder<R, C>, // some fields omitted }

Used for rendering 2D graphics.

Fields

Provide access to the gfx::Encoder in case a user needs to update textures for caching, etc.

Methods

impl<'a, R, C> GfxGraphics<'a, R, C> where
    R: Resources,
    C: CommandBuffer<R>, 
[src]

[src]

Creates a new object for rendering 2D graphics.

[src]

Returns true if texture has alpha channel.

Trait Implementations

impl<'a, R, C> Graphics for GfxGraphics<'a, R, C> where
    R: Resources,
    C: CommandBuffer<R>,
    R::Buffer: 'a,
    R::Shader: 'a,
    R::Program: 'a,
    R::Texture: 'a,
    R::Sampler: 'a, 
[src]

The texture type associated with the back-end. Read more

[src]

Clears background with a color. Read more

[src]

Clears stencil buffer with a value, usually 0. Read more

[src]

Renders list of 2d triangles using a solid color. Read more

[src]

Renders list of 2d triangles using a color and a texture. Read more

[src]

Draws a rectangle. Read more

[src]

Draws a polygon. Read more

[src]

Draws a tweened polygon using linear interpolation. Read more

[src]

Draws image. Read more

[src]

Draws ellipse. Read more

[src]

Draws line. Read more

[src]

Draws circle arc. Read more

[src]

Draws deformed image. Read more