Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Thomas_Jensen1
Beginner
72 Views

Missing documentation for param_jpeg2k.precision

Jump to solution
In IPP 6.1.5 UIC samples, when Encoding or Decoding a JPeg2000 image, the param struct must be filled in.
One member is "precision", with values J2K_16 and J2K_32; for example "param_jpeg2k.precision = J2K_16".

I miss documentation for this parameter. What is it for, and what are the requirements and/or effects of using it?

0 Kudos
1 Solution
Vladimir_Dudnik
Employee
72 Views
Yes, for 8u images it is allowed and sufficient to use 16-bit precision for internal computations. For 16-bit images it is required to use 32-bit precision in internal computations.

View solution in original post

7 Replies
Vladimir_Dudnik
Employee
72 Views
Hello,


this parameter control arithmetic precision of internal computatations. When it is J2K_32 it mean 32-bit internal computations will be used and when it is J2K_16 then 16-bit computations will be used where it appropriate. 16-bit computation path allow to reduce a little bit internal memory buffers size.

Regards,
Vladimir
Thomas_Jensen1
Beginner
72 Views
Thanks, but I was looking for an answer as I wrote in my question; Since J2K_16 indeed is faster, and since it uses less memory, can I always use that, also for 16u images, without problems?
Vladimir_Dudnik
Employee
72 Views
No. For 16-bit input data internal computations have to use higher precision to avoid artifacts. IPP JPEG2000 codec will ignore that parameter and force 32-bit computations in that case.

Vladimir
Thomas_Jensen1
Beginner
72 Views
So, to conclude:

- For 16u images, is it a requirement to use J2K_32?
- For 8u images, is it sufficient to use J2K_16?
- For 8u images, is it allowed to use J2K_16?

This information is not available in the IPP samples.
Vladimir_Dudnik
Employee
73 Views
Yes, for 8u images it is allowed and sufficient to use 16-bit precision for internal computations. For 16-bit images it is required to use 32-bit precision in internal computations.

View solution in original post

Thomas_Jensen1
Beginner
72 Views
Thanks.

You could pass this on to your IPP Sample documentation collegues.
Vladimir_Dudnik
Employee
72 Views
Sure. Unfortunately it is too late for IPP 7.0 release but weconstantly work onimprovement ofdocumentation.
Reply