This document is for a version of USD that is under development. See this page for the current release.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
HdDrawingCoord Class Reference

A tiny set of integers, which provides an indirection mapping from the conceptual space of an HdRprim's resources (topological, primvar & instancing) to the index within HdBufferArrayRangeContainer, where the resource is stored. More...

#include <drawingCoord.h>

Public Member Functions

int GetConstantPrimvarIndex () const
 
void SetConstantPrimvarIndex (int slot)
 
int GetVertexPrimvarIndex () const
 
void SetVertexPrimvarIndex (int slot)
 
int GetTopologyIndex () const
 
void SetTopologyIndex (int slot)
 
int GetElementPrimvarIndex () const
 
void SetElementPrimvarIndex (int slot)
 
int GetInstanceIndexIndex () const
 
void SetInstanceIndexIndex (int slot)
 
int GetFaceVaryingPrimvarIndex () const
 
void SetFaceVaryingPrimvarIndex (int slot)
 
int GetTopologyVisibilityIndex () const
 
void SetTopologyVisibilityIndex (int slot)
 
int GetVaryingPrimvarIndex () const
 
void SetVaryingPrimvarIndex (int slot)
 
void SetInstancePrimvarBaseIndex (int slot)
 
int GetInstancePrimvarIndex (int level) const
 

Static Public Attributes

static const int CustomSlotsBegin = 8
 
static const int DefaultNumSlots = 3
 
static const int Unassigned = -1
 

Detailed Description

A tiny set of integers, which provides an indirection mapping from the conceptual space of an HdRprim's resources (topological, primvar & instancing) to the index within HdBufferArrayRangeContainer, where the resource is stored.

Each HdDrawItem contains a HdDrawingCoord, with the relevant compositional hierarchy being:

HdRprim | +–HdRepr(s) | | | +–HdDrawItem(s)-------—. | | | | +–HdDrawingCoord | | | (mapping provided by HdDrawingCoord) +–HdRprimSharedData | | | +–HdBARContainer <-----—+

Having this indirection provides a recipe for how to configure a drawing coordinate, which is a bundle of HdBufferArrayRanges, while they are shared or not shared across different representations constructed on the same prim.

HullRepr ------— Rprim ------— RefinedRepr | | | DrawItem | DrawItem | | | DrawingCoord Container DrawingCoord constant ----—> [ 0 ] <---— constant vertex ----—> [ 1 ] topology ----—> [ 2 ] [ 3 ] [ 4 ] [ 5 ] [ 6 ] [ 7 ] [ 8 ] <---— vertex (refined) [ 9 ] <---— topology (refined) ... instance level=0 —> [ k ] instance level=1 —> [k+1] instance level=2 —> [k+2]

Definition at line 66 of file drawingCoord.h.

Constructor & Destructor Documentation

◆ HdDrawingCoord()

HdDrawingCoord ( )
inline

Definition at line 72 of file drawingCoord.h.

Member Function Documentation

◆ GetConstantPrimvarIndex()

int GetConstantPrimvarIndex ( ) const
inline

Definition at line 85 of file drawingCoord.h.

◆ GetElementPrimvarIndex()

int GetElementPrimvarIndex ( ) const
inline

Definition at line 91 of file drawingCoord.h.

◆ GetFaceVaryingPrimvarIndex()

int GetFaceVaryingPrimvarIndex ( ) const
inline

Definition at line 95 of file drawingCoord.h.

◆ GetInstanceIndexIndex()

int GetInstanceIndexIndex ( ) const
inline

Definition at line 93 of file drawingCoord.h.

◆ GetInstancePrimvarIndex()

int GetInstancePrimvarIndex ( int  level) const
inline

Definition at line 104 of file drawingCoord.h.

◆ GetTopologyIndex()

int GetTopologyIndex ( ) const
inline

Definition at line 89 of file drawingCoord.h.

◆ GetTopologyVisibilityIndex()

int GetTopologyVisibilityIndex ( ) const
inline

Definition at line 97 of file drawingCoord.h.

◆ GetVaryingPrimvarIndex()

int GetVaryingPrimvarIndex ( ) const
inline

Definition at line 99 of file drawingCoord.h.

◆ GetVertexPrimvarIndex()

int GetVertexPrimvarIndex ( ) const
inline

Definition at line 87 of file drawingCoord.h.

◆ SetConstantPrimvarIndex()

void SetConstantPrimvarIndex ( int  slot)
inline

Definition at line 86 of file drawingCoord.h.

◆ SetElementPrimvarIndex()

void SetElementPrimvarIndex ( int  slot)
inline

Definition at line 92 of file drawingCoord.h.

◆ SetFaceVaryingPrimvarIndex()

void SetFaceVaryingPrimvarIndex ( int  slot)
inline

Definition at line 96 of file drawingCoord.h.

◆ SetInstanceIndexIndex()

void SetInstanceIndexIndex ( int  slot)
inline

Definition at line 94 of file drawingCoord.h.

◆ SetInstancePrimvarBaseIndex()

void SetInstancePrimvarBaseIndex ( int  slot)
inline

Definition at line 103 of file drawingCoord.h.

◆ SetTopologyIndex()

void SetTopologyIndex ( int  slot)
inline

Definition at line 90 of file drawingCoord.h.

◆ SetTopologyVisibilityIndex()

void SetTopologyVisibilityIndex ( int  slot)
inline

Definition at line 98 of file drawingCoord.h.

◆ SetVaryingPrimvarIndex()

void SetVaryingPrimvarIndex ( int  slot)
inline

Definition at line 100 of file drawingCoord.h.

◆ SetVertexPrimvarIndex()

void SetVertexPrimvarIndex ( int  slot)
inline

Definition at line 88 of file drawingCoord.h.

Member Data Documentation

◆ CustomSlotsBegin

const int CustomSlotsBegin = 8
static

Definition at line 68 of file drawingCoord.h.

◆ DefaultNumSlots

const int DefaultNumSlots = 3
static

Definition at line 69 of file drawingCoord.h.

◆ Unassigned

const int Unassigned = -1
static

Definition at line 70 of file drawingCoord.h.


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