25 static const char * help =
": install libjpeg and re-run configure" ;
30 void Gr::JpegReader::setup(
int ,
bool ) {
throw Jpeg::Error(
"jpegreader not implemented" + std::string(help) ) ; }
32 void Gr::JpegReader::decode( ImageData & ,
const unsigned char * ,
size_t ) {
throw Jpeg::Error(
"jpegreader not implemented" + std::string(help) ) ; }
33 void Gr::JpegReader::decode( ImageData & ,
const char * ,
size_t ) {
throw Jpeg::Error(
"jpegreader not implemented" + std::string(help) ) ; }
void encode(const ImageData &in, const G::Path &path_out)
Encodes to a file.
A private pimple class for Gr::JpegWriter.
Vectors ImageBuffer
An ImageBuffer is used to hold raw image data, typically in more than one chunk.
void setup(int scale, bool monochrome_out=false)
Sets the decoding scale factor.
static bool available()
Returns true if a jpeg library is available.
A private implementation class for Gr::JpegReader.
void decode(ImageData &out, const G::Path &in)
Decodes a jpeg file into an image. Throws on error.
JpegReader(int scale=1, bool monochrome_out=false)
Constructor.
void setup(int scale, bool monochrome_out=false)
Sets the encoding scale factor.
JpegWriter(int scale=1, bool monochrome_out=false)
Constructor.
A Path object represents a file system path.