pub struct Compiler<'a> { /* private fields */ }
Implementations§
Source§impl<'a> Compiler<'a>
impl<'a> Compiler<'a>
pub fn new() -> Option<Compiler<'a>>
pub fn add_macro_definition(&mut self, name: &str, value: Option<&str>)
pub fn compile_from_string( &mut self, source: &str, kind: ShaderKind, ) -> Result<Vec<u32>, CompilerError>
pub fn compile_from_file<T: AsRef<Path>>( &mut self, path: T, kind: ShaderKind, cache: bool, ) -> Result<Vec<u32>, CompilerError>
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Compiler<'a>
impl<'a> !RefUnwindSafe for Compiler<'a>
impl<'a> !Send for Compiler<'a>
impl<'a> !Sync for Compiler<'a>
impl<'a> Unpin for Compiler<'a>
impl<'a> !UnwindSafe for Compiler<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more