Trait gfx::CommandBuffer[][src]

pub trait CommandBuffer<R>: 'static + Send where
    R: Resources
{ pub fn reset(&mut self);
pub fn bind_pipeline_state(&mut self, <R as Resources>::PipelineStateObject);
pub fn bind_vertex_buffers(&mut self, VertexBufferSet<R>);
pub fn bind_constant_buffers(&mut self, &[ConstantBufferParam<R>]);
pub fn bind_global_constant(&mut self, usize, UniformValue);
pub fn bind_resource_views(&mut self, &[ResourceViewParam<R>]);
pub fn bind_unordered_views(&mut self, &[UnorderedViewParam<R>]);
pub fn bind_samplers(&mut self, &[SamplerParam<R>]);
pub fn bind_pixel_targets(&mut self, PixelTargetSet<R>);
pub fn bind_index(&mut self, <R as Resources>::Buffer, IndexType);
pub fn set_scissor(&mut self, Rect);
pub fn set_ref_values(&mut self, RefValues);
pub fn copy_buffer(
        &mut self,
        src: <R as Resources>::Buffer,
        dst: <R as Resources>::Buffer,
        src_offset_bytes: usize,
        dst_offset_bytes: usize,
        size_bytes: usize
    );
pub fn copy_buffer_to_texture(
        &mut self,
        src: <R as Resources>::Buffer,
        src_offset_bytes: usize,
        dst: TextureCopyRegion<<R as Resources>::Texture>
    );
pub fn copy_texture_to_buffer(
        &mut self,
        src: TextureCopyRegion<<R as Resources>::Texture>,
        dst: <R as Resources>::Buffer,
        dst_offset_bytes: usize
    );
pub fn copy_texture_to_texture(
        &mut self,
        src: TextureCopyRegion<<R as Resources>::Texture>,
        dst: TextureCopyRegion<<R as Resources>::Texture>
    );
pub fn update_buffer(
        &mut self,
        <R as Resources>::Buffer,
        data: &[u8],
        offset: usize
    );
pub fn update_texture(
        &mut self,
        TextureCopyRegion<<R as Resources>::Texture>,
        data: &[u8]
    );
pub fn generate_mipmap(&mut self, <R as Resources>::ShaderResourceView);
pub fn clear_color(
        &mut self,
        <R as Resources>::RenderTargetView,
        ClearColor
    );
pub fn clear_depth_stencil(
        &mut self,
        <R as Resources>::DepthStencilView,
        Option<f32>,
        Option<u8>
    );
pub fn call_draw(&mut self, u32, u32, Option<(u32, u32)>);
pub fn call_draw_indexed(&mut self, u32, u32, u32, Option<(u32, u32)>); }

An interface of the abstract command buffer. It collects commands in an efficient API-specific manner, to be ready for execution on the device.

Required methods

pub fn reset(&mut self)[src]

Reset the command buffer contents, retain the allocated storage

pub fn bind_pipeline_state(&mut self, <R as Resources>::PipelineStateObject)[src]

Bind a pipeline state object

pub fn bind_vertex_buffers(&mut self, VertexBufferSet<R>)[src]

Bind a complete set of vertex buffers

pub fn bind_constant_buffers(&mut self, &[ConstantBufferParam<R>])[src]

Bind a complete set of constant buffers

pub fn bind_global_constant(&mut self, usize, UniformValue)[src]

Bind a global constant

pub fn bind_resource_views(&mut self, &[ResourceViewParam<R>])[src]

Bind a complete set of shader resource views

pub fn bind_unordered_views(&mut self, &[UnorderedViewParam<R>])[src]

Bind a complete set of unordered access views

pub fn bind_samplers(&mut self, &[SamplerParam<R>])[src]

Bind a complete set of samplers

pub fn bind_pixel_targets(&mut self, PixelTargetSet<R>)[src]

Bind a complete set of pixel targets, including multiple colors views and an optional depth/stencil view.

pub fn bind_index(&mut self, <R as Resources>::Buffer, IndexType)[src]

Bind an index buffer

pub fn set_scissor(&mut self, Rect)[src]

Set scissor rectangle

pub fn set_ref_values(&mut self, RefValues)[src]

Set reference values for the blending and stencil front/back

pub fn copy_buffer(
    &mut self,
    src: <R as Resources>::Buffer,
    dst: <R as Resources>::Buffer,
    src_offset_bytes: usize,
    dst_offset_bytes: usize,
    size_bytes: usize
)
[src]

Copy part of a buffer to another

pub fn copy_buffer_to_texture(
    &mut self,
    src: <R as Resources>::Buffer,
    src_offset_bytes: usize,
    dst: TextureCopyRegion<<R as Resources>::Texture>
)
[src]

Copy part of a buffer to a texture

pub fn copy_texture_to_buffer(
    &mut self,
    src: TextureCopyRegion<<R as Resources>::Texture>,
    dst: <R as Resources>::Buffer,
    dst_offset_bytes: usize
)
[src]

Copy part of a texture to a buffer

pub fn copy_texture_to_texture(
    &mut self,
    src: TextureCopyRegion<<R as Resources>::Texture>,
    dst: TextureCopyRegion<<R as Resources>::Texture>
)
[src]

Copy part of one texture into another

pub fn update_buffer(
    &mut self,
    <R as Resources>::Buffer,
    data: &[u8],
    offset: usize
)
[src]

Update a vertex/index/uniform buffer

pub fn update_texture(
    &mut self,
    TextureCopyRegion<<R as Resources>::Texture>,
    data: &[u8]
)
[src]

Update a texture

pub fn generate_mipmap(&mut self, <R as Resources>::ShaderResourceView)[src]

pub fn clear_color(&mut self, <R as Resources>::RenderTargetView, ClearColor)[src]

Clear color target

pub fn clear_depth_stencil(
    &mut self,
    <R as Resources>::DepthStencilView,
    Option<f32>,
    Option<u8>
)
[src]

pub fn call_draw(&mut self, u32, u32, Option<(u32, u32)>)[src]

Draw a primitive

pub fn call_draw_indexed(&mut self, u32, u32, u32, Option<(u32, u32)>)[src]

Draw a primitive with index buffer

Loading content...

Implementations on Foreign Types

impl Buffer<DummyResources> for DummyCommandBuffer[src]

Loading content...

Implementors

Loading content...