DPC++ Runtime
Runtime libraries for oneAPI Data Parallel C++
cl::sycl::sampler Class Reference

Encapsulates a configuration for sampling an image accessor. More...

#include <CL/sycl/sampler.hpp>

Public Member Functions

 sampler (coordinate_normalization_mode normalizationMode, addressing_mode addressingMode, filtering_mode filteringMode, const property_list &propList={})
 
 sampler (cl_sampler clSampler, const context &syclContext)
 
 sampler (const sampler &rhs)=default
 
 sampler (sampler &&rhs)=default
 
sampleroperator= (const sampler &rhs)=default
 
sampleroperator= (sampler &&rhs)=default
 
bool operator== (const sampler &rhs) const
 
bool operator!= (const sampler &rhs) const
 
template<typename propertyT >
bool has_property () const
 Checks if this sampler has a property of type propertyT. More...
 
template<typename propertyT >
propertyT get_property () const
 Gets the specified property of this sampler. More...
 
addressing_mode get_addressing_mode () const
 
filtering_mode get_filtering_mode () const
 
coordinate_normalization_mode get_coordinate_normalization_mode () const
 

Friends

template<typename DataT , int Dimensions, cl::sycl::access::mode AccessMode, cl::sycl::access::target AccessTarget, access::placeholder IsPlaceholder>
class detail::image_accessor
 

Detailed Description

Encapsulates a configuration for sampling an image accessor.

See also
Accessors

Definition at line 65 of file sampler.hpp.

Constructor & Destructor Documentation

◆ sampler() [1/4]

cl::sycl::sampler::sampler ( coordinate_normalization_mode  normalizationMode,
addressing_mode  addressingMode,
filtering_mode  filteringMode,
const property_list propList = {} 
)

Definition at line 16 of file sampler.cpp.

◆ sampler() [2/4]

cl::sycl::sampler::sampler ( cl_sampler  clSampler,
const context syclContext 
)

Definition at line 22 of file sampler.cpp.

◆ sampler() [3/4]

cl::sycl::sampler::sampler ( const sampler rhs)
default

◆ sampler() [4/4]

cl::sycl::sampler::sampler ( sampler &&  rhs)
default

Member Function Documentation

◆ get_addressing_mode()

addressing_mode cl::sycl::sampler::get_addressing_mode ( ) const

Definition at line 25 of file sampler.cpp.

Referenced by cl::sycl::detail::imageReadSamplerHostImpl().

◆ get_coordinate_normalization_mode()

coordinate_normalization_mode cl::sycl::sampler::get_coordinate_normalization_mode ( ) const

Definition at line 34 of file sampler.cpp.

Referenced by cl::sycl::detail::imageReadSamplerHostImpl().

◆ get_filtering_mode()

filtering_mode cl::sycl::sampler::get_filtering_mode ( ) const

Definition at line 29 of file sampler.cpp.

Referenced by cl::sycl::detail::imageReadSamplerHostImpl().

◆ get_property()

template<typename propertyT >
propertyT cl::sycl::sampler::get_property ( ) const

Gets the specified property of this sampler.

Throws invalid_object_error if this sampler does not have a property of type propertyT.

Returns
a copy of the property of type propertyT.

◆ has_property()

template<typename propertyT >
bool cl::sycl::sampler::has_property ( ) const

Checks if this sampler has a property of type propertyT.

Returns
true if this sampler has a property of type propertyT.

◆ operator!=()

bool cl::sycl::sampler::operator!= ( const sampler rhs) const

Definition at line 42 of file sampler.cpp.

◆ operator=() [1/2]

sampler& cl::sycl::sampler::operator= ( const sampler rhs)
default

◆ operator=() [2/2]

sampler& cl::sycl::sampler::operator= ( sampler &&  rhs)
default

◆ operator==()

bool cl::sycl::sampler::operator== ( const sampler rhs) const

Definition at line 38 of file sampler.cpp.

Friends And Related Function Documentation

◆ detail::image_accessor

template<typename DataT , int Dimensions, cl::sycl::access::mode AccessMode, cl::sycl::access::target AccessTarget, access::placeholder IsPlaceholder>
friend class detail::image_accessor
friend

Definition at line 122 of file sampler.hpp.


The documentation for this class was generated from the following files: