[][src]Struct tm_sys::ffi::tm_shader_api

#[repr(C)]pub struct tm_shader_api {
    pub create_constant_buffer_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_instances: u32, result: *mut tm_shader_constant_buffer_instance_t)>,
    pub create_constant_buffer_instances_from_template: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, num_instances: u32, result: *mut tm_shader_constant_buffer_instance_t, cbuf_template: tm_shader_constant_buffer_instance_t)>,
    pub destroy_constant_buffer_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, instances: *mut tm_shader_constant_buffer_instance_t, num_instances: u32)>,
    pub create_resource_binder_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_instances: u32, result: *mut tm_shader_resource_binder_instance_t)>,
    pub destroy_resource_binder_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, instances: *mut tm_shader_resource_binder_instance_t, num_instances: u32)>,
    pub reflect_constants: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_constants: *mut u32, constants: *mut tm_shader_constant_t, constant_offsets: *mut u32)>,
    pub lookup_constant: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, name: u64, constant: *mut tm_shader_constant_t, constant_offset: *mut u32) -> bool>,
    pub update_constants: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, constant_updates: *const tm_shader_constant_update_t, num_updates: u32)>,
    pub update_constants_raw: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, instance_ids: *const u32, data: *mut *const c_void, offset: u32, size: u32, num_updates: u32)>,
    pub update_constant_buffer_instances_from_template: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, num_instances: u32, instances: *mut tm_shader_constant_buffer_instance_t, cbuf_template: tm_shader_constant_buffer_instance_t)>,
    pub reflect_resources: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_resources: *mut u32, resources: *mut tm_shader_resource_t, resource_slots: *mut u32)>,
    pub lookup_resource: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, name: u64, resource: *mut tm_shader_resource_t, resource_slot: *mut u32) -> bool>,
    pub update_resources: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, resource_updates: *mut tm_shader_resource_update_t, num_updates: u32)>,
    pub max_passes: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> u8>,
    pub assemble_shader_infos: Option<unsafe extern "C" fn(shader: *mut tm_shader_o, state_override_blocks: *const u32, num_state_override_blocks: u32, context: *const tm_shader_system_context_o, visibility_context: u64, resource_buffer: *mut tm_renderer_resource_command_buffer_o, cbuf_instances: *const tm_shader_constant_buffer_instance_t, rbinder_instances: *const tm_shader_resource_binder_instance_t, num_shaders: u32, results: *mut tm_renderer_shader_info_t) -> u8>,
    pub shader_io: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> *mut tm_shader_io_o>,
    pub system_io: Option<unsafe extern "C" fn(system: *mut tm_shader_system_o) -> *mut tm_shader_io_o>,
    pub name: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> u64>,
}

Fields

create_constant_buffer_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_instances: u32, result: *mut tm_shader_constant_buffer_instance_t)>create_constant_buffer_instances_from_template: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, num_instances: u32, result: *mut tm_shader_constant_buffer_instance_t, cbuf_template: tm_shader_constant_buffer_instance_t)>destroy_constant_buffer_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, instances: *mut tm_shader_constant_buffer_instance_t, num_instances: u32)>create_resource_binder_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_instances: u32, result: *mut tm_shader_resource_binder_instance_t)>destroy_resource_binder_instances: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, instances: *mut tm_shader_resource_binder_instance_t, num_instances: u32)>reflect_constants: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_constants: *mut u32, constants: *mut tm_shader_constant_t, constant_offsets: *mut u32)>lookup_constant: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, name: u64, constant: *mut tm_shader_constant_t, constant_offset: *mut u32) -> bool>update_constants: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, constant_updates: *const tm_shader_constant_update_t, num_updates: u32)>update_constants_raw: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, instance_ids: *const u32, data: *mut *const c_void, offset: u32, size: u32, num_updates: u32)>update_constant_buffer_instances_from_template: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, num_instances: u32, instances: *mut tm_shader_constant_buffer_instance_t, cbuf_template: tm_shader_constant_buffer_instance_t)>reflect_resources: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, num_resources: *mut u32, resources: *mut tm_shader_resource_t, resource_slots: *mut u32)>lookup_resource: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, name: u64, resource: *mut tm_shader_resource_t, resource_slot: *mut u32) -> bool>update_resources: Option<unsafe extern "C" fn(io: *mut tm_shader_io_o, resource_buffer: *mut tm_renderer_resource_command_buffer_o, resource_updates: *mut tm_shader_resource_update_t, num_updates: u32)>max_passes: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> u8>assemble_shader_infos: Option<unsafe extern "C" fn(shader: *mut tm_shader_o, state_override_blocks: *const u32, num_state_override_blocks: u32, context: *const tm_shader_system_context_o, visibility_context: u64, resource_buffer: *mut tm_renderer_resource_command_buffer_o, cbuf_instances: *const tm_shader_constant_buffer_instance_t, rbinder_instances: *const tm_shader_resource_binder_instance_t, num_shaders: u32, results: *mut tm_renderer_shader_info_t) -> u8>shader_io: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> *mut tm_shader_io_o>system_io: Option<unsafe extern "C" fn(system: *mut tm_shader_system_o) -> *mut tm_shader_io_o>name: Option<unsafe extern "C" fn(shader: *mut tm_shader_o) -> u64>

Trait Implementations

impl Clone for tm_shader_api[src]

impl Copy for tm_shader_api[src]

impl Debug for tm_shader_api[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.