HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GA_AIFTuple Class Referenceabstract

Generic Attribute Interface class to access an attribute as a tuple. More...

#include <GA_AIFTuple.h>

Public Member Functions

 GA_AIFTuple ()
 
virtual ~GA_AIFTuple ()
 
virtual bool getRangeInContainer (const GA_Attribute *attrib, const GA_Range &range, std::vector< int32 > &data, int start=0, int tuple_size=-1) const
 
virtual bool getRangeInContainer (const GA_Attribute *attrib, const GA_Range &range, std::vector< int64 > &data, int start=0, int tuple_size=-1) const
 
virtual bool getRangeInContainer (const GA_Attribute *attrib, const GA_Range &range, std::vector< fpreal32 > &data, int start=0, int tuple_size=-1) const
 
virtual bool getRangeInContainer (const GA_Attribute *attrib, const GA_Range &range, std::vector< fpreal64 > &data, int start=0, int tuple_size=-1) const
 
virtual const GA_Defaults getDefaults (const GA_Attribute *attrib) const =0
 Return the default values for the attribute. More...
 
virtual bool set (GA_Attribute &dest, GA_Offset di, const GA_Attribute &src, GA_Offset si, int component=-1) const =0
 Copy values from the source attribute to this attribute. More...
 
virtual bool set (GA_Attribute &dest, const GA_Range &di, const GA_Attribute &src, const GA_Range &si, int component=-1) const =0
 Copy values from the source attribute to this attribute. More...
 
virtual int getTupleSize (const GA_Attribute *attrib) const =0
 
virtual bool setTupleSize (GA_Attribute *attrib, int size) const =0
 
virtual GA_Storage getStorage (const GA_Attribute *attrib) const =0
 
virtual bool setStorage (GA_Attribute *attrib, GA_Storage storage) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, int32 data, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, int64 data, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, fpreal32 data, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, fpreal64 data, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, const int32 *data, int len, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, const int64 *data, int len, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, const fpreal32 *data, int len, int index=0) const =0
 
virtual bool makeConstant (GA_Attribute *attrib, const fpreal64 *data, int len, int index=0) const =0
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, int32 &data, int index=0) const =0
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, int64 &data, int index=0) const =0
 Get a single value from a single offset in an attribute array. More...
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, fpreal32 &data, int index=0) const =0
 Get a single value from a single offset in an attribute array. More...
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, fpreal64 &data, int index=0) const =0
 Get a single value from a single offset in an attribute array. More...
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, int32 *data, int count, int start=0) const =0
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, int64 *data, int count, int start=0) const =0
 Get a tuple of values from a single array element. More...
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, fpreal32 *data, int count, int start=0) const =0
 Get a tuple of values from a single array element. More...
 
virtual bool get (const GA_Attribute *attrib, GA_Offset ai, fpreal64 *data, int count, int start=0) const =0
 Get a tuple of values from a single array element. More...
 
virtual bool getRange (const GA_Attribute *attrib, const GA_Range &range, int32 *result, int start=0, int tuple_size=-1) const
 
virtual bool getRange (const GA_Attribute *attrib, const GA_Range &range, int64 *result, int start=0, int tuple_size=-1) const
 
virtual bool getRange (const GA_Attribute *attrib, const GA_Range &range, fpreal32 *result, int start=0, int tuple_size=-1) const
 
virtual bool getRange (const GA_Attribute *attrib, const GA_Range &range, fpreal64 *result, int start=0, int tuple_size=-1) const
 
template<typename T >
bool getRangeTuple (const GA_Attribute *attrib, const GA_Range &range, T *result, int start=0, typename SYS_EnableIf< SYS_IsArithmetic_v< T > >::type *dummy=0) const
 
template<typename T >
bool getRangeTuple (const GA_Attribute *attrib, const GA_Range &range, T *result, int start=0, typename SYS_DisableIf< SYS_IsArithmetic_v< T > >::type *dummy=0) const
 
virtual bool isNan (const GA_Attribute *attrib, GA_Offset ai) const =0
 
virtual bool isNan (const GA_Attribute *attrib, const GA_Range &it) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, int32 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, int64 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, fpreal32 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, fpreal64 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, int32 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, int64 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, fpreal32 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, fpreal64 data, int comp=-1) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, const int32 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, const int64 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, const fpreal32 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, GA_Offset ai, const fpreal64 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, const int32 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, const int64 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, const fpreal32 *data, int count, int start=0) const =0
 
virtual bool set (GA_Attribute *attrib, const GA_Range &ai, const fpreal64 *data, int count, int start=0) const =0
 
virtual bool setRange (GA_Attribute *attrib, const GA_Range &it, const int32 *data, int start=0, int tuple_size=-1) const
 
virtual bool setRange (GA_Attribute *attrib, const GA_Range &it, const int64 *data, int start=0, int tuple_size=-1) const
 
