HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
apex Namespace Reference

Namespaces

 detail
 

Classes

class  APEX_TypedBuffer
 Expandable storage of arbitrary runtime types for APEX program state. Indexed by APEX_Buffer. More...
 
class  APEX_Buffer
 Holds all of the memory for execution state of a compiled APEX graph. More...
 
class  APEX_Argument
 Represents a location for a single object inside of an APEX_Buffer. More...
 
class  APEX_TrackedArgument
 
struct  APEX_Parm
 
struct  ParmNameComp
 
struct  ParmIterator
 
class  APEX_Signature
 
class  APEX_ParmHandleRef
 
class  APEX_ParmHandle
 
class  APEX_FunctionBase
 
class  APEX_GenericFunction
 
class  APEX_CompatibilityMap
 
class  APEX_COWHandle
 
class  ApexArray
 
class  ApexGeometry
 
class  APEX_RunDataErrorBase
 
class  APEX_GenericFunctionRunData
 
struct  APEX_Context
 
class  APEX_GenericFunctionContext
 
class  FloatRamp
 
class  ColorRamp
 
class  VariadicArg
 
class  APEX_ParmDict
 
class  APEX_RegistryEvent
 
class  APEX_Registry
 
class  APEX_TypeDefinitionBase
 
struct  APEX_TypeDefault
 Compile-time information about the default initialization to use for a type visible to the APEX type system. More...
 
struct  APEX_TypeDefault< Vector2 >
 
struct  APEX_TypeDefault< Vector3 >
 
struct  APEX_TypeDefault< Vector4 >
 
struct  APEX_TypeDefault< Matrix3 >
 
struct  APEX_TypeDefault< Matrix4 >
 
class  APEX_TypeTraits
 
struct  APEX_IsCompoundType
 
struct  APEX_IsCompoundType< T, SYS_Void_t< typename T::value_type > >
 Check if an APEX type wraps another type (for example, VariadicArg) More...
 
class  APEX_VoidTypeDefinition
 
struct  APEX_IsArrayType
 
struct  APEX_IsArrayType< ApexArray< T > >
 
struct  APEX_IsVariadicType
 
struct  APEX_IsVariadicType< VariadicArg< T > >
 
class  APEX_TypeDefinition
 
class  APEX_TypeDefinition< void >
 

Typedefs

using APEX_DataID = int64
 
using APEX_ParmPtr = UT_SharedPtr< APEX_Parm >
 
using APEX_ParmList = UT_Array< APEX_Parm >
 
using APEX_SignaturePtr = UT_SharedPtr< APEX_Signature >
 
using APEX_ArgPtrs = UT_Array< void * >
 
using Bool = bool
 
using Int = exint
 
using Float = double
 
using String = UT_StringHolder
 
using Vector2 = UT_Vector2T< Float >
 
using Vector3 = UT_Vector3T< Float >
 
using Vector4 = UT_Vector4T< Float >
 
using Matrix3 = UT_Matrix3T< Float >
 
using Matrix4 = UT_Matrix4T< Float >
 
using Geometry = ApexGeometry
 
using APEX_GraphHandle = APEX_COWHandle< APEX_Graph >
 
using BoolArray = ApexArray< Bool >
 
using IntArray = ApexArray< Int >
 
using FloatArray = ApexArray< Float >
 
using StringArray = ApexArray< String >
 
using Vector2Array = ApexArray< Vector2 >
 
using Vector3Array = ApexArray< Vector3 >
 
using Vector4Array = ApexArray< Vector4 >
 
using Matrix3Array = ApexArray< Matrix3 >
 
using Matrix4Array = ApexArray< Matrix4 >
 
using GeometryArray = ApexArray< ApexGeometry >
 
using FloatRampArray = ApexArray< FloatRamp >
 
using ColorRampArray = ApexArray< ColorRamp >
 
using Quaternion = UT_QuaternionT< Float >
 
using DataItem = PRM_DataItemHandle
 
using Dict = APEX_COWHandle< APEX_ParmDict >
 
using DictArray = ApexArray< Dict >
 
using addApexFunctionPtr = void(*)(APEX_Registry &)
 
using APEX_RegistryPtr = UT_SharedPtr< APEX_Registry >
 
