LDM buffer object optimized for in memory reader tile data. More...
#include <LDM/tiles/SoCpuBufferFromVolumeReader.h>
Public Member Functions | |
SoCpuBufferFromVolumeReader (SoDataSet *dataset, SoLDMTileID tileId) | |
Constructor with dataset and tile Id as parameter. | |
virtual void | map (SoBufferObject *targetBufferObject, SoBufferObject::AccessMode accessMode, size_t startPosition, size_t mappingSize=SO_BUFFER_SIZE_ALL) |
Map the current buffer object into the specified buffer object. | |
virtual void | map (SoCpuBufferObject *targetBufferObject, SoBufferObject::AccessMode accessMode, size_t startPosition=0, size_t mappingSize=SO_BUFFER_SIZE_ALL) |
Map the current buffer object into the specified CPU buffer object. | |
virtual void | map (SoGLBufferObject *targetBufferObject, SoBufferObject::AccessMode accessMode, size_t startPosition=0, size_t mappingSize=SO_BUFFER_SIZE_ALL) |
Map the current buffer object into the specified GL buffer object. | |
virtual void * | map (SoBufferObject::AccessMode accessMode, size_t offset=0, size_t count=SO_BUFFER_SIZE_ALL) |
Map the buffer to a system memory address and allows the mapping of a sub part of the buffer object into CPU memory. | |
virtual void | unmap (SoCpuBufferObject *bufferObject) |
Unmap the specified CPU buffer object It is defined just to speed up the call when the type of the object is known. | |
virtual void | unmap (SoGLBufferObject *bufferObject) |
Unmap the specified GL buffer object It is defined just to speed up the call when the type of the object is known. | |
void | unmap (SoBufferObject *bufferObject) |
Unmap the specified buffer object It is defined just to speed up the call when the type of the object is known. | |
virtual void | unmap () |
Unmap a mapped buffer. | |
bool | getMinMax (double &min, double &max) |
Get the min and max values in the buffer, if they are known. | |
size_t | getRealSize () const |
Returns the real size of the buffer in bytes. | |
Public Member Functions inherited from SoCpuBufferObject | |
SoCpuBufferObject () | |
Default constructor. | |
SoCpuBufferObject (void *buffer, size_t size) | |
Constructor that takes an existing block of CPU memory. | |
void | setBuffer (void *buffer, size_t size) |
Request that the buffer object manage an existing block of memory. | |
virtual SoBufferObject * | createInstance () const |
Create a new buffer with the same properties as the current one. | |
virtual void | clearInstance () |
This function clears the content of the buffer, it frees the memory if the mode was COPY. | |
Public Member Functions inherited from SoBufferObject | |
void | lockBuffer () |
Locks the buffer against concurrent calls from different threads. | |
void | unlockBuffer () |
Unlocks the buffer object. | |
virtual bool | setSize (size_t size) |
Sets the size in bytes of the buffer object. | |
virtual size_t | getSize () const |
Returns the size, in bytes, of the buffer object. | |
virtual void | memcpy (SoBufferObject *sourceBufferObject, size_t destOffset=0, size_t sourceOffset=0, size_t copySize=SO_BUFFER_SIZE_ALL) |
Copies data from the specified buffer object into this buffer object. | |
virtual void | memset (void *value, size_t valueSize=1, size_t offset=0, size_t count=SO_BUFFER_SIZE_ALL) |
This function sets the contents of (or a portion of) this buffer object to the specified value. | |
SoDeviceContext * | getContext () const |
Returns the device context where this buffer is valid. | |
SoBufferObject * | getMappedBufferObject () const |
Returns a pointer to the buffer object which is mapped by the actual object. | |
AccessMode | getMappedBufferObjectAccessMode () |
Returns the access mode used for the buffer mapping. | |
size_t | getMappedBufferObjectPosition () const |
Returns the position in the source buffer mapped in this buffer. | |
size_t | getMappedBufferObjectSize () const |
Returns the size of the mapped area in bytes. | |
Public Member Functions inherited from SoRefCounter | |
void | ref () const |
Adds a reference to an instance. | |
void | unref () const |
Removes a reference from an instance. | |
void | unrefNoDelete () const |
unrefNoDelete() should be called when it is desired to decrement the reference count, but not delete the instance if this brings the reference count to zero. | |
int | getRefCount () const |
Returns current reference count. | |
void | lock () const |
lock this instance. | |
void | unlock () const |
unlock this instance. | |
Public Member Functions inherited from SoTypedObject | |
virtual SoType | getTypeId () const =0 |
Returns the type identifier for a specific instance. | |
SbBool | isOfType (const SoType &type) const |
Returns TRUE if this object is of the type specified in type or is derived from that type. | |
template<typename TypedObjectClass > | |
SbBool | isOfType () const |
Returns TRUE if this object is of the type of class TypedObjectClass or is derived from that class. | |
Public Member Functions inherited from SoBufferPropertiesInterface | |
SoBufferPropertiesInterface () | |
Default constructor. | |
virtual | ~SoBufferPropertiesInterface () |
Destructor. | |
Public Member Functions inherited from SoLDMBufferObjectInterface | |
SoLDMBufferObjectInterface () | |
Default constructor. | |
virtual | ~SoLDMBufferObjectInterface () |
Destructor. | |
virtual void | prefetch () |
Simply expand the given buffer to OIV cache. | |
Friends | |
class | SoCpuBufferFromVolumeReaderImpl |
Additional Inherited Members | |
Public Types inherited from SoBufferObject | |
enum | AccessMode { READ_ONLY , SET , READ_WRITE } |
This enum provides the possible access modes for a mapped buffer object. More... | |
Static Public Member Functions inherited from SoBufferObject | |
static SoCpuBufferObjectCache * | getBufferObjectCache () |
Returns the cache manager object. | |
Static Public Member Functions inherited from SoTypedObject | |
static SoType | getClassTypeId () |
Returns the type identifier for this class. | |
LDM buffer object optimized for in memory reader tile data.
SoBufferPropertiesInterface, SoCpuBufferObject
Definition at line 45 of file SoCpuBufferFromVolumeReader.h.
SoCpuBufferFromVolumeReader::SoCpuBufferFromVolumeReader | ( | SoDataSet * | dataset, |
SoLDMTileID | tileId | ||
) |
Constructor with dataset and tile Id as parameter.
dataset | pointer to dataset associated with buffer |
tileId | tileId representing the tile the buffer will store |
|
virtual |
Get the min and max values in the buffer, if they are known.
Returns false if these values have not been set or computed. Returns true if values are available.
min | user variable to store min value |
max | user variable to store max value |
Implements SoBufferPropertiesInterface.
|
virtual |
Returns the real size of the buffer in bytes.
Implements SoBufferPropertiesInterface.
|
virtual |
Map the current buffer object into the specified buffer object.
It is useful in order to use a buffer in multiple contexts.
targetBufferObject | The buffer object which will be the mapped version of this buffer. |
accessMode | The access mode used for the mapping. |
startPosition | offset in source buffer to map from (default is start of buffer). |
mappingSize | size from the startPosition, if SO_BUFFER_SIZE_ALL then the whole buffer is mapped. |
Reimplemented from SoBufferObject.
|
virtual |
Map the buffer to a system memory address and allows the mapping of a sub part of the buffer object into CPU memory.
Notes:
Reimplemented from SoBufferObject.
|
virtual |
Map the current buffer object into the specified CPU buffer object.
See the general map method for more information.
|
virtual |
Map the current buffer object into the specified GL buffer object.
See the general map method for more information.
|
virtual |
Unmap a mapped buffer.
No error is reported if the buffer was not mapped.
Reimplemented from SoBufferObject.
|
virtual |
Unmap the specified buffer object
It is defined just to speed up the call when the type of the object is known.
See the general unmap function for more information.
Reimplemented from SoBufferObject.
|
virtual |
Unmap the specified CPU buffer object
It is defined just to speed up the call when the type of the object is known.
Remove the specified bufferObject from the list of buffers which map the current buffer.
See the general unmap function for more information.
|
virtual |
Unmap the specified GL buffer object
It is defined just to speed up the call when the type of the object is known.
If the access mode supports writing the specified buffer is sync'd with the buffer.
See the general unmap function for more information.
bufferObject | Buffer to be unmapped. |
|
friend |
Definition at line 161 of file SoCpuBufferFromVolumeReader.h.