This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM368 JPEG encoder

Hi,

We use DM368 JPEG encoder (version.01.00.00.09) with image resolution of 4096x2048. The jpeg image looks ok.

But, with the maximum quality of the encoder (dynamicParams.qValue=97),  the output image is not a high quality (not very good) and the size is only 2 MB, and yet outDataMaxSize = W*H* 2 in our case.   What do you think? Has anyone encountered this problem?

Yet, when we change the qValue parameter (for example a smaller value), the image size and quality are changed.

We cannot find a way to improve it. If you have ideas, thank you for your help.

Regards,

Sakho

  • Hi,

    qValue= 97 is max quality we support on DM368. And the output size is dependent on content of the input you are feeding to encoder. We have tried different input of resolution, for some YUVs we got output more than 2MB.

  • Hi,

    We tried with YUV422 or YUV420 entries, but the result is the same. With our resolution (4096x2048) and qvalue = 97, we still have more than 2MB. And the most annoying thing is that the image quality is too poor.

    What parameters can we change to increase the quality? Can you help to find a way to improve it?
     
    Thank you in advance.
     
    Sakho
  • I guess poor quality of image might not get affected with qvalue  in your case, because you had set qvalue at max(97). And file size (2MB in your case) is only depend on input raw file you are giving to encoder.

  • Hi Sukho,

    Can you please share you input YUV and output bitstream for 1 frame?. And also share the parameters you are setting.

    Thanks,

    Veeranna

  • Hi,

    Thank you for your reply.

    You can download the input yuv files with format YUV420P and resolution  4096x2048. You can also find the output corresponding jpeg files:

                    https://drive.google.com/file/d/0B_1Za9-nIcj5eUxLVWNVMFkzM2c/edit?usp=sharing


    For JPEG codec parameters:

                IMGENC1_Params  params;

                                        params.size = sizeof(IMGENC1_Params);
                                        params.maxHeight =   2048;
                                        params.maxWidth  =  4096;
                                        params.maxScans  =  1;
                                       params.dataEndianness = XDM_BYTE;
                                      params.forceChromaFormat = XDM_YUV_420P;

              IMGENC1_DynamicParams dynamicParams;

                             dynamicParams.size = sizeof(IMGENC1_DynamicParams);
                          dynamicParams.numAU = XDM_DEFAULT;
                          dynamicParams.inputChromaFormat  = XDM_YUV_420SP;
                          dynamicParams.inputWidth  = 4096;
                         dynamicParams.inputHeight  = 2048;
    dynamicParams.generateHeader  = XDM_ENCODE_AU;
    dynamicParams.qValue          = 97;


    Do not hesitate if you need further informations and thank you again for your help.

    Sakho




                        

     

  • Hi,

    The shred YUVs doesn't have chroma component. Can you please check.

  • Hi,

    link for new captures:

    https://drive.google.com/file/d/0B_1Za9-nIcj5ZjQxa0YwRzNiRHM/edit?usp=sharing

    Regards,

    Sakho

  • Hi Sakho,

    We encoded these YUVs and we are getting JPEG of size similar to yours. We also tried encode these YUVs on OMAP4 based JPEG encoder, there also we are getting similar size(1.5 - 1.7 MB).

    So that will be max quality we can get on DM36x platform.