using APEX_RegistryPtrList = UT_Array< APEX_RegistryPtr >
 
using APEX_OverloadSetPtr = UT_SharedPtr< APEX_OverloadSet >
 

Enumerations

enum  APEX_CallbackType {
  APEX_CallbackType::NOOP, APEX_CallbackType::NORMAL, APEX_CallbackType::IF_BEGIN, APEX_CallbackType::IF_END,
  APEX_CallbackType::LOOP_BEGIN, APEX_CallbackType::LOOP_END
}
 
enum  APEX_RegistryType {
  APEX_REGISTRY_INVALID = -1, APEX_REGISTRY_CALLBACK, APEX_REGISTRY_COMPONENT, APEX_REGISTRY_CONSTRAINT,
  APEX_REGISTRY_CONTROL, APEX_REGISTRY_N
}
 

Functions

template<>
UT_Optional< BoolcastArgValue (APEX_Argument &arg)
 Specialization for bools to allow conversion from integers. More...
 
template<>
UT_Optional< IntcastArgValue (APEX_Argument &arg)
 Specialization for ints to allow conversion from bools. More...
 
APEX_API UT_StringHolder APEXformatArg (const APEX_Argument *arg)
 Returns the value of the argument as a string. More...
 
APEX_API void APEXformatString (String &result, const String &format_str, const UT_Array< const APEX_Argument * > &args)
 
template<typename C , typename... Ts, size_t... Index>
void applyArgs (const C &callback, APEX_ArgPtrs &arg_ptrs, std::index_sequence< Index...>)
 
template<typename C , typename... Ts>
void applyArgs (const C &callback, APEX_ArgPtrs &arg_ptrs)
 Invoke the callback with the provided arguments, which are casted to type Ts... More...
 
template<typename T >
void addToSignature (APEX_Signature &sig, const UT_StringHolder &name)
 
template<typename... Ts, size_t... Index>
APEX_Signature makeSignature (UT_Span< const char *const, sizeof...(Ts)> argnames, std::index_sequence< Index...>)
 
template<typename... Ts>
APEX_Signature makeSignature (UT_Span< const char *const, sizeof...(Ts)> argnames)
 
template<typename... Ts>
APEX_Signature makeSignature (std::nullptr_t)
 
std::pair< UT_StringHolder,
UT_StringHolder
APEXsplitNameAndVersion (const char *fullname)
 
template<typename T >
exint APEXfilterCallbacksBySignature (UT_Array< const T * > &callbacks, const APEX_Signature &filter)
 
APEX_VISIBILITY_EXPORT void addApexFunction (APEX_Registry &reg)
 
template<typename T >
size_t UTformatBuffer (char *buffer, size_t bufsize, const ApexArray< T > &v)
 
APEX_API size_t UTformatBuffer (char *buffer, size_t bufsize, const ApexGeometry &v)
 
template<>
APEX_API size_t UTformatBuffer< ApexGeometry > (char *buffer, size_t bufsize, const ApexArray< ApexGeometry > &v)
 
APEX_API size_t UTformatBuffer (char *buffer, size_t buffer_size, const APEX_ParmDict &v)
 
APEX_API size_t UTformatBuffer (char *buffer, size_t buffer_size, const Dict &v)
 
template<>
APEX_API size_t UTformatBuffer< Dict > (char *buffer, size_t bufsize, const ApexArray< Dict > &v)
 
void setUtOption (UT_Options &opt, const UT_StringRef &key, const APEX_Argument &arg, bool include_geometry=false, bool include_typeinfo=true)
 
APEX_API UT_ArrayStringMap
< const
APEX_TypeDefinitionBase * > & 
APEXtypeDefinitions ()
 

Variables

APEX_API APEX_VoidTypeDefinition void_type_defn
 

Typedef Documentation

Definition at line 52 of file APEX_Registry.h.

using apex::APEX_ArgPtrs = typedef UT_Array<void *>

Definition at line 430 of file APEX_Callback.h.

using apex::APEX_DataID = typedef int64

Definition at line 86 of file APEX_Buffer.h.

using apex::APEX_GraphHandle = typedef APEX_COWHandle<APEX_Graph>

