Struct ocl::Sampler
[−]
[src]
#[repr(C)]pub struct Sampler(_);
An image sampler used to process images.
Methods
impl Sampler
[src]
fn new(
context: &Context,
normalize_coords: bool,
addressing_mode: AddressingMode,
filter_mode: FilterMode
) -> OclResult<Sampler>
context: &Context,
normalize_coords: bool,
addressing_mode: AddressingMode,
filter_mode: FilterMode
) -> OclResult<Sampler>
Creates and returns a new sampler.
Enum Quick Reference
addressing_mode
:
- AddressingMode::None
- AddressingMode::ClampToEdge
- AddressingMode::Clamp
- AddressingMode::Repeat
- AddressingMode::MirroredRepeat
filter_mode
:
- FilterMode::Nearest
- FilterMode::Linear
See SDK Docs for more information.
fn with_defaults(context: &Context) -> OclResult<Sampler>
Creates and returns a new sampler with some default settings.
Defaults
normalize_coords
: falseaddressing_mode
:AddressingMode::None
filter_mode
:FilterMode::Nearest
fn info(&self, info_kind: SamplerInfo) -> SamplerInfoResult
Returns various kinds of information about the sampler.
Methods from Deref<Target = SamplerCore>
Trait Implementations
impl Display for Sampler
[src]
impl Deref for Sampler
[src]
type Target = SamplerCore
The resulting type after dereferencing
fn deref(&self) -> &SamplerCore
The method called to dereference a value
impl DerefMut for Sampler
[src]
fn deref_mut(&mut self) -> &mut SamplerCore
The method called to mutably dereference a value