cl::sycl::sampler Class Reference
Public sampler class. More...
#include <sampler.h>
Public Member Functions | |
COMPUTECPP_DEPRECATED_API ("sampler::sampler(bool, addressing_mode, filtering_mode) deprecated. Use" "sampler::sampler(coordinate_normalization_mode, addressing_mode," "filtering_mode) instead.") sampler(const bool normalizedCoords | |
Constructor that creates a sampler from the sampler addressing mode sampler filter mode and a boolean specifying whether normalized coordinates are enabled. More... | |
COMPUTECPP_DEPRECATED_API ("sampler(cl_sampler) deprecated in SYCL 1.2.1, " "please also provide a SYCL context") explicit sampler(cl_sampler clSampler) | |
Inter-op constructor that creates a sampler from a cl_sampler object. More... | |
sampler (cl_sampler clSampler, const context &syclContext) | |
Inter-op constructor that creates a sampler from a cl_sampler object. More... | |
sampler (const cl::sycl::sampler &rhs) | |
Default copy constructor. More... | |
sampler (cl::sycl::sampler &&rhs) noexcept | |
Default move constructor. More... | |
~sampler ()=default | |
Default destructor. More... | |
sampler & | operator= (const cl::sycl::sampler &rhs) |
Default assignment operator. More... | |
sampler & | operator= (cl::sycl::sampler &&rhs) noexcept |
Default move assignment operator. More... | |
bool | is_host () const |
Returns true if this sampler is a host sampler. More... | |
addressing_mode | get_addressing_mode () const |
Get the addressing mode. More... | |
filtering_mode | get_filtering_mode () const |
Get the filter mode. More... | |
coordinate_normalization_mode | get_coordinate_normalization_mode () const |
Get the coordinate normalization mode. More... | |
cl_sampler | get () const |
Get the sampler object for OpenCL. More... | |
dsampler_shptr | get_impl () const |
Get implementation object. More... | |
Public Attributes | |
const addressing_mode | addressMode |
const addressing_mode const filtering_mode | filterMode: sampler{normalizedCoords ? coordinate_normalization_mode::normalized : coordinate_normalization_mode::unnormalized |
const addressing_mode const filtering_mode | addressMode |
Friends | |
bool | operator== (const cl::sycl::sampler &lhs, const cl::sycl::sampler &rhs) |
Determines if lhs and rhs are equal. More... | |
bool | operator!= (const sampler &lhs, const sampler &rhs) |
Determines if lhs and rhs are not equal. More... | |
Detailed Description
Public sampler class.
Encapsulates an OpenCL sampler and host device sampler.
Constructor & Destructor Documentation
◆ sampler() [1/3]
cl::sycl::sampler::sampler | ( | cl_sampler | clSampler, |
const context & | syclContext | ||
) |
Inter-op constructor that creates a sampler from a cl_sampler object.
- Parameters
-
clSampler OpenCL cl_sampler object syclContext Context associated with the OpenCL sampler object
◆ sampler() [2/3]
|
inline |
◆ sampler() [3/3]
|
inlinenoexcept |
◆ ~sampler()
|
default |
Default destructor.
Member Function Documentation
◆ COMPUTECPP_DEPRECATED_API() [1/2]
cl::sycl::sampler::COMPUTECPP_DEPRECATED_API | ( | "sampler::sampler(bool, addressing_mode, filtering_mode) deprecated. Use" "sampler::sampler(coordinate_normalization_mode, addressing_mode," "filtering_mode) instead." | ) | const |
Constructor that creates a sampler from the sampler addressing mode sampler filter mode and a boolean specifying whether normalized coordinates are enabled.
- Parameters
-
normalizedCoords Boolean specifying whether normalized coordinates are enabled. addressMode The sampler addressing mode. filterMode The sampler filter mode.
- Deprecated:
- Use sampler::sampler(coordinate_normalization_mode, addressing_mode, filtering_mode) instead.
◆ COMPUTECPP_DEPRECATED_API() [2/2]
cl::sycl::sampler::COMPUTECPP_DEPRECATED_API | ( | "sampler(cl_sampler) deprecated in SYCL 1.2. | 1, |
" "please also provide a SYCL context" | |||
) |
Inter-op constructor that creates a sampler from a cl_sampler object.
- Parameters
-
clSampler OpenCL cl_sampler object/
- Deprecated:
- Please also provide a SYCL context
◆ get()
cl_sampler cl::sycl::sampler::get | ( | ) | const |
Get the sampler object for OpenCL.
- Returns
- The OpenCL sampler that is associated with the latest context the sampler was used in.
◆ get_addressing_mode()
addressing_mode cl::sycl::sampler::get_addressing_mode | ( | ) | const |
Get the addressing mode.
- Returns
- Sampler addressing mode.
◆ get_coordinate_normalization_mode()
coordinate_normalization_mode cl::sycl::sampler::get_coordinate_normalization_mode | ( | ) | const |
Get the coordinate normalization mode.
- Returns
- Sampler normalization mode.
◆ get_filtering_mode()
filtering_mode cl::sycl::sampler::get_filtering_mode | ( | ) | const |
Get the filter mode.
- Returns
- Sampler filter mode.
◆ get_impl()
dsampler_shptr cl::sycl::sampler::get_impl | ( | ) | const |
Get implementation object.
- Returns
- Implementation shared_ptr.
◆ is_host()
bool cl::sycl::sampler::is_host | ( | ) | const |
Returns true if this sampler is a host sampler.
- Returns
- True is a host sampler, false otherwise
◆ operator=() [1/2]
|
inline |
◆ operator=() [2/2]
|
inlinenoexcept |
Friends And Related Function Documentation
◆ operator!=
◆ operator==
|
friend |
Member Data Documentation
◆ addressMode [1/2]
const addressing_mode cl::sycl::sampler::addressMode |
◆ addressMode [2/2]
const addressing_mode const filtering_mode cl::sycl::sampler::addressMode |
◆ filterMode
const addressing_mode const filtering_mode cl::sycl::sampler::filterMode |
{} sampler(coordinate_normalization_mode normalizedCoords, const property_list& propList = {})
The documentation for this class was generated from the following file: