13 #ifndef __IMG_DeepShadow__
14 #define __IMG_DeepShadow__
106 class DeepShadowPixel;
107 DeepShadowPixel *myHandle;
144 void writeRawSamples(
bool enable);
187 const float *chdata,
int chsize,
196 const float *chdata,
int chsize,
201 return write(z, chdata, chsize, flags, sampleid, dz);
210 bool writePixel(
int pixel_x,
int pixel_y,
217 img_DeepShadow *myFile;
218 int myPixelX, myPixelY;
276 const char *
getName()
const {
return myName.c_str(); }
356 void setOption(
const char *option,
fpreal value);
357 void setOption(
const char *option,
int64 value);
359 { setOption(option, (
int64)value); }
402 bool create(
const char *name,
int xres,
int yres,
403 int sxres,
int syres,
404 float pixel_aspect = 1.0,
414 bool open(
const char *name);
422 bool pixelStart(
int x,
int y);
424 bool pixelWrite(
float z,
const float *
data,
int vsize);
426 bool pixelWriteOrdered(
float z,
const float *data,
441 int getChannelCount() const;
452 bool setTextureOptions(const
UT_Options &opts);
459 static
bool getWorldToCamera(const
UT_Options *options,
461 static
bool getWorldToCamera(const
UT_Options *options,
463 template <typename
T>
465 {
return getWorldToCamera(getTextureOptions().
get(),
486 static bool getCameraToNDC(
const UT_Options *options,
490 static bool getCameraToNDC(
const UT_Options *options,
494 template <
typename T>
496 bool fit_z=
true)
const
500 return getCameraToNDC(getTextureOptions().
get(),
501 xform, xres, yres, fit_z);
513 static bool getWorldToNDC(
const UT_Options *options,
515 int xres,
int yres,
bool fit_z);
516 static bool getWorldToNDC(
const UT_Options *options,
518 int xres,
int yres,
bool fit_z);
519 template <
typename T>
525 return getWorldToNDC(getTextureOptions().
get(),
526 xform, xres, yres, fit_z);
533 float ofBias()
const;
540 int deepSampleListsPerPixel()
const;
546 const char *
const *
data);
558 const char *name,
int xres,
int yres,
559 int sxres,
int syres,
571 friend class img_DeepShadow;
575 img_DeepShadow *myFile;
PXL_API const char * getDescription(const ColorSpace *space)
Return the description of the color space.
#define SYS_DEPRECATED(__V__)
Thread-safe convenience class to make reading DSM pixels easy.
getFileOption("OpenEXR:storage") storage
GLdouble GLdouble GLdouble z
Single channel of a Houdini DSM image.
const PXL_DeepCompressorPtr & compressor() const
Access to the pixel compressor.
Thread-safe convenience class to make writing DSM pixels easy.
Class to read or write deep shadow/camera images.
std::unique_ptr< T, Deleter > UT_UniquePtr
A smart pointer for unique ownership of dynamically allocated objects.
void setOption(const char *option, int value)
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
const char * getName() const
bool getCameraToNDC(UT_Matrix4T< T > &xform, bool fit_z=true) const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
#define UT_NON_COPYABLE(CLASS)
Define deleted copy constructor and assignment operator inside a class.
HUSD_API const char * resolution()
GLuint const GLchar * name
GLfloat GLfloat GLfloat GLfloat h
A map of string to various well defined value types.
SIM_API const UT_StringHolder force
bool getWorldToNDC(UT_Matrix4T< T > &xform, bool fit_z) const
File options for manipulating image data on load or save. This class allows you to modify the incomin...
Contains the details of a specific image file, used by IMG_File. This class contains all the high-lev...
UT_SharedPtr< PXL_DeepCompressor > PXL_DeepCompressorPtr
const char * getStorage() const
ImageBuf OIIO_API crop(const ImageBuf &src, ROI roi={}, int nthreads=0)
void write(T &out, bool v)
bool writeOrdered(float z, const float *chdata, int chsize, int flags, int sampleid, float dz=0)