Definition at line 92 of file APEX_Include.h.

using apex::APEX_OverloadSetPtr = typedef UT_SharedPtr<APEX_OverloadSet>

Definition at line 86 of file APEX_Registry.h.

Definition at line 97 of file APEX_Callback.h.

Definition at line 96 of file APEX_Callback.h.

Definition at line 84 of file APEX_Registry.h.

Definition at line 85 of file APEX_Registry.h.

Definition at line 305 of file APEX_Callback.h.

using apex::Bool = typedef bool

Definition at line 60 of file APEX_Include.h.

using apex::BoolArray = typedef ApexArray<Bool>

Definition at line 94 of file APEX_Include.h.

Definition at line 105 of file APEX_Include.h.

Definition at line 112 of file APEX_Include.h.

Definition at line 66 of file APEX_ParmDict.h.

using apex::DictArray = typedef ApexArray<Dict>

Definition at line 67 of file APEX_ParmDict.h.

using apex::Float = typedef double

Definition at line 62 of file APEX_Include.h.

using apex::FloatArray = typedef ApexArray<Float>

Definition at line 96 of file APEX_Include.h.

Definition at line 104 of file APEX_Include.h.

using apex::Geometry = typedef ApexGeometry
Examples:
SIM/SIM_RadialEmit.h.

Definition at line 69 of file APEX_Include.h.

Definition at line 103 of file APEX_Include.h.

using apex::Int = typedef exint

Definition at line 61 of file APEX_Include.h.

using apex::IntArray = typedef ApexArray<Int>

Definition at line 95 of file APEX_Include.h.

using apex::Matrix3 = typedef UT_Matrix3T<Float>
Examples:
APEX/apex_external_test.C.

Definition at line 67 of file APEX_Include.h.

Definition at line 101 of file APEX_Include.h.

using apex::Matrix4 = typedef UT_Matrix4T<Float>
Examples:
APEX/apex_external_test.C.

Definition at line 68 of file APEX_Include.h.

Definition at line 102 of file APEX_Include.h.

Definition at line 110 of file APEX_Include.h.

using apex::String = typedef UT_StringHolder

Definition at line 63 of file APEX_Include.h.

Definition at line 97 of file APEX_Include.h.

using apex::Vector2 = typedef UT_Vector2T<Float>

Definition at line 64 of file APEX_Include.h.

Definition at line 98 of file APEX_Include.h.

using apex::Vector3 = typedef UT_Vector3T<Float>

Definition at line 65 of file APEX_Include.h.

Definition at line 99 of file APEX_Include.h.

using apex::Vector4 = typedef UT_Vector4T<Float>

Definition at line 66 of file APEX_Include.h.

Definition at line 100 of file APEX_Include.h.

Enumeration Type Documentation

Enumerator
NOOP 
NORMAL 

Do nothing; ignored after compilation.

IF_BEGIN 

Normal callback which is unconditionally executed.

flow control

IF_END 

condition + scope/spare

Callback is used as an IF_BEGIN: expects the signature to be exactly a Bool called

LOOP_BEGIN 

scope/spare.

Callback marks the end of an if block: expects the signature to be exactly

LOOP_END 

Marks the start of an arbitrary loop, expects RunData to be an iterator.

Marks the end of an arbitrary loop, expects RunData to be an iterator and shares that rundata with the corresponding LOOP_BEGIN.

Definition at line 410 of file APEX_Callback.h.

Enumerator
APEX_REGISTRY_INVALID 
APEX_REGISTRY_CALLBACK 
APEX_REGISTRY_COMPONENT 
APEX_REGISTRY_CONSTRAINT 
APEX_REGISTRY_CONTROL 
APEX_REGISTRY_N 

Definition at line 54 of file APEX_Registry.h.

Function Documentation

APEX_VISIBILITY_EXPORT void apex::addApexFunction ( APEX_Registry &  reg)
template<typename T >
void apex::addToSignature ( APEX_Signature &  sig,
const UT_StringHolder name 
)

Definition at line 517 of file APEX_Callback.h.

template<typename T >
exint apex::APEXfilterCallbacksBySignature ( UT_Array< const T * > &  callbacks,
const APEX_Signature &  filter 
)