virtual bool setRange (GA_Attribute *attrib, const GA_Range &it, const fpreal32 *data, int start=0, int tuple_size=-1) const
 
virtual bool setRange (GA_Attribute *attrib, const GA_Range &it, const fpreal64 *data, int start=0, int tuple_size=-1) const
 
template<typename T >
bool setRangeTuple (GA_Attribute *attrib, const GA_Range &range, const T *data, int start=0, typename SYS_EnableIf< SYS_IsArithmetic_v< T > >::type *dummy=0) const
 
template<typename T >
bool setRangeTuple (GA_Attribute *attrib, const GA_Range &range, const T *data, int start=0, typename SYS_DisableIf< SYS_IsArithmetic_v< T > >::type *dummy=0) const
 
virtual bool homogenize (GA_Attribute &dest, GA_Offset di) const
 
virtual bool dehomogenize (GA_Attribute &dest, GA_Offset di) const
 

Detailed Description

Generic Attribute Interface class to access an attribute as a tuple.

This class provides the interface to access attribute data. Each attribute type may provide this interface if it makes sense.

Definition at line 32 of file GA_AIFTuple.h.

Constructor & Destructor Documentation

GA_AIFTuple::GA_AIFTuple ( )
virtual GA_AIFTuple::~GA_AIFTuple ( )
virtual

Member Function Documentation

virtual bool GA_AIFTuple::dehomogenize ( GA_Attribute dest,
GA_Offset  di 
) const
virtual

Dehomogenize (divide through by the last element of the tuple)

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
int32 data,
int  index = 0 
) const
pure virtual

Get a single value from a single offset in an attribute array.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
int64 data,
int  index = 0 
) const
pure virtual

Get a single value from a single offset in an attribute array.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
fpreal32 data,
int  index = 0 
) const
pure virtual

Get a single value from a single offset in an attribute array.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
fpreal64 data,
int  index = 0 
) const
pure virtual

Get a single value from a single offset in an attribute array.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
int32 data,
int  count,
int  start = 0 
) const
pure virtual

Get a tuple of values from a single array element, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
int64 data,
int  count,
int  start = 0 
) const
pure virtual

Get a tuple of values from a single array element.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
fpreal32 data,
int  count,
int  start = 0 
) const
pure virtual

Get a tuple of values from a single array element.

virtual bool GA_AIFTuple::get ( const GA_Attribute attrib,
GA_Offset  ai,
fpreal64 data,
int  count,
int  start = 0 
) const
pure virtual

Get a tuple of values from a single array element.

virtual const GA_Defaults GA_AIFTuple::getDefaults ( const GA_Attribute attrib) const
pure virtual

Return the default values for the attribute.

