24 #ifndef VISIONCPP_INCLUDE_FRAMEWORK_MEMORY_MEMORY_ACCESS_MEM_NEIGHBOUR_HPP_
25 #define VISIONCPP_INCLUDE_FRAMEWORK_MEMORY_MEMORY_ACCESS_MEM_NEIGHBOUR_HPP_
39 cl::sycl::local_ptr<T> &
ptr;
44 :
ptr(
ptr),
I_c(0),
I_r(0), cols(colsArg), rows(rowsArg) {}
88 cl::sycl::global_ptr<T> &
ptr;
107 c = (c >= 0 ? c : 0);
108 r = (r >= 0 ? r : 0);
126 cl::sycl::constant_ptr<T> &
ptr;
137 c = (c >= 0 ? c : 0);
138 r = (r >= 0 ? r : 0);
static size_t calculate_index(size_t c, size_t r, size_t cols, size_t rows)
function calculate_index
ConstNeighbour is used to provide global access to the constant memory.
cl::sycl::constant_ptr< T > & ptr
PixelType at(int c, int r) const
function at provides access to a specific coordinate for a 2d buffer parameters:
ConstNeighbour(cl::sycl::constant_ptr< T > &ptr, size_t colsArg, size_t rowsArg)
PixelType at(int c) const
function at provides access to an specific Coordinate for a 1d buffer parameters:
GlobalNeighbour is used to provide local access for each element of the global memory based on the Co...
cl::sycl::global_ptr< T > & ptr
GlobalNeighbour(cl::sycl::global_ptr< T > &ptr, size_t colsArg, size_t rowsArg)
void set_offset(int c, int r)
function set_offset:
PixelType at(int c, int r) const
function at provides access to a specific Coordinate for a 2d buffer parameters:
PixelType at(int c) const
function at provides access to a specific coordinate for a 1d buffer parameters:
LocalNeighbour is used to provide local access for each element of the local memory based on the Coor...
LocalNeighbour(cl::sycl::local_ptr< T > &ptr, size_t colsArg, size_t rowsArg)
cl::sycl::local_ptr< T > & ptr
PixelType at(int c) const
function at provides access to a specific Coordinate for a 1d buffer parameters:
PixelType at(int c, int r) const
function at provides access to a specific Coordinate for a 2d buffer parameters:
void set_offset(int c, int r)
function set_offset: