pub unsafe fn from_words(
        device: Arc<Device>,
        words: &[u32],
    ) -> Result<Arc<ShaderModule>, ShaderCreationError> {
        let spirv = Spirv::new(words)?;

        Self::from_words_with_data(
            device,
            words,
            spirv.version(),
            reflect::spirv_capabilities(&spirv),
            reflect::spirv_extensions(&spirv),
            reflect::entry_points(&spirv),
        )
    }
/// Builds a new shader module from SPIR-V 32-bit words. The shader code is parsed and the
/// necessary information is extracted from it.
///
/// # Safety
///
/// - The SPIR-V code is not validated beyond the minimum needed to extract the information.
Builds a new shader module from SPIR-V 32-bit words. The shader code is parsed and the
necessary information is extracted from it.
Builds a new shader module from SPIR - V 32 - bit words . The shader code is parsed and the necessary information is extracted from it .
pub unsafe fn from_words(
        device: Arc<Device>,
        words: &[u32],
    ) -> Result<Arc<ShaderModule>, ShaderCreationError> {
        let spirv = Spirv::new(words)?;
        Self::from_words_with_data(
            device,
            words,
            spirv.version(),
            reflect::spirv_capabilities(&spirv),
            reflect::spirv_extensions(&spirv),
            reflect::entry_points(&spirv),
        )
    }
pub unsafe fn from_words ( device : Arc < Device > , words : & [ u32 ] , ) -> Result < Arc < ShaderModule > , ShaderCreationError > { let spirv = Spirv :: new ( words ) ? ; Self :: from_words_with_data ( device , words , spirv . version ( ) , reflect :: spirv_capabilities ( & spirv ) , reflect :: spirv_extensions ( & spirv ) , reflect :: entry_points ( & spirv ) , ) }
Builds a new shader module from SPIR-V 32-bit words.
Builds a new shader module from SPIR - V 32 - bit words .
device
Arc<Device>
words
&[u32]
device
Arc<Device>
words
&[u32]
safety
The SPIR-V code is not validated beyond the minimum needed to extract the information.
The SPIR - V code is not validated beyond the minimum needed to extract the information .