CommandBuffer

Struct CommandBuffer 

Source
pub struct CommandBuffer { /* private fields */ }

Implementations§

Source§

impl CommandBuffer

Source

pub unsafe fn create(device: &Device) -> Result<Self>

Source

pub unsafe fn destroy(self, device: &Device)

Source

pub unsafe fn begin(&self, device: &Device) -> Result<()>

Source

pub unsafe fn end(&self, device: &Device) -> Result<()>

Source

pub unsafe fn handle(&self) -> CommandBuffer

Source

pub unsafe fn begin_rendering<Image>( &self, device: &Device, color_attachment: (&Image, [f32; 4]), depth_attachment: Option<(&Image, f32)>, resolve_attachment: Option<&Image>, )
where Image: ImageOps,

Source

pub unsafe fn end_rendering(&self, device: &Device)

Source

pub unsafe fn barrier( &self, device: &Device, src_stage_mask: impl Into<PipelineStageFlags2>, src_access_mask: impl Into<AccessFlags2>, dst_stage_mask: impl Into<PipelineStageFlags2>, dst_access_mask: impl Into<AccessFlags2>, )

Source

pub unsafe fn buffer_barrier( &self, device: &Device, buffer: &impl BufferOps, src_stage_mask: impl Into<PipelineStageFlags2>, src_access_mask: impl Into<AccessFlags2>, dst_stage_mask: impl Into<PipelineStageFlags2>, dst_access_mask: impl Into<AccessFlags2>, )

Source

pub unsafe fn image_barrier( &self, device: &Device, image: &impl ImageOps, src_stage_mask: impl Into<PipelineStageFlags2>, src_access_mask: impl Into<AccessFlags2>, dst_stage_mask: impl Into<PipelineStageFlags2>, dst_access_mask: impl Into<AccessFlags2>, old_layout: ImageLayout, new_layout: ImageLayout, )

Source

pub unsafe fn draw_mesh_tasks( &self, device: &Device, group_count_x: u32, group_count_y: u32, group_count_z: u32, )

Source

pub unsafe fn draw_mesh_tasks_indirect( &self, device: &Device, buffer: &impl BufferOps, offset: DeviceSize, draw_count: u32, stride: u32, )

Source

pub unsafe fn draw_mesh_tasks_indirect_count( &self, device: &Device, buffer: &impl BufferOps, offset: DeviceSize, count_buffer: &impl BufferOps, count_buffer_offset: DeviceSize, max_draw_count: u32, stride: u32, )

Source

pub unsafe fn dispatch( &self, device: &Device, group_count_x: u32, group_count_y: u32, group_count_z: u32, )

Source

pub unsafe fn dispatch_indirect( &self, device: &Device, buffer: &impl BufferOps, offset: DeviceSize, )

Source

pub unsafe fn copy_buffer( &self, device: &Device, src_buffer: (&impl BufferOps, DeviceSize), dst_buffer: (&impl BufferOps, DeviceSize), size: DeviceSize, )

Source

pub unsafe fn copy_image( &self, device: &Device, src_image: (&impl ImageOps, ImageLayout), dst_image: (&impl ImageOps, ImageLayout), extent: Extent3D, )

Source

pub unsafe fn copy_buffer_to_image( &self, device: &Device, src_buffer: (&impl BufferOps, DeviceSize), dst_image: &impl ImageOps, )

Source

pub unsafe fn copy_image_to_buffer( &self, device: &Device, src_image: &impl ImageOps, dst_buffer: (&impl BufferOps, DeviceSize), )

Source

pub unsafe fn bind_descriptor_storage( &self, device: &Device, descriptor_storage: &DescriptorStorage, pipeline_bind_point: PipelineBindPoint, )

Source

pub unsafe fn push_constants<T>( &self, device: &Device, descriptor_storage: &DescriptorStorage, data: &T, ) -> Result<()>

Source

pub unsafe fn bind_shader(&self, device: &Device, shader: &Shader)

Source

pub unsafe fn set_viewport(&self, device: &Device, viewport: &Viewport)

Source

pub unsafe fn set_viewport_flip_y(&self, device: &Device, viewport: &Viewport)

Source

pub unsafe fn set_scissor(&self, device: &Device, scissor: &Rect2D)

Source

pub unsafe fn set_samples(&self, device: &Device, samples: SampleCountFlagBits)

Source

pub unsafe fn set_front_face(&self, device: &Device, front_face: FrontFace)

Source

pub unsafe fn set_cull_mode( &self, device: &Device, cull_mode: impl Into<CullModeFlags>, )

Source

pub unsafe fn set_depth_test(&self, device: &Device, depth_test: bool)

Source

pub unsafe fn set_depth_compare_op( &self, device: &Device, depth_compare_op: CompareOp, )

Source

pub unsafe fn set_depth_write(&self, device: &Device, depth_write: bool)

Source

pub unsafe fn set_color_blend( &self, device: &Device, attachment: u32, color_blend: bool, )

Source

pub unsafe fn set_color_blend_equation( &self, device: &Device, attachment: u32, color_blend_equation: &ColorBlendEquationEXT, )

Source

pub unsafe fn set_color_write_mask( &self, device: &Device, attachment: u32, mask: ColorComponentFlags, )

Source

pub unsafe fn set_color_write_mask_rgba(&self, device: &Device, attachment: u32)

Source

pub unsafe fn write_timestamp( &self, device: &Device, timestamps: &TimestampQuery, index: u32, )

Source

pub unsafe fn begin_statistics( &self, device: &Device, statistics: &StatisticsQuery, )

Source

pub unsafe fn end_statistics( &self, device: &Device, statistics: &StatisticsQuery, )

Source

pub unsafe fn build_acceleration_structures( &self, device: &Device, ty: AccelerationStructureTypeKHR, dst_acceleration_structure: AccelerationStructureKHR, geometry_count: u32, geometries: &AccelerationStructureGeometryKHR, primitive_count: u32, scratch_data: &impl BufferOps, )

Source

pub unsafe fn bind_ray_tracing_pipeline( &self, device: &Device, pipeline: Pipeline, )

Source

pub unsafe fn trace_rays<Sbt>( &self, physical_device: &PhysicalDevice, device: &Device, raygen_sbt: Option<&Sbt>, miss_sbt: Option<&Sbt>, hit_sbt: Option<&Sbt>, callable_sbt: Option<&Sbt>, width: u32, height: u32, )
where Sbt: BufferOps,

Trait Implementations§

Source§

impl Debug for CommandBuffer

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.