Struct CompilerBuilder

Source
pub struct CompilerBuilder<'a> { /* private fields */ }

Implementations§

Source§

impl<'a> CompilerBuilder<'a>

Source

pub fn new() -> CompilerBuilder<'a>

Source

pub fn with_target_spirv(self, version: SpirvVersion) -> Self

Source

pub fn with_macro(self, name: &str, value: Option<&str>) -> Self

Source

pub fn with_auto_bind_uniforms(self, auto_bind: bool) -> Self

Source

pub fn with_binding_base(self, kind: ResourceKind, base: u32) -> Self

Source

pub fn generate_debug_info(self) -> Self

Source

pub fn force_version_profile(self, version: u32, profile: GlslProfile) -> Self

Source

pub fn with_target_env(self, env: TargetEnv, version: u32) -> Self

Source

pub fn with_hlsl_io_mapping(self, iomap: bool) -> Self

Source

pub fn with_hlsl_register_set_and_binding( self, register: &str, set: &str, binding: &str, ) -> Self

Source

pub fn with_hlsl_offsets(self, offsets: bool) -> Self

Source

pub fn with_source_language(self, lang: SourceLanguage) -> Self

Source

pub fn with_binding_base_for_stage( self, kind: ShaderKind, resource_kind: ResourceKind, base: u32, ) -> Self

Source

pub fn with_opt_level(self, level: OptimizationLevel) -> Self

Source

pub fn supress_warnings(self) -> Self

Source

pub fn with_warnings_as_errors(self) -> Self

Source

pub fn with_limit(self, limit: Limit, value: i32) -> Self

Source

pub fn with_include_dir<T: AsRef<Path>>(self, path: T) -> Self

Source

pub fn build(self) -> Option<Compiler<'a>>

Trait Implementations§

Source§

impl Default for CompilerBuilder<'_>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<'a> Freeze for CompilerBuilder<'a>

§

impl<'a> !RefUnwindSafe for CompilerBuilder<'a>

§

impl<'a> !Send for CompilerBuilder<'a>

§

impl<'a> !Sync for CompilerBuilder<'a>

§

impl<'a> Unpin for CompilerBuilder<'a>

§

impl<'a> !UnwindSafe for CompilerBuilder<'a>

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.