go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
Protected Member Functions | Protected Attributes | Friends
itk::OpenCLVectorBase Class Reference

#include <itkOpenCLVectorBase.h>

Detailed Description

The base class for the OpenCLVector implementation.

See also
OpenCLVector

Definition at line 37 of file itkOpenCLVectorBase.h.

+ Inheritance diagram for itk::OpenCLVectorBase:

Protected Member Functions

void Assign (const OpenCLVectorBase &other)
 
void Create (OpenCLContext *context, const OpenCLMemoryObject::Access access, const std::vcl_size_t size)
 
OpenCLContextGetContext () const
 
cl_mem GetKernelArgument () const
 
cl_mem GetMemoryId () const
 
void Map ()
 
 OpenCLVectorBase (const std::vcl_size_t elemSize)
 
 OpenCLVectorBase (const std::vcl_size_t elemSize, const OpenCLVectorBase &other)
 
void Read (void *data, const std::vcl_size_t size, const std::vcl_size_t offset=0)
 
void Release ()
 
void Unmap () const
 
void Write (const void *data, const std::vcl_size_t size, const std::vcl_size_t offset=0)
 
 ~OpenCLVectorBase ()
 

Protected Attributes

OpenCLVectorBasePimpl * d_ptr
 
std::vcl_size_t m_ElementSize
 
void * m_Mapped
 
std::vcl_size_t m_Size
 

Friends

class OpenCLKernel
 

Constructor & Destructor Documentation

◆ OpenCLVectorBase() [1/2]

itk::OpenCLVectorBase::OpenCLVectorBase ( const std::vcl_size_t  elemSize)
protected

Creates a vector with elemSize.

◆ OpenCLVectorBase() [2/2]

itk::OpenCLVectorBase::OpenCLVectorBase ( const std::vcl_size_t  elemSize,
const OpenCLVectorBase other 
)
protected

Creates a copy of the other vector reference with elemSize. The vector's contents are not duplicated, modifications to this vector will also affect other.

◆ ~OpenCLVectorBase()

itk::OpenCLVectorBase::~OpenCLVectorBase ( )
protected

Destroys this vector reference. If this is the last reference to the underlying data, the vector will be unmapped and deallocated.

Member Function Documentation

◆ Assign()

void itk::OpenCLVectorBase::Assign ( const OpenCLVectorBase other)
protected

Assign vector and take ownership.

◆ Create()

void itk::OpenCLVectorBase::Create ( OpenCLContext context,
const OpenCLMemoryObject::Access  access,
const std::vcl_size_t  size 
)
protected

A vector object is created using the following method.

◆ GetContext()

OpenCLContext * itk::OpenCLVectorBase::GetContext ( ) const
protected

Returns the OpenCL context that created this memory object.

◆ GetKernelArgument()

cl_mem itk::OpenCLVectorBase::GetKernelArgument ( ) const
protected

Unmaps and returns the native OpenCL identifier for this memory object.

◆ GetMemoryId()

cl_mem itk::OpenCLVectorBase::GetMemoryId ( ) const
protected

Returns the native OpenCL identifier for this memory object.

◆ Map()

void itk::OpenCLVectorBase::Map ( )
protected

Enqueues a command to map a region of the buffer object given by buffer into the host address.

See also
Unmap()

◆ Read()

void itk::OpenCLVectorBase::Read ( void *  data,
const std::vcl_size_t  size,
const std::vcl_size_t  offset = 0 
)
protected

The following functions enqueue commands to read from a buffer object to host memory.

See also
Write()

◆ Release()

void itk::OpenCLVectorBase::Release ( )
protected

Decrements the memobj reference count.

◆ Unmap()

void itk::OpenCLVectorBase::Unmap ( ) const
protected

Enqueues a command to unmap a previously mapped region of a memory object.

See also
Map()

◆ Write()

void itk::OpenCLVectorBase::Write ( const void *  data,
const std::vcl_size_t  size,
const std::vcl_size_t  offset = 0 
)
protected

The following functions enqueue commands to write from a buffer object to host memory.

See also
Read()

Friends And Related Function Documentation

◆ OpenCLKernel

friend class OpenCLKernel
friend

friends from OpenCL core

Definition at line 97 of file itkOpenCLVectorBase.h.

Field Documentation

◆ d_ptr

OpenCLVectorBasePimpl* itk::OpenCLVectorBase::d_ptr
protected

Definition at line 91 of file itkOpenCLVectorBase.h.

◆ m_ElementSize

std::vcl_size_t itk::OpenCLVectorBase::m_ElementSize
protected

Definition at line 92 of file itkOpenCLVectorBase.h.

◆ m_Mapped

void* itk::OpenCLVectorBase::m_Mapped
mutableprotected

Definition at line 94 of file itkOpenCLVectorBase.h.

◆ m_Size

std::vcl_size_t itk::OpenCLVectorBase::m_Size
protected

Definition at line 93 of file itkOpenCLVectorBase.h.



Generated on 1667476801 for elastix by doxygen 1.9.4 elastix logo