Struct rspirv_reflect::Reflection
source · [−]pub struct Reflection(pub Module);Tuple Fields
0: ModuleImplementations
sourceimpl Reflection
impl Reflection
pub fn new(module: Module) -> Self
pub fn new_from_spirv(code: &[u8]) -> Result<Self, ReflectError>
sourcepub fn find_annotations_for_id(
annotations: &[Instruction],
id: u32
) -> Result<Vec<&Instruction>, ReflectError>
pub fn find_annotations_for_id(
annotations: &[Instruction],
id: u32
) -> Result<Vec<&Instruction>, ReflectError>
Returns all instructions where the first operand (Instruction::operands[0]) equals IdRef(id)
sourcepub fn find_assignment_for(
instructions: &[Instruction],
id: u32
) -> Result<&Instruction, ReflectError>
pub fn find_assignment_for(
instructions: &[Instruction],
id: u32
) -> Result<&Instruction, ReflectError>
Returns the first Instruction assigning to id (ie. result_id == Some(id))
pub fn get_compute_group_size(&self) -> Option<(u32, u32, u32)>
sourcepub fn get_descriptor_sets(
&self
) -> Result<BTreeMap<u32, BTreeMap<u32, DescriptorInfo>>, ReflectError>
pub fn get_descriptor_sets(
&self
) -> Result<BTreeMap<u32, BTreeMap<u32, DescriptorInfo>>, ReflectError>
Returns a nested mapping, where the first level maps descriptor set indices (register spaces) and the second level maps descriptor binding indices (registers) to descriptor information.
pub fn get_push_constant_range(
&self
) -> Result<Option<PushConstantInfo>, ReflectError>
pub fn disassemble(&self) -> String
Auto Trait Implementations
impl RefUnwindSafe for Reflection
impl Send for Reflection
impl Sync for Reflection
impl Unpin for Reflection
impl UnwindSafe for Reflection
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more