13 #ifndef __IMG_DeepShadow__
14 #define __IMG_DeepShadow__
103 class DeepShadowPixel;
104 DeepShadowPixel *myHandle;
139 void writeRawSamples(
bool enable);
182 const float *chdata,
int chsize,
191 const float *chdata,
int chsize,
196 return write(z, chdata, chsize, flags, sampleid, dz);
205 bool writePixel(
int pixel_x,
int pixel_y,
212 img_DeepShadow *myFile;
213 int myPixelX, myPixelY;
271 const char *
getName()
const {
return myName.c_str(); }
349 void setOption(
const char *option,
fpreal value);
350 void setOption(
const char *option,
int64 value);
352 { setOption(option, (
int64)value); }
367 const char *getDescription();
395 bool create(
const char *name,
int xres,
int yres,
396 int sxres,
int syres,
397 float pixel_aspect = 1.0,
407 bool open(
const char *name);
415 bool pixelStart(
int x,
int y);
417 bool pixelWrite(
float z,
const float *
data,
int vsize);
419 bool pixelWriteOrdered(
float z,
const float *data,
434 int getChannelCount() const;
445 bool setTextureOptions(const
UT_Options &opts);
452 static
bool getWorldToCamera(const
UT_Options *options,
454 static
bool getWorldToCamera(const
UT_Options *options,
456 template <typename
T>
458 {
return getWorldToCamera(getTextureOptions().
get(),
479 static bool getCameraToNDC(
const UT_Options *options,
483 static bool getCameraToNDC(
const UT_Options *options,
487 template <
typename T>
489 bool fit_z=
true)
const
493 return getCameraToNDC(getTextureOptions().
get(),
494 xform, xres, yres, fit_z);
506 static bool getWorldToNDC(
const UT_Options *options,
508 int xres,
int yres,
bool fit_z);
509 static bool getWorldToNDC(
const UT_Options *options,
511 int xres,
int yres,
bool fit_z);
512 template <
typename T>
518 return getWorldToNDC(getTextureOptions().
get(),
519 xform, xres, yres, fit_z);
526 float ofBias()
const;
533 int deepSampleListsPerPixel()
const;
539 const char *
const *
data);
551 const char *name,
int xres,
int yres,
552 int sxres,
int syres,
564 friend class img_DeepShadow;
568 img_DeepShadow *myFile;
#define SYS_DEPRECATED(__V__)
Thread-safe convenience class to make reading DSM pixels easy.
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.
GLuint const GLchar * name
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
GLint GLint GLsizei GLint GLenum GLenum type
bool getCameraToNDC(UT_Matrix4T< T > &xform, bool fit_z=true) const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
GLdouble GLdouble GLdouble z
HUSD_API const char * resolution()
GLfloat GLfloat GLfloat GLfloat h
A map of string to various well defined value types.
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...
GLsizei const GLfloat * value
Contains the details of a specific image file, used by IMG_File. This class contains all the high-lev...
getOption("OpenEXR.storage") storage
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)