HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
BRAY_AttribList Class Reference

Each BRAY_Object can define a list of attributes that it can evaluate. More...

#include <BRAY_AttribList.h>

+ Inheritance diagram for BRAY_AttribList:

Classes

struct  Attrib
 

Public Types

enum  AttributeOwner {
  ATTRIB_INVALID = -1, ATTRIB_VERTEX = GA_ATTRIB_VERTEX, ATTRIB_POINT = GA_ATTRIB_POINT, ATTRIB_UNIFORM = GA_ATTRIB_PRIMITIVE,
  ATTRIB_CONSTANT = GA_ATTRIB_DETAIL, ATTRIB_DICED_POINT, ATTRIB_INSTANCE, MAX_ATTRIB_TYPE
}
 

Public Member Functions

 BRAY_AttribList ()
 
 BRAY_AttribList (const Attrib *list, int list_size, bool volume)
 
 ~BRAY_AttribList ()
 
void setCapacity (int n)
 
int addAttribute (const UT_StringHolder &name, int tuple_size, AttributeOwner owner, GA_Storage storage, bool isarray)
 
template<int TSIZE = -1>
int getIndex (const UT_StringRef &name) const
 
int size () const
 
bool forVolume () const
 
GA_Storage storage (int i) const
 
int tupleSize (int i) const
 
AttributeOwner owner (int i) const
 
GA_StorageClass storageClass (int i) const
 
bool isArray (int i) const
 
const UT_StringHoldername (int i) const
 
const Attribattrib (int i) const
 
const Attriboperator[] (int i) const
 
bool isNormal (int i) const
 
bool isP (int i) const
 
int displayColor () const
 
int normal () const
 
int getP () const
 
bool isDicedNormal () const
 
void dump () const
 
void dump (UT_JSONWriter &w) const
 

Static Public Member Functions

static const char * owner (AttributeOwner)
 
static const BRAY_AttribListfindList (const Attrib *list, int list_size, bool for_volume)
 
static const BRAY_AttribListfindList (const BRAY_AttribList &src)
 

Detailed Description

Each BRAY_Object can define a list of attributes that it can evaluate.

Definition at line 24 of file BRAY_AttribList.h.

Member Enumeration Documentation

Enumerator
ATTRIB_INVALID 
ATTRIB_VERTEX 
ATTRIB_POINT 
ATTRIB_UNIFORM 
ATTRIB_CONSTANT 
ATTRIB_DICED_POINT 
ATTRIB_INSTANCE 
MAX_ATTRIB_TYPE 

Definition at line 28 of file BRAY_AttribList.h.

Constructor & Destructor Documentation

BRAY_AttribList::BRAY_AttribList ( )
BRAY_AttribList::BRAY_AttribList ( const Attrib list,
int  list_size,
bool  volume 
)
BRAY_AttribList::~BRAY_AttribList ( )

Member Function Documentation

int BRAY_AttribList::addAttribute ( const UT_StringHolder name,
int  tuple_size,
AttributeOwner  owner,
GA_Storage  storage,
bool  isarray 
)
const Attrib& BRAY_AttribList::attrib ( int  i) const
inline

Definition at line 120 of file BRAY_AttribList.h.

int BRAY_AttribList::displayColor ( ) const
inline

Definition at line 125 of file BRAY_AttribList.h.

void BRAY_AttribList::dump ( ) const
void BRAY_AttribList::dump ( UT_JSONWriter w) const
static const BRAY_AttribList* BRAY_AttribList::findList ( const Attrib list,
int  list_size,
bool  for_volume 
)
static

Look up a list of attributes in a shared table. If different BRAY_Objects share the same attribute list, then it's possible they will be shaded in batch. Using the shared table can improve rendering performance.

static const BRAY_AttribList* BRAY_AttribList::findList ( const BRAY_AttribList src)
static
bool BRAY_AttribList::forVolume ( ) const
inline

Definition at line 113 of file BRAY_AttribList.h.

template<int TSIZE = -1>
int BRAY_AttribList::getIndex ( const UT_StringRef name) const
inline

Definition at line 101 of file BRAY_AttribList.h.

int BRAY_AttribList::getP ( ) const
inline

Definition at line 127 of file BRAY_AttribList.h.

bool BRAY_AttribList::isArray ( int  i) const
inline

Definition at line 118 of file BRAY_AttribList.h.

bool BRAY_AttribList::isDicedNormal ( ) const
inline

Definition at line 129 of file BRAY_AttribList.h.

bool BRAY_AttribList::isNormal ( int  i) const
inline

Definition at line 122 of file BRAY_AttribList.h.

bool BRAY_AttribList::isP ( int  i) const
inline

Definition at line 123 of file BRAY_AttribList.h.

const UT_StringHolder& BRAY_AttribList::name ( int  i) const
inline

Definition at line 119 of file BRAY_AttribList.h.

int BRAY_AttribList::normal ( ) const
inline

Definition at line 126 of file BRAY_AttribList.h.

const Attrib& BRAY_AttribList::operator[] ( int  i) const
inline

Definition at line 121 of file BRAY_AttribList.h.

static const char* BRAY_AttribList::owner ( AttributeOwner  )
static
AttributeOwner BRAY_AttribList::owner ( int  i) const
inline

Definition at line 116 of file BRAY_AttribList.h.

void BRAY_AttribList::setCapacity ( int  n)
int BRAY_AttribList::size ( ) const
inline

Definition at line 112 of file BRAY_AttribList.h.

GA_Storage BRAY_AttribList::storage ( int  i) const
inline

Definition at line 114 of file BRAY_AttribList.h.

GA_StorageClass BRAY_AttribList::storageClass ( int  i) const
inline

Definition at line 117 of file BRAY_AttribList.h.

int BRAY_AttribList::tupleSize ( int  i) const
inline

Definition at line 115 of file BRAY_AttribList.h.


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