VRay SDK for C++
Loading...
Searching...
No Matches
VRay::LocalJpeg Class Reference

A wrapper around JPEG data in memory. It's meant to be stack allocated to free the data when done. More...

#include <vraysdk.hpp>

Inheritance diagram for VRay::LocalJpeg:
VRay::CompressImage

Public Member Functions

 LocalJpeg (const VRayImage *img, const VRayRenderer &renderer, int quality=0)
 Same as the other constructor. The renderer is used to log error messages.
 
 LocalJpeg (const VRayImage *img, int quality=0)
 
- Public Member Functions inherited from VRay::CompressImage
void * getBuf () const
 Returns a pointer to the image data.
 
size_t getLen () const
 Returns size of image data in bytes.
 
 operator size_t () const
 
bool saveToFile (const char *fileName) const
 Write the data to disk.
 
bool saveToFile (const std::string &fileName) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
 
void swap (CompressImage &ci)
 

Additional Inherited Members

- Protected Attributes inherited from VRay::CompressImage
byte * bufAddr
 
size_t bufSize
 

Detailed Description

A wrapper around JPEG data in memory. It's meant to be stack allocated to free the data when done.

Constructor & Destructor Documentation

◆ LocalJpeg()

VRay::LocalJpeg::LocalJpeg ( const VRayImage img,
int  quality = 0 
)
inline

Compression is performed in this constructor

Parameters
imgThe source image to compress. The source is not modified.
qualityIf negative, abs(quality) is used and progressive encoding is performed

The documentation for this class was generated from the following file: