Maybe I'm missing it, but there doesn't seem to be a simple way like there was in IJL.
did you looked at IPP samples? We have big bunch of different samples which demonstrates how to use IPP to build various media codecs,including JPEG andJPEG2000
You can see three different JPEG samples on IPP main page.
1) IJL, for those customers who still use this old interface. It demostrates how you can implement IJL interface with using IPP functions. It will not be improved or extended.
2) IJG, this sample demonstrates how you can speedup well-know JPEG codec with using IPP
3) JPEGView sample contains simple codec, but this codec supports JPEG lossless mode, is able to extract Exif metadata, decoder is threaded with using OpenMP. We plan to continue improve this codec.
I've got the following code:
Everything works OK until
err = ijlInit(ℑ);
if (err != IJL_OK)
if (bmiHeader.biBitCount != 24)
//Resize output buffer
OutputBuffer.resize(bmiHeader.biWidth * bmiHeader.biHeight * 3);
image.DIBWidth = bmiHeader.biWidth;//
image.DIBHeight = bmiHeader.biHeight;//
image.DIBBytes = ImageBuffer;//
char saveto = "C://imagetest.jpg";
image.JPGFile = saveto;
image.JPGWidth = bmiHeader.biWidth;//
image.JPGHeight = bmiHeader.biHeight;//
image.JPGBytes = NULL;//
image.DIBChannels = 3; //
image.DIBColor = IJL_BGR; //
image.DIBPadBytes = IJL_DIB_PAD_BYTES(bmiHeader.biWidth, 3);
image.JPGSizeBytes = NULL;//
image.JPGColor = IJL_YCBCR; //
image.JPGChannels = 3; //
image.JPGSubsampling = IJL_411; //
image.jquality = 50;
bool returnval = true;
err =ijlWrite(ℑ, IJL_JBUFF_WRITEWHOLEIMAGE);
if (err != IJL_OK)
returnval = false;
if (ijlFree(ℑ) != IJL_OK)
TRACE("Can't free JPEG Library ");
ijlWrite is returning IJL_EXCEPTION_DETECTED.
Do you have any clue why?
Seems you solved your issue? So, what is your feeling about IJL implementation in IPP v5.0?
BTW, did you try JPEG codec in JPEGView sample? This codec supports lossless JPEG, it also threaded and is able to retrieve Exif metadata.