HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
stacked.h File Reference
#include "pxr/pxr.h"
#include "pxr/base/tf/api.h"
#include "pxr/base/tf/diagnostic.h"
#include "pxr/base/arch/demangle.h"
#include <hboost/mpl/if.hpp>
#include <hboost/noncopyable.hpp>
#include <tbb/enumerable_thread_specific.h>
#include <atomic>
#include <vector>
+ Include dependency graph for stacked.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  TfStackedAccess
 
class  Tf_StackedStorageType< T, PerThread >
 
struct  Tf_ExportedStackedStorage< T, PerThread >
 
struct  Tf_StackedStorage< T, PerThread >
 
class  TfStacked< Derived, PerThread, Holder >
 

Macros

#define TF_DEFINE_STACKED(Derived, IsPerThread, eiAPI)
 

Macro Definition Documentation

#define TF_DEFINE_STACKED (   Derived,
  IsPerThread,
  eiAPI 
)
Value:
class Derived; \
template <> \
static eiAPI std::atomic<Type*> value; \
}; \
class Derived : \
public TfStacked<Derived, IsPerThread, \
Tf_ExportedStackedStorage<Derived, IsPerThread>>
*get result *(waiting if necessary)*A common idiom is to fire a bunch of sub tasks at the and then *wait for them to all complete We provide a helper class
Definition: thread.h:643
hboost::mpl::if_c< PerThread, _PerThreadStackStorage, _GlobalStackStorage >::type Type
Definition: stacked.h:100
std::vector< T const * > Stack
Definition: stacked.h:60
GLsizei const GLfloat * value
Definition: glew.h:1849

Define the class Derived that subclasses from TfStacked. IsPerThread selected thread safety and eiAPI is used to export the storage for the stack. Use TF_INSTANTIATE_DEFINED_STACKED to define the storage.

Definition at line 240 of file stacked.h.