HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PXL_Common.h File Reference
#include <limits.h>
#include "PXL_API.h"
#include <SYS/SYS_Types.h>
#include <UT/UT_Assert.h>
#include <UT/UT_ComputeGPU.h>
+ Include dependency graph for PXL_Common.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  PXL_DataFormatResolver< T >
 
struct  PXL_TypeResolver< PXL_DataFormat >
 

Macros

#define DEF_TYPERESOLVER(FORMAT, CPPTYPE)
 
#define PXL_WHITE_8   UCHAR_MAX
 
#define PXL_WHITE_16   USHRT_MAX
 
#define PXL_WHITE_32   UINT_MAX
 

Enumerations

enum  PXL_DataFormat {
  PXL_INT8 = 0, PXL_INT16, PXL_INT32, PXL_FLOAT32,
  PXL_FLOAT16, PXL_MAX_DATA_FORMAT
}
 
enum  PXL_Packing {
  PACK_SINGLE =0, PACK_DUAL, PACK_DUAL_NI, PACK_RGB,
  PACK_RGBA, PACK_RGB_NI, PACK_RGBA_NI, PACK_UV,
  PACK_UNKNOWN = 255, PACK_UV_NI = PACK_DUAL_NI
}
 
enum  PXL_ColorSpace {
  PXL_CS_UNKNOWN, PXL_CS_LINEAR, PXL_CS_GAMMA2_2, PXL_CS_CUSTOM_GAMMA,
  PXL_CS_SRGB, PXL_CS_REC709, PXL_CS_OCIO, PXL_CS_MAX_SPACES
}
 

Functions

PXL_API const char * PXLdataFormat (PXL_DataFormat f)
 
PXL_API const char * PXLpacking (PXL_Packing p)
 
PXL_API const char * PXLgetColorSpaceName (PXL_ColorSpace cs)
 
PXL_API PXL_ColorSpace PXLgetColorSpace (const char *csname)
 
const char * PXLcolorSpace (PXL_ColorSpace s)
 
PXL_ColorSpace PXLcolorSpace (const char *s)
 
UT_GPUType PXLconvertToUTGPUType (PXL_DataFormat t)
 
int PXLformatDepth (PXL_DataFormat d)
 
int PXLpackingComponents (PXL_Packing p)
 
int PXLpackingDepth (PXL_Packing p)
 
unsigned int PXLwhitePoint (PXL_DataFormat dt)
 
PXL_API void PXLdetermineProcCaps ()
 
PXL_API bool PXLcpuHasMMX ()
 
PXL_API int PXLcpuHasSSE ()
 
PXL_API bool PXLcpuHasXMMX ()
 
PXL_API bool PXLcpuHasCondMov ()
 
int PXLclampChar (int t)
 
int PXLclampShort (int t)
 
bool PXLformatIsInteger (const PXL_DataFormat d)
 

Variables

PXL_API const int pxlDefinesDepth [6]
 
PXL_API const int pxlDefinesPComp [256]
 
PXL_API const int pxlDefinesPDepth [256]
 
PXL_API const unsigned int pxlDefinesWhite [6]
 

Macro Definition Documentation

#define DEF_TYPERESOLVER (   FORMAT,
  CPPTYPE 
)
Value:
template <> struct PXL_DataFormatResolver<CPPTYPE> { \
static constexpr PXL_DataFormat format = FORMAT; \
}; \
template <> struct PXL_TypeResolver<FORMAT> { \
using T = CPPTYPE; \
}; \
/* end macro */
GLint GLint GLsizei GLint GLenum format
Definition: glcorearb.h:108
PXL_DataFormat
Definition: PXL_Common.h:20

Definition at line 57 of file PXL_Common.h.

#define PXL_WHITE_16   USHRT_MAX

Definition at line 99 of file PXL_Common.h.

#define PXL_WHITE_32   UINT_MAX

Definition at line 100 of file PXL_Common.h.

#define PXL_WHITE_8   UCHAR_MAX

Definition at line 98 of file PXL_Common.h.

Enumeration Type Documentation

Enumerator
PXL_CS_UNKNOWN 
PXL_CS_LINEAR 
PXL_CS_GAMMA2_2 
PXL_CS_CUSTOM_GAMMA 
PXL_CS_SRGB 
PXL_CS_REC709 
PXL_CS_OCIO 
PXL_CS_MAX_SPACES 

Definition at line 72 of file PXL_Common.h.

Enumerator
PXL_INT8 
PXL_INT16 
PXL_INT32 
PXL_FLOAT32 
PXL_FLOAT16 
PXL_MAX_DATA_FORMAT 

Definition at line 20 of file PXL_Common.h.

Enumerator
PACK_SINGLE 
PACK_DUAL 
PACK_DUAL_NI 
PACK_RGB 
PACK_RGBA 
PACK_RGB_NI 
PACK_RGBA_NI 
PACK_UV 
PACK_UNKNOWN 
PACK_UV_NI 

Definition at line 32 of file PXL_Common.h.

Function Documentation

int PXLclampChar ( int  t)
inline

Definition at line 143 of file PXL_Common.h.

int PXLclampShort ( int  t)
inline

Definition at line 153 of file PXL_Common.h.

const char* PXLcolorSpace ( PXL_ColorSpace  s)
inline

Definition at line 93 of file PXL_Common.h.

PXL_ColorSpace PXLcolorSpace ( const char *  s)
inline

Definition at line 95 of file PXL_Common.h.

UT_GPUType PXLconvertToUTGPUType ( PXL_DataFormat  t)
inline

Definition at line 107 of file PXL_Common.h.

PXL_API bool PXLcpuHasCondMov ( )
PXL_API bool PXLcpuHasMMX ( )
PXL_API int PXLcpuHasSSE ( )
PXL_API bool PXLcpuHasXMMX ( )
PXL_API const char* PXLdataFormat ( PXL_DataFormat  f)
PXL_API void PXLdetermineProcCaps ( )
int PXLformatDepth ( PXL_DataFormat  d)
inline

Definition at line 123 of file PXL_Common.h.

bool PXLformatIsInteger ( const PXL_DataFormat  d)
inline

Definition at line 162 of file PXL_Common.h.

PXL_API PXL_ColorSpace PXLgetColorSpace ( const char *  csname)
PXL_API const char* PXLgetColorSpaceName ( PXL_ColorSpace  cs)
PXL_API const char* PXLpacking ( PXL_Packing  p)
int PXLpackingComponents ( PXL_Packing  p)
inline

Definition at line 126 of file PXL_Common.h.

int PXLpackingDepth ( PXL_Packing  p)
inline

Definition at line 129 of file PXL_Common.h.

unsigned int PXLwhitePoint ( PXL_DataFormat  dt)
inline

Definition at line 132 of file PXL_Common.h.

Variable Documentation

PXL_API const int pxlDefinesDepth[6]
PXL_API const int pxlDefinesPComp[256]
PXL_API const int pxlDefinesPDepth[256]
PXL_API const unsigned int pxlDefinesWhite[6]