Medical Imaging Interaction Toolkit  2021.10.99-1c4db16f
Medical Imaging Interaction Toolkit
mitk::OclDataSet Class Reference

Class implementing processing of arbitrary data sets for GPU Image Processing. More...

#include <mitkOclDataSet.h>

Inheritance diagram for mitk::OclDataSet:
Collaboration diagram for mitk::OclDataSet:

Public Member Functions

 mitkClassMacro (OclDataSet, OclBaseData)
 
Pointer Clone () const
 
virtual int TransferDataToGPU (cl_command_queue)
 Copies the RAM-stored data to GMEM. More...
 
virtual void * TransferDataToCPU (cl_command_queue)
 Copies the in GMEM stored data to RAM. More...
 
void * GetData ()
 Returns the pointer to the referenced data. More...
 
cl_mem GetGPUBuffer ()
 
cl_mem CreateGPUBuffer ()
 
bool IsModified (int _type)
 Returns the status of the image buffer. More...
 
void Modified (int _type)
 Set the modified flag for one of the buffers. More...
 
void SetData (void *data)
 Initialze the OclDataSet with data. More...
 
vcl_size_t GetBufferSize () const
 returns the amount of elements in the DataSet More...
 
short GetBytesPerElement () const
 
void SetBufferSize (vcl_size_t size)
 Set the amount of elements in buffer. More...
 
void SetBpE (unsigned short BpE)
 Set the DataSet memory Size per Element in Bytes. More...
 
- Public Member Functions inherited from mitk::OclBaseData
 mitkClassMacroItkParent (OclBaseData, itk::Object)
 
void GPUModified ()
 Set the modified flag for one of the GPU buffer. More...
 
void CPUModified ()
 Set the modified flag for one of the CPU buffer. More...
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 OclDataSet ()
 Constructor. More...
 
virtual ~OclDataSet ()
 Destructor. More...
 
- Protected Member Functions inherited from mitk::OclBaseData
 OclBaseData ()
 Default constructor. More...
 
virtual ~OclBaseData ()
 Default destructor. More...
 

Protected Attributes

cl_mem m_gpuBuffer
 
cl_context m_context
 

Detailed Description

Class implementing processing of arbitrary data sets for GPU Image Processing.

The class holds a pointer to the data stored in RAM and performs an on-demand-copy to the graphics memory. It is the basic data structure for all mitk::oclDataSetToDataSetFilter classes

Definition at line 36 of file mitkOclDataSet.h.

Constructor & Destructor Documentation

◆ OclDataSet()

mitk::OclDataSet::OclDataSet ( )
protected

Constructor.

◆ ~OclDataSet()

virtual mitk::OclDataSet::~OclDataSet ( )
protectedvirtual

Destructor.

Member Function Documentation

◆ Clone()

Pointer mitk::OclDataSet::Clone ( ) const

◆ CreateGPUBuffer()

cl_mem mitk::OclDataSet::CreateGPUBuffer ( )

Create the GPU buffer for image

◆ GetBufferSize()

vcl_size_t mitk::OclDataSet::GetBufferSize ( ) const
inline

returns the amount of elements in the DataSet

Definition at line 86 of file mitkOclDataSet.h.

◆ GetBytesPerElement()

short mitk::OclDataSet::GetBytesPerElement ( ) const
inline

Definition at line 91 of file mitkOclDataSet.h.

◆ GetData()

void* mitk::OclDataSet::GetData ( )
inline

Returns the pointer to the referenced data.

Definition at line 50 of file mitkOclDataSet.h.

◆ GetGPUBuffer()

cl_mem mitk::OclDataSet::GetGPUBuffer ( )
virtual

Returns the pointer to the GPU buffer

Reimplemented from mitk::OclBaseData.

◆ IsModified()

bool mitk::OclDataSet::IsModified ( int  _type)

Returns the status of the image buffer.

Parameters
_typeThe flag to specify the buffer type ( GPU / CPU )

◆ mitkClassMacro()

mitk::OclDataSet::mitkClassMacro ( OclDataSet  ,
OclBaseData   
)

◆ Modified()

void mitk::OclDataSet::Modified ( int  _type)

Set the modified flag for one of the buffers.

Parameters
_typeThe flag to specify the buffer type ( GPU / CPU )

◆ New()

static Pointer mitk::OclDataSet::New ( )
static

◆ SetBpE()

void mitk::OclDataSet::SetBpE ( unsigned short  BpE)

Set the DataSet memory Size per Element in Bytes.

◆ SetBufferSize()

void mitk::OclDataSet::SetBufferSize ( vcl_size_t  size)

Set the amount of elements in buffer.

◆ SetData()

void mitk::OclDataSet::SetData ( void *  data)
inline

Initialze the OclDataSet with data.

Definition at line 78 of file mitkOclDataSet.h.

◆ TransferDataToCPU()

virtual void* mitk::OclDataSet::TransferDataToCPU ( cl_command_queue  )
virtual

Copies the in GMEM stored data to RAM.

Implements mitk::OclBaseData.

◆ TransferDataToGPU()

virtual int mitk::OclDataSet::TransferDataToGPU ( cl_command_queue  )
virtual

Copies the RAM-stored data to GMEM.

Implements mitk::OclBaseData.

Member Data Documentation

◆ m_context

cl_context mitk::OclDataSet::m_context
protected

GPU Context the Buffer was created in, needed for access

Definition at line 113 of file mitkOclDataSet.h.

◆ m_gpuBuffer

cl_mem mitk::OclDataSet::m_gpuBuffer
protected

GMEM Image buffer

Definition at line 110 of file mitkOclDataSet.h.


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