SoCudaConversion Class Reference
[CUDA algorithms]

VSG extension Type conversion functions for CUDA buffers More...

#include <Inventor/cuda/algorithms/SoConversion.h>

Inheritance diagram for SoCudaConversion:
SoConversion

List of all members.

Public Member Functions

 SoCudaConversion ()
virtual int convertFloatToRGBA (SoBufferObject *sourceBufferObject, SoBufferObject *targetBufferObject, const size_t size, const float dataMin, const float dataMax)
int convertFloatToRGBA (SoCudaBufferObject *sourceBufferObject, SoCudaBufferObject *targetBufferObject, const size_t size, const float dataMin, const float dataMax)
virtual int convert (SoBufferObject *sourceBufferObject, const SbDataType src_type, SoBufferObject *targetBufferObject, const SbDataType dst_type, const size_t size)
int convert (SoCudaBufferObject *sourceBufferObject, const SbDataType src_type, SoCudaBufferObject *targetBufferObject, const SbDataType dst_type, const size_t size)

Detailed Description

VSG extension Type conversion functions for CUDA buffers

This module provides data type conversions, like bytes to floats...

NOTE: The classes in this module do not exist in Open Inventor 10.0 and later.

Examples:


Constructor & Destructor Documentation

SoCudaConversion::SoCudaConversion (  ) 

Constructor.


Member Function Documentation

int SoCudaConversion::convert ( SoCudaBufferObject sourceBufferObject,
const SbDataType  src_type,
SoCudaBufferObject targetBufferObject,
const SbDataType  dst_type,
const size_t  size 
)

Convert the data in a buffer object from one data type to another one.


CUDA input version.

virtual int SoCudaConversion::convert ( SoBufferObject sourceBufferObject,
const SbDataType  src_type,
SoBufferObject targetBufferObject,
const SbDataType  dst_type,
const size_t  size 
) [virtual]

Convert the data in a buffer object from one data type to another one.


Notes: The destination buffer and the source buffers can be same.

Limitations: This function only supports FLOAT and UNSIGNED_BYTE for dst_type.

Parameters:
sourceBufferObject The source buffer object.
src_type The type of the data in the source buffer object.
targetBufferObject The destination buffer object.
dst_type The destination type.
size The number of elements in the source buffer object to convert.
Returns:
Returns 0 if there were no errors during the process. Returns 1 if one or more buffers don't have the correct size.

Reimplemented from SoConversion.

int SoCudaConversion::convertFloatToRGBA ( SoCudaBufferObject sourceBufferObject,
SoCudaBufferObject targetBufferObject,
const size_t  size,
const float  dataMin,
const float  dataMax 
)

Convert FLOAT data stored in a buffer to (grayscale) RGBA data.


Cuda input version.

virtual int SoCudaConversion::convertFloatToRGBA ( SoBufferObject sourceBufferObject,
SoBufferObject targetBufferObject,
const size_t  size,
const float  dataMin,
const float  dataMax 
) [virtual]

Convert FLOAT data stored in a buffer to (grayscale) RGBA data.

  • The source and the target buffers can be the same.
  • The algorithm maps float values between dataMin and dataMax to the range 0..255.
  • The resulting values are clamped to 0..255.
Parameters:
sourceBufferObject The source buffer object containing the FLOAT data.
targetBufferObject The target buffer object.
size The number of FLOAT values to convert.
dataMin The minimum value for the greyscale conversion.
dataMax The maximum value for the greyscale conversion.
Returns:
Returns 0 if there were no errors during the process. Returns 1 if one or more buffers don't have the correct size.

Reimplemented from SoConversion.


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

Open Inventor by FEI reference manual, generated on 19 Aug 2019
Copyright © FEI S.A.S. All rights reserved.
http://www.openinventor.com/