pub struct QualitySettings {Show 21 fields
pub point_shadow_map_size: usize,
pub point_soft_shadows: bool,
pub point_shadows_enabled: bool,
pub point_shadows_distance: f32,
pub point_shadow_map_precision: ShadowMapPrecision,
pub point_shadows_fade_out_range: f32,
pub spot_shadow_map_size: usize,
pub spot_soft_shadows: bool,
pub spot_shadows_enabled: bool,
pub spot_shadows_distance: f32,
pub spot_shadow_map_precision: ShadowMapPrecision,
pub spot_shadows_fade_out_range: f32,
pub csm_settings: CsmSettings,
pub use_ssao: bool,
pub ssao_radius: f32,
pub light_scatter_enabled: bool,
pub fxaa: bool,
pub use_parallax_mapping: bool,
pub use_bloom: bool,
pub use_occlusion_culling: bool,
pub use_light_occlusion_culling: bool,
}Expand description
Quality settings allows you to find optimal balance between performance and graphics quality.
Fields§
§point_shadow_map_size: usizePoint shadows Size of cube map face of shadow map texture in pixels.
point_soft_shadows: boolUse or not percentage close filtering (smoothing) for point shadows.
point_shadows_enabled: boolPoint shadows enabled or not.
point_shadows_distance: f32Maximum distance from camera to draw shadows.
point_shadow_map_precision: ShadowMapPrecisionPoint shadow map precision. Allows you to select compromise between quality and performance.
point_shadows_fade_out_range: f32Point shadows fade out range. Specifies the distance from the camera at which point shadows start to fade out. Shadows beyond this distance will gradually become less visible.
spot_shadow_map_size: usizeSpot shadows Size of square shadow map texture in pixels
spot_soft_shadows: boolUse or not percentage close filtering (smoothing) for spot shadows.
spot_shadows_enabled: boolSpot shadows enabled or not.
spot_shadows_distance: f32Maximum distance from camera to draw shadows.
spot_shadow_map_precision: ShadowMapPrecisionSpot shadow map precision. Allows you to select compromise between quality and performance.
spot_shadows_fade_out_range: f32Specifies the distance from the camera at which spot shadows start to fade out. Shadows beyond this distance will gradually become less visible.
csm_settings: CsmSettingsCascaded-shadow maps settings.
use_ssao: boolWhether to use screen space ambient occlusion or not.
ssao_radius: f32Radius of sampling hemisphere used in SSAO, it defines much ambient occlusion will be in your scene.
light_scatter_enabled: boolGlobal switch to enable or disable light scattering. Each light can have its own scatter switch, but this one is able to globally disable scatter.
fxaa: boolWhether to use Fast Approximate AntiAliasing or not.
use_parallax_mapping: boolWhether to use Parallax Mapping or not.
use_bloom: boolWhether to use bloom effect.
use_occlusion_culling: boolWhether to use occlusion culling for geometry or not. Warning: this is experimental feature that may have bugs and unstable behavior. Disabled by default.
use_light_occlusion_culling: boolWhether to use occlusion culling for light sources or not. Warning: this is experimental feature that may have bugs and unstable behavior. Disabled by default.
Implementations§
Source§impl QualitySettings
impl QualitySettings
pub const POINT_SHADOW_MAP_SIZE: &'static str = "point_shadow_map_size"
pub const POINT_SOFT_SHADOWS: &'static str = "point_soft_shadows"
pub const POINT_SHADOWS_ENABLED: &'static str = "point_shadows_enabled"
pub const POINT_SHADOWS_DISTANCE: &'static str = "point_shadows_distance"
pub const POINT_SHADOW_MAP_PRECISION: &'static str = "point_shadow_map_precision"
pub const POINT_SHADOWS_FADE_OUT_RANGE: &'static str = "point_shadows_fade_out_range"
pub const SPOT_SHADOW_MAP_SIZE: &'static str = "spot_shadow_map_size"
pub const SPOT_SOFT_SHADOWS: &'static str = "spot_soft_shadows"
pub const SPOT_SHADOWS_ENABLED: &'static str = "spot_shadows_enabled"
pub const SPOT_SHADOWS_DISTANCE: &'static str = "spot_shadows_distance"
pub const SPOT_SHADOW_MAP_PRECISION: &'static str = "spot_shadow_map_precision"
pub const SPOT_SHADOWS_FADE_OUT_RANGE: &'static str = "spot_shadows_fade_out_range"
pub const CSM_SETTINGS: &'static str = "csm_settings"
pub const USE_SSAO: &'static str = "use_ssao"
pub const SSAO_RADIUS: &'static str = "ssao_radius"
pub const LIGHT_SCATTER_ENABLED: &'static str = "light_scatter_enabled"
pub const FXAA: &'static str = "fxaa"
pub const USE_PARALLAX_MAPPING: &'static str = "use_parallax_mapping"
pub const USE_BLOOM: &'static str = "use_bloom"
pub const USE_OCCLUSION_CULLING: &'static str = "use_occlusion_culling"
pub const USE_LIGHT_OCCLUSION_CULLING: &'static str = "use_light_occlusion_culling"
Trait Implementations§
Source§impl Clone for QualitySettings
impl Clone for QualitySettings
Source§fn clone(&self) -> QualitySettings
fn clone(&self) -> QualitySettings
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for QualitySettings
impl Debug for QualitySettings
Source§impl Default for QualitySettings
impl Default for QualitySettings
Source§impl<'de> Deserialize<'de> for QualitySettings
impl<'de> Deserialize<'de> for QualitySettings
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for QualitySettings
impl PartialEq for QualitySettings
Source§impl Reflect for QualitySettingswhere
Self: 'static,
usize: Reflect,
bool: Reflect,
f32: Reflect,
ShadowMapPrecision: Reflect,
CsmSettings: Reflect,
impl Reflect for QualitySettingswhere
Self: 'static,
usize: Reflect,
bool: Reflect,
f32: Reflect,
ShadowMapPrecision: Reflect,
CsmSettings: Reflect,
fn source_path() -> &'static str
fn type_name(&self) -> &'static str
fn doc(&self) -> &'static str
Source§fn assembly_name(&self) -> &'static str
fn assembly_name(&self) -> &'static str
#[derive(Reflect)]) to ensure that this method will return correct assembly
name. In other words - there’s no guarantee, that any implementation other than proc-macro
will return a correct name of the assembly. Alternatively, you can use env!("CARGO_PKG_NAME")
as an implementation.Source§fn type_assembly_name() -> &'static str
fn type_assembly_name() -> &'static str
#[derive(Reflect)]) to ensure that this method will return correct assembly
name. In other words - there’s no guarantee, that any implementation other than proc-macro
will return a correct name of the assembly. Alternatively, you can use env!("CARGO_PKG_NAME")
as an implementation.fn fields_info(&self, func: &mut dyn FnMut(&[FieldInfo<'_, '_>]))
fn into_any(self: Box<Self>) -> Box<dyn Any>
fn set( &mut self, value: Box<dyn Reflect>, ) -> Result<Box<dyn Reflect>, Box<dyn Reflect>>
fn as_any(&self, func: &mut dyn FnMut(&dyn Any))
fn as_any_mut(&mut self, func: &mut dyn FnMut(&mut dyn Any))
fn as_reflect(&self, func: &mut dyn FnMut(&dyn Reflect))
fn as_reflect_mut(&mut self, func: &mut dyn FnMut(&mut dyn Reflect))
fn fields(&self, func: &mut dyn FnMut(&[&dyn Reflect]))
fn fields_mut(&mut self, func: &mut dyn FnMut(&mut [&mut dyn Reflect]))
fn field(&self, name: &str, func: &mut dyn FnMut(Option<&dyn Reflect>))
fn field_mut( &mut self, name: &str, func: &mut dyn FnMut(Option<&mut dyn Reflect>), )
Source§fn set_field(
&mut self,
field: &str,
value: Box<dyn Reflect>,
func: &mut dyn FnMut(Result<Box<dyn Reflect>, Box<dyn Reflect>>),
)
fn set_field( &mut self, field: &str, value: Box<dyn Reflect>, func: &mut dyn FnMut(Result<Box<dyn Reflect>, Box<dyn Reflect>>), )
#[reflect(setter = ..)] or falls back to
Reflect::field_mutfn as_array(&self, func: &mut dyn FnMut(Option<&(dyn ReflectArray + 'static)>))
fn as_array_mut( &mut self, func: &mut dyn FnMut(Option<&mut (dyn ReflectArray + 'static)>), )
fn as_list(&self, func: &mut dyn FnMut(Option<&(dyn ReflectList + 'static)>))
fn as_list_mut( &mut self, func: &mut dyn FnMut(Option<&mut (dyn ReflectList + 'static)>), )
fn as_inheritable_variable( &self, func: &mut dyn FnMut(Option<&(dyn ReflectInheritableVariable + 'static)>), )
fn as_inheritable_variable_mut( &mut self, func: &mut dyn FnMut(Option<&mut (dyn ReflectInheritableVariable + 'static)>), )
fn as_hash_map( &self, func: &mut dyn FnMut(Option<&(dyn ReflectHashMap + 'static)>), )
fn as_hash_map_mut( &mut self, func: &mut dyn FnMut(Option<&mut (dyn ReflectHashMap + 'static)>), )
Source§impl Serialize for QualitySettings
impl Serialize for QualitySettings
impl Copy for QualitySettings
impl StructuralPartialEq for QualitySettings
Auto Trait Implementations§
impl Freeze for QualitySettings
impl RefUnwindSafe for QualitySettings
impl Send for QualitySettings
impl Sync for QualitySettings
impl Unpin for QualitySettings
impl UnwindSafe for QualitySettings
Blanket Implementations§
Source§impl<T> AsyncTaskResult for T
impl<T> AsyncTaskResult for T
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Any. Could be used to downcast a trait object
to a particular type.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Any. Could be used to downcast a trait object
to a particular type.fn into_any(self: Box<T>) -> Box<dyn Any>
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> FieldValue for Twhere
T: 'static,
impl<T> FieldValue for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> MessageData for T
impl<T> MessageData for T
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().Source§impl<T> ReflectBase for Twhere
T: Reflect,
impl<T> ReflectBase for Twhere
T: Reflect,
fn as_any_raw(&self) -> &(dyn Any + 'static)
fn as_any_raw_mut(&mut self) -> &mut (dyn Any + 'static)
Source§impl<T> ResolvePath for Twhere
T: Reflect,
impl<T> ResolvePath for Twhere
T: Reflect,
fn resolve_path<'p>( &self, path: &'p str, func: &mut dyn FnMut(Result<&(dyn Reflect + 'static), ReflectPathError<'p>>), )
fn resolve_path_mut<'p>( &mut self, path: &'p str, func: &mut dyn FnMut(Result<&mut (dyn Reflect + 'static), ReflectPathError<'p>>), )
fn get_resolve_path<'p, T>(
&self,
path: &'p str,
func: &mut dyn FnMut(Result<&T, ReflectPathError<'p>>),
)where
T: Reflect,
fn get_resolve_path_mut<'p, T>(
&mut self,
path: &'p str,
func: &mut dyn FnMut(Result<&mut T, ReflectPathError<'p>>),
)where
T: Reflect,
Source§impl<T> ScriptMessagePayload for T
impl<T> ScriptMessagePayload for T
Source§fn as_any_ref(&self) -> &(dyn Any + 'static)
fn as_any_ref(&self) -> &(dyn Any + 'static)
self as &dyn AnySource§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
self as &dyn AnySource§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.