MaterialX 1.39.1
Loading...
Searching...
No Matches
TypeDesc.h File Reference

Type descriptor for a MaterialX data type. More...

#include <MaterialXGenShader/Export.h>
#include <string_view>

Go to the source code of this file.

Classes

class  TypeDesc
 A type descriptor for MaterialX data types. More...
 
struct  TypeDesc::Hasher
 Hash operator. More...
 
class  TypeDescRegistry
 Helper class for type registration. More...
 

Macros

#define TYPEDESC_DEFINE_TYPE(T, name, basetype, semantic, size)    static constexpr TypeDesc T(name, basetype, semantic, size);
 Macro to define global type descriptions for commonly used types.
 
#define TYPEDESC_REGISTER_TYPE(T, name)    TypeDescRegistry register_##T(T, name);
 Macro to register a previously defined type in the type registry. More...
 

Detailed Description

Type descriptor for a MaterialX data type.

Macro Definition Documentation

◆ TYPEDESC_REGISTER_TYPE

#define TYPEDESC_REGISTER_TYPE (   T,
  name 
)     TypeDescRegistry register_##T(T, name);

Macro to register a previously defined type in the type registry.

Registration must be done in order for the type to be searchable by name.