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

Functions

RE_API bool isUDIMTexture (const UT_StringHolder &map_name)
 
RE_API bool determineUDIMBounds (const UT_StringHolder &filepath, UT_DimRect &udim_area, int &max_tile, UT_Array< std::pair< UT_StringHolder, UT_Vector2i >> &tiles, int tile_stride, RE_TextureHDAResolverCB hda_resolver)
 
RE_API bool createRampFromParm (const UT_StringHolder &parm_path, const UT_StringHolder &rel_path, UT_Vector4FArray &ramp_data, int &op_id, int &op_version, bool &is_rgb)
 
RE_API bool createSphereMap (const PXL_Raster *polar_image, int cube_size, void *output_pixels, RE_GPUType dest_type)
 
RE_API void scalePolarFromRaster (PXL_Raster *dest, const PXL_Raster *src, bool wrap_y)
 
RE_API bool loadCubeMap (IMG_File *fp, int w, int h, RE_GPUType type, int vsize, void *output_pixels)
 
RE_API UT_Matrix4D getPerspectiveProjection (fpreal l, fpreal r, fpreal b, fpreal t, fpreal n, fpreal f)
 
RE_API UT_Matrix4D getOrthoProjection (fpreal l, fpreal r, fpreal b, fpreal t, fpreal n, fpreal f)
 
RE_API UT_Matrix4D getLookatTransform (const UT_Vector3D &eye, const UT_Vector3D &target, const UT_Vector3D &up)
 

Function Documentation

RE_API bool RE_Utils::createRampFromParm ( const UT_StringHolder parm_path,
const UT_StringHolder rel_path,
UT_Vector4FArray ramp_data,
int op_id,
int op_version,
bool &  is_rgb 
)

Given an oppath + a channel name (op:/path/to/node/parmname) to a ramp parm, generate a ramp in ramp_data. Presize the array to the precision you require. parm_path can also be op:parmname if rel_path is the path to the node.

RE_API bool RE_Utils::createSphereMap ( const PXL_Raster polar_image,
int  cube_size,
void output_pixels,
RE_GPUType  dest_type 
)
RE_API bool RE_Utils::determineUDIMBounds ( const UT_StringHolder filepath,
UT_DimRect udim_area,
int max_tile,
UT_Array< std::pair< UT_StringHolder, UT_Vector2i >> &  tiles,
int  tile_stride,
RE_TextureHDAResolverCB  hda_resolver 
)
RE_API UT_Matrix4D RE_Utils::getLookatTransform ( const UT_Vector3D eye,
const UT_Vector3D target,
const UT_Vector3D up 
)
RE_API UT_Matrix4D RE_Utils::getOrthoProjection ( fpreal  l,
fpreal  r,
fpreal  b,
fpreal  t,
fpreal  n,
fpreal  f 
)
RE_API UT_Matrix4D RE_Utils::getPerspectiveProjection ( fpreal  l,
fpreal  r,
fpreal  b,
fpreal  t,
fpreal  n,
fpreal  f 
)
RE_API bool RE_Utils::isUDIMTexture ( const UT_StringHolder map_name)
RE_API bool RE_Utils::loadCubeMap ( IMG_File *  fp,
int  w,
int  h,
RE_GPUType  type,
int  vsize,
void output_pixels 
)
RE_API void RE_Utils::scalePolarFromRaster ( PXL_Raster dest,
const PXL_Raster src,
bool  wrap_y 
)