Struct gfx_core::texture::SamplerInfo [−][src]
pub struct SamplerInfo { pub filter: FilterMethod, pub wrap_mode: (WrapMode, WrapMode, WrapMode), pub lod_bias: Lod, pub lod_range: (Lod, Lod), pub comparison: Option<Comparison>, pub border: PackedColor, }
Specifies how to sample from a texture.
Fields
filter: FilterMethod
Filter method to use.
wrap_mode: (WrapMode, WrapMode, WrapMode)
Wrapping mode for each of the U, V, and W axis (S, T, and R in OpenGL speak).
lod_bias: Lod
This bias is added to every computed mipmap level (N + lod_bias). For example, if it would select mipmap level 2 and lod_bias is 1, it will use mipmap level 3.
lod_range: (Lod, Lod)
This range is used to clamp LOD level used for sampling.
comparison: Option<Comparison>
Comparison mode, used primary for a shadow map.
border: PackedColor
Border color is used when one of the wrap modes is set to border.
Implementations
impl SamplerInfo
[src]
pub fn new(filter: FilterMethod, wrap: WrapMode) -> SamplerInfo
[src]
Create a new sampler description with a given filter method and wrapping mode, using no LOD modifications.
Trait Implementations
impl Clone for SamplerInfo
[src]
fn clone(&self) -> SamplerInfo
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for SamplerInfo
[src]
impl Debug for SamplerInfo
[src]
impl Eq for SamplerInfo
[src]
impl Hash for SamplerInfo
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
pub fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl PartialEq<SamplerInfo> for SamplerInfo
[src]
fn eq(&self, other: &SamplerInfo) -> bool
[src]
fn ne(&self, other: &SamplerInfo) -> bool
[src]
impl PartialOrd<SamplerInfo> for SamplerInfo
[src]
fn partial_cmp(&self, other: &SamplerInfo) -> Option<Ordering>
[src]
#[must_use]pub fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
pub fn lt(&self, other: &Rhs) -> bool#[must_use]pub fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
pub fn le(&self, other: &Rhs) -> bool#[must_use]pub fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
pub fn gt(&self, other: &Rhs) -> bool#[must_use]pub fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]
pub fn ge(&self, other: &Rhs) -> boolimpl StructuralEq for SamplerInfo
[src]
impl StructuralPartialEq for SamplerInfo
[src]
Auto Trait Implementations
impl RefUnwindSafe for SamplerInfo
impl Send for SamplerInfo
impl Sync for SamplerInfo
impl Unpin for SamplerInfo
impl UnwindSafe for SamplerInfo
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,