virtual bool GA_AIFTuple::getRange ( const GA_Attribute attrib,
const GA_Range range,
int32 result,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute. The result array must have been preallocated. If tuple_size is not positive, the tuple size is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied to the result array for each element

Definition at line 109 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRange ( const GA_Attribute attrib,
const GA_Range range,
int64 result,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute. The result array must have been preallocated.

Definition at line 115 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRange ( const GA_Attribute attrib,
const GA_Range range,
fpreal32 result,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute. The result array must have been preallocated.

Definition at line 121 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRange ( const GA_Attribute attrib,
const GA_Range range,
fpreal64 result,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute. The result array must have been preallocated.

Definition at line 127 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRangeInContainer ( const GA_Attribute attrib,
const GA_Range range,
std::vector< int32 > &  data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute into a flattened std::vector of the appropriate type.

Definition at line 159 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRangeInContainer ( const GA_Attribute attrib,
const GA_Range range,
std::vector< int64 > &  data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute into a flattened std::vector of the appropriate type.

Definition at line 166 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRangeInContainer ( const GA_Attribute attrib,
const GA_Range range,
std::vector< fpreal32 > &  data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute into a flattened std::vector of the appropriate type.

Definition at line 173 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::getRangeInContainer ( const GA_Attribute attrib,
const GA_Range range,
std::vector< fpreal64 > &  data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Get an array of values from a selection of elements from the attribute into a flattened std::vector of the appropriate type.

Definition at line 180 of file GA_AIFTuple.h.

template<typename T >
bool GA_AIFTuple::getRangeTuple ( const GA_Attribute attrib,
const GA_Range range,
T result,
int  start = 0,
typename SYS_EnableIf< SYS_IsArithmetic_v< T > >::type dummy = 0 
) const
inline

Templated version of getRange() which allows for both arithmetic types as well as UT_Vector[234] UT_Matrix[234], UT_Quaternion[FD] types.

Definition at line 136 of file GA_AIFTuple.h.

template<typename T >
bool GA_AIFTuple::getRangeTuple ( const GA_Attribute attrib,
const GA_Range range,
T result,
int  start = 0,
typename SYS_DisableIf< SYS_IsArithmetic_v< T > >::type dummy = 0 
) const
inline

Get an array of values from a selection of elements from the attribute. The result array must have been preallocated. If tuple_size is not positive, the tuple size is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied to the result array for each element

Definition at line 146 of file GA_AIFTuple.h.

virtual GA_Storage GA_AIFTuple::getStorage ( const GA_Attribute attrib) const
pure virtual

Query and set some tuple intrisics.

virtual int GA_AIFTuple::getTupleSize ( const GA_Attribute attrib) const
pure virtual

Query and set some tuple intrisics.

virtual bool GA_AIFTuple::homogenize ( GA_Attribute dest,
GA_Offset  di 
) const
virtual

Homogenize the tuple (i.e. multiply through by the last element of the tuple).

virtual bool GA_AIFTuple::isNan ( const GA_Attribute attrib,
GA_Offset  ai 
) const
pure virtual

Test if any elements are NAN's

virtual bool GA_AIFTuple::isNan ( const GA_Attribute attrib,
const GA_Range it 
) const
pure virtual

Test if any elements are NAN's

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
int32  data,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
int64  data,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
fpreal32  data,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
fpreal64  data,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
const int32 data,
int  len,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
const int64 data,
int  len,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
const fpreal32 data,
int  len,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::makeConstant ( GA_Attribute attrib,
const fpreal64 data,
int  len,
int  index = 0 
) const
pure virtual

Make the attribute constant

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
int32  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
int64  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
fpreal32  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
fpreal64  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
int32  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
int64  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
fpreal32  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
fpreal64  data,
int  comp = -1 
) const
pure virtual

Set a component of a single element of the array. If the component is -1, all elements of the tuple will be set to the value.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
const int32 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
const int64 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
const fpreal32 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
GA_Offset  ai,
const fpreal64 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
const int32 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
const int64 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
const fpreal32 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute attrib,
const GA_Range ai,
const fpreal64 data,
int  count,
int  start = 0 
) const
pure virtual

Set a single element of the attribute to a tuple of values, starting at the (optionally) specified component.

virtual bool GA_AIFTuple::set ( GA_Attribute dest,
GA_Offset  di,
const GA_Attribute src,
GA_Offset  si,
int  component = -1 
) const
pure virtual

Copy values from the source attribute to this attribute.

virtual bool GA_AIFTuple::set ( GA_Attribute dest,
const GA_Range di,
const GA_Attribute src,
const GA_Range si,
int  component = -1 
) const
pure virtual

Copy values from the source attribute to this attribute.

virtual bool GA_AIFTuple::setRange ( GA_Attribute attrib,
const GA_Range it,
const int32 data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Set a selection of attributes to elements from an array of values. If the tuple size is not positive, it is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied from the array for each element.

Definition at line 271 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::setRange ( GA_Attribute attrib,
const GA_Range it,
const int64 data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Set a selection of attributes to elements from an array of values. If the tuple size is not positive, it is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied from the array for each element.

Definition at line 277 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::setRange ( GA_Attribute attrib,
const GA_Range it,
const fpreal32 data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Set a selection of attributes to elements from an array of values. If the tuple size is not positive, it is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied from the array for each element.

Definition at line 283 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::setRange ( GA_Attribute attrib,
const GA_Range it,
const fpreal64 data,
int  start = 0,
int  tuple_size = -1 
) const
inlinevirtual

Set a selection of attributes to elements from an array of values. If the tuple size is not positive, it is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied from the array for each element.

Definition at line 289 of file GA_AIFTuple.h.

template<typename T >
bool GA_AIFTuple::setRangeTuple ( GA_Attribute attrib,
const GA_Range range,
const T data,
int  start = 0,
typename SYS_EnableIf< SYS_IsArithmetic_v< T > >::type dummy = 0 
) const
inline

Templated version of setRange() which allows for both arithmetic types as well as UT_Vector[234] UT_Matrix[234], UT_Quaternion[FD] types.

Note
Like setRange(), sets from an array of range.getEntries() values

Definition at line 301 of file GA_AIFTuple.h.

template<typename T >
bool GA_AIFTuple::setRangeTuple ( GA_Attribute attrib,
const GA_Range range,
const T data,
int  start = 0,
typename SYS_DisableIf< SYS_IsArithmetic_v< T > >::type dummy = 0 
) const
inline

Set a selection of attributes to elements from an array of values. If the tuple size is not positive, it is assumed to be the attribute's tuple size. If explicitly specified, 'tuple_size' values will be copied from the array for each element.

Definition at line 312 of file GA_AIFTuple.h.

virtual bool GA_AIFTuple::setStorage ( GA_Attribute attrib,
GA_Storage  storage 
) const
pure virtual

Query and set some tuple intrisics.

virtual bool GA_AIFTuple::setTupleSize ( GA_Attribute attrib,
int  size 
) const
pure virtual

Query and set some tuple intrisics.


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