Filters the callbacks array by removing the callbacks whose signatures do not contain all parms present in the filter signature. Returns the number of removed callbacks.

The filter signature represents a sparse set of required parms. Callbacks with additional parms are not removed as long as all parms in the filter signature are present in the callback signature.

Definition at line 661 of file APEX_Callback.h.

APEX_API UT_StringHolder apex::APEXformatArg ( const APEX_Argument *  arg)

Returns the value of the argument as a string.

APEX_API void apex::APEXformatString ( String &  result,
const String &  format_str,
const UT_Array< const APEX_Argument * > &  args 
)

Takes a formatting string, and an array of arguments, and writes the formatted string to the result.

std::pair<UT_StringHolder, UT_StringHolder> apex::APEXsplitNameAndVersion ( const char *  fullname)
inline

Splits the namespace version of fullname into a name and version pair. For example, "string::Build::3.0" is split as {"string::Build", "3.0"}.

Definition at line 635 of file APEX_Callback.h.

APEX_API UT_ArrayStringMap<const APEX_TypeDefinitionBase *>& apex::APEXtypeDefinitions ( )
template<typename C , typename... Ts, size_t... Index>
void apex::applyArgs ( const C &  callback,
APEX_ArgPtrs &  arg_ptrs,
std::index_sequence< Index...>   
)
inline

Definition at line 502 of file APEX_Callback.h.

template<typename C , typename... Ts>
void apex::applyArgs ( const C &  callback,
APEX_ArgPtrs &  arg_ptrs 
)
inline

Invoke the callback with the provided arguments, which are casted to type Ts...

Definition at line 510 of file APEX_Callback.h.

template<>
UT_Optional<Bool> apex::castArgValue ( APEX_Argument &  arg)
inline

Specialization for bools to allow conversion from integers.

Definition at line 272 of file APEX_Buffer.h.

template<>
UT_Optional<Int> apex::castArgValue ( APEX_Argument &  arg)
inline

Specialization for ints to allow conversion from bools.

Definition at line 287 of file APEX_Buffer.h.

template<typename... Ts, size_t... Index>
APEX_Signature apex::makeSignature ( UT_Span< const char *const, sizeof...(Ts)>  argnames,
std::index_sequence< Index...>   
)

Definition at line 538 of file APEX_Callback.h.

template<typename... Ts>
APEX_Signature apex::makeSignature ( UT_Span< const char *const, sizeof...(Ts)>  argnames)

Definition at line 549 of file APEX_Callback.h.

template<typename... Ts>
APEX_Signature apex::makeSignature ( std::nullptr_t  )

NB: This overload is here for backward compatibility. It was used to handle callbacks declaring an empty argnames member (since const char*[0] is a non-standard c++ type). The rare callbacks which do have an empty argnames member should instead use a std::array<T, 0>: static constexpr std::array<const char*, 0> argnames = {};

Definition at line 564 of file APEX_Callback.h.

void apex::setUtOption ( UT_Options opt,
const UT_StringRef key,
const APEX_Argument &  arg,
bool  include_geometry = false,
bool  include_typeinfo = true 
)
template<typename T >
size_t apex::UTformatBuffer ( char *  buffer,
size_t  bufsize,
const ApexArray< T > &  v 
)
inline

Definition at line 138 of file APEX_COW.h.

APEX_API size_t apex::UTformatBuffer ( char *  buffer,
size_t  buffer_size,
const APEX_ParmDict &  v 
)
APEX_API size_t apex::UTformatBuffer ( char *  buffer,
size_t  buffer_size,
const Dict &  v 
)
APEX_API size_t apex::UTformatBuffer ( char *  buffer,
size_t  bufsize,
const ApexGeometry &  v 
)
template<>
APEX_API size_t apex::UTformatBuffer< ApexGeometry > ( char *  buffer,
size_t  bufsize,
const ApexArray< ApexGeometry > &  v 
)
template<>
APEX_API size_t apex::UTformatBuffer< Dict > ( char *  buffer,
size_t  bufsize,
const ApexArray< Dict > &  v 
)

Variable Documentation

APEX_API APEX_VoidTypeDefinition apex::void_type_defn