rfreeimage 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (860) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +1 -0
  4. data/Rakefile +34 -0
  5. data/ext/rfreeimage/extconf.rb +35 -0
  6. data/ext/rfreeimage/rfi_main.c +389 -0
  7. data/lib/rfreeimage/image.rb +26 -0
  8. data/lib/rfreeimage/version.rb +3 -0
  9. data/lib/rfreeimage.rb +3 -0
  10. data/rfreeimage.gemspec +32 -0
  11. data/vendor/FreeImage/Makefile +34 -0
  12. data/vendor/FreeImage/Makefile.cygwin +74 -0
  13. data/vendor/FreeImage/Makefile.fip +84 -0
  14. data/vendor/FreeImage/Makefile.gnu +83 -0
  15. data/vendor/FreeImage/Makefile.iphone +96 -0
  16. data/vendor/FreeImage/Makefile.mingw +136 -0
  17. data/vendor/FreeImage/Makefile.osx +115 -0
  18. data/vendor/FreeImage/Makefile.solaris +66 -0
  19. data/vendor/FreeImage/Makefile.srcs +6 -0
  20. data/vendor/FreeImage/README.iphone +19 -0
  21. data/vendor/FreeImage/README.linux +50 -0
  22. data/vendor/FreeImage/README.minGW +236 -0
  23. data/vendor/FreeImage/README.osx +44 -0
  24. data/vendor/FreeImage/README.solaris +67 -0
  25. data/vendor/FreeImage/Source/CacheFile.h +92 -0
  26. data/vendor/FreeImage/Source/DeprecationManager/Deprecated.cpp +36 -0
  27. data/vendor/FreeImage/Source/DeprecationManager/DeprecationMgr.cpp +103 -0
  28. data/vendor/FreeImage/Source/DeprecationManager/DeprecationMgr.h +83 -0
  29. data/vendor/FreeImage/Source/FreeImage/BitmapAccess.cpp +1573 -0
  30. data/vendor/FreeImage/Source/FreeImage/CacheFile.cpp +271 -0
  31. data/vendor/FreeImage/Source/FreeImage/ColorLookup.cpp +785 -0
  32. data/vendor/FreeImage/Source/FreeImage/Conversion.cpp +551 -0
  33. data/vendor/FreeImage/Source/FreeImage/Conversion16_555.cpp +209 -0
  34. data/vendor/FreeImage/Source/FreeImage/Conversion16_565.cpp +204 -0
  35. data/vendor/FreeImage/Source/FreeImage/Conversion24.cpp +252 -0
  36. data/vendor/FreeImage/Source/FreeImage/Conversion32.cpp +345 -0
  37. data/vendor/FreeImage/Source/FreeImage/Conversion4.cpp +246 -0
  38. data/vendor/FreeImage/Source/FreeImage/Conversion8.cpp +305 -0
  39. data/vendor/FreeImage/Source/FreeImage/ConversionFloat.cpp +194 -0
  40. data/vendor/FreeImage/Source/FreeImage/ConversionRGB16.cpp +144 -0
  41. data/vendor/FreeImage/Source/FreeImage/ConversionRGBA16.cpp +147 -0
  42. data/vendor/FreeImage/Source/FreeImage/ConversionRGBAF.cpp +250 -0
  43. data/vendor/FreeImage/Source/FreeImage/ConversionRGBF.cpp +243 -0
  44. data/vendor/FreeImage/Source/FreeImage/ConversionType.cpp +699 -0
  45. data/vendor/FreeImage/Source/FreeImage/ConversionUINT16.cpp +134 -0
  46. data/vendor/FreeImage/Source/FreeImage/FreeImage.cpp +226 -0
  47. data/vendor/FreeImage/Source/FreeImage/FreeImageC.c +22 -0
  48. data/vendor/FreeImage/Source/FreeImage/FreeImageIO.cpp +175 -0
  49. data/vendor/FreeImage/Source/FreeImage/GetType.cpp +92 -0
  50. data/vendor/FreeImage/Source/FreeImage/Halftoning.cpp +474 -0
  51. data/vendor/FreeImage/Source/FreeImage/J2KHelper.cpp +591 -0
  52. data/vendor/FreeImage/Source/FreeImage/J2KHelper.h +36 -0
  53. data/vendor/FreeImage/Source/FreeImage/LFPQuantizer.cpp +208 -0
  54. data/vendor/FreeImage/Source/FreeImage/MNGHelper.cpp +1320 -0
  55. data/vendor/FreeImage/Source/FreeImage/MemoryIO.cpp +237 -0
  56. data/vendor/FreeImage/Source/FreeImage/MultiPage.cpp +974 -0
  57. data/vendor/FreeImage/Source/FreeImage/NNQuantizer.cpp +507 -0
  58. data/vendor/FreeImage/Source/FreeImage/PSDParser.cpp +1057 -0
  59. data/vendor/FreeImage/Source/FreeImage/PSDParser.h +271 -0
  60. data/vendor/FreeImage/Source/FreeImage/PixelAccess.cpp +197 -0
  61. data/vendor/FreeImage/Source/FreeImage/Plugin.cpp +822 -0
  62. data/vendor/FreeImage/Source/FreeImage/PluginBMP.cpp +1494 -0
  63. data/vendor/FreeImage/Source/FreeImage/PluginCUT.cpp +240 -0
  64. data/vendor/FreeImage/Source/FreeImage/PluginDDS.cpp +655 -0
  65. data/vendor/FreeImage/Source/FreeImage/PluginEXR.cpp +773 -0
  66. data/vendor/FreeImage/Source/FreeImage/PluginG3.cpp +433 -0
  67. data/vendor/FreeImage/Source/FreeImage/PluginGIF.cpp +1407 -0
  68. data/vendor/FreeImage/Source/FreeImage/PluginHDR.cpp +722 -0
  69. data/vendor/FreeImage/Source/FreeImage/PluginICO.cpp +824 -0
  70. data/vendor/FreeImage/Source/FreeImage/PluginIFF.cpp +459 -0
  71. data/vendor/FreeImage/Source/FreeImage/PluginJ2K.cpp +328 -0
  72. data/vendor/FreeImage/Source/FreeImage/PluginJNG.cpp +162 -0
  73. data/vendor/FreeImage/Source/FreeImage/PluginJP2.cpp +328 -0
  74. data/vendor/FreeImage/Source/FreeImage/PluginJPEG.cpp +1706 -0
  75. data/vendor/FreeImage/Source/FreeImage/PluginJXR.cpp +1475 -0
  76. data/vendor/FreeImage/Source/FreeImage/PluginKOALA.cpp +243 -0
  77. data/vendor/FreeImage/Source/FreeImage/PluginMNG.cpp +153 -0
  78. data/vendor/FreeImage/Source/FreeImage/PluginPCD.cpp +251 -0
  79. data/vendor/FreeImage/Source/FreeImage/PluginPCX.cpp +659 -0
  80. data/vendor/FreeImage/Source/FreeImage/PluginPFM.cpp +409 -0
  81. data/vendor/FreeImage/Source/FreeImage/PluginPICT.cpp +1343 -0
  82. data/vendor/FreeImage/Source/FreeImage/PluginPNG.cpp +1115 -0
  83. data/vendor/FreeImage/Source/FreeImage/PluginPNM.cpp +838 -0
  84. data/vendor/FreeImage/Source/FreeImage/PluginPSD.cpp +131 -0
  85. data/vendor/FreeImage/Source/FreeImage/PluginRAS.cpp +512 -0
  86. data/vendor/FreeImage/Source/FreeImage/PluginRAW.cpp +793 -0
  87. data/vendor/FreeImage/Source/FreeImage/PluginSGI.cpp +425 -0
  88. data/vendor/FreeImage/Source/FreeImage/PluginTARGA.cpp +1591 -0
  89. data/vendor/FreeImage/Source/FreeImage/PluginTIFF.cpp +2631 -0
  90. data/vendor/FreeImage/Source/FreeImage/PluginWBMP.cpp +372 -0
  91. data/vendor/FreeImage/Source/FreeImage/PluginWebP.cpp +698 -0
  92. data/vendor/FreeImage/Source/FreeImage/PluginXBM.cpp +399 -0
  93. data/vendor/FreeImage/Source/FreeImage/PluginXPM.cpp +487 -0
  94. data/vendor/FreeImage/Source/FreeImage/TIFFLogLuv.cpp +65 -0
  95. data/vendor/FreeImage/Source/FreeImage/ToneMapping.cpp +75 -0
  96. data/vendor/FreeImage/Source/FreeImage/WuQuantizer.cpp +559 -0
  97. data/vendor/FreeImage/Source/FreeImage/ZLibInterface.cpp +223 -0
  98. data/vendor/FreeImage/Source/FreeImage/tmoColorConvert.cpp +479 -0
  99. data/vendor/FreeImage/Source/FreeImage/tmoDrago03.cpp +295 -0
  100. data/vendor/FreeImage/Source/FreeImage/tmoFattal02.cpp +689 -0
  101. data/vendor/FreeImage/Source/FreeImage/tmoReinhard05.cpp +260 -0
  102. data/vendor/FreeImage/Source/FreeImage.h +1153 -0
  103. data/vendor/FreeImage/Source/FreeImageIO.h +63 -0
  104. data/vendor/FreeImage/Source/FreeImageToolkit/BSplineRotate.cpp +730 -0
  105. data/vendor/FreeImage/Source/FreeImageToolkit/Background.cpp +895 -0
  106. data/vendor/FreeImage/Source/FreeImageToolkit/Channels.cpp +488 -0
  107. data/vendor/FreeImage/Source/FreeImageToolkit/ClassicRotate.cpp +917 -0
  108. data/vendor/FreeImage/Source/FreeImageToolkit/Colors.cpp +967 -0
  109. data/vendor/FreeImage/Source/FreeImageToolkit/CopyPaste.cpp +861 -0
  110. data/vendor/FreeImage/Source/FreeImageToolkit/Display.cpp +230 -0
  111. data/vendor/FreeImage/Source/FreeImageToolkit/Filters.h +287 -0
  112. data/vendor/FreeImage/Source/FreeImageToolkit/Flip.cpp +166 -0
  113. data/vendor/FreeImage/Source/FreeImageToolkit/JPEGTransform.cpp +623 -0
  114. data/vendor/FreeImage/Source/FreeImageToolkit/MultigridPoissonSolver.cpp +505 -0
  115. data/vendor/FreeImage/Source/FreeImageToolkit/Rescale.cpp +192 -0
  116. data/vendor/FreeImage/Source/FreeImageToolkit/Resize.cpp +2116 -0
  117. data/vendor/FreeImage/Source/FreeImageToolkit/Resize.h +196 -0
  118. data/vendor/FreeImage/Source/LibJPEG/ansi2knr.c +739 -0
  119. data/vendor/FreeImage/Source/LibJPEG/cderror.h +134 -0
  120. data/vendor/FreeImage/Source/LibJPEG/cdjpeg.c +181 -0
  121. data/vendor/FreeImage/Source/LibJPEG/cdjpeg.h +187 -0
  122. data/vendor/FreeImage/Source/LibJPEG/cjpeg.c +664 -0
  123. data/vendor/FreeImage/Source/LibJPEG/ckconfig.c +402 -0
  124. data/vendor/FreeImage/Source/LibJPEG/djpeg.c +617 -0
  125. data/vendor/FreeImage/Source/LibJPEG/example.c +433 -0
  126. data/vendor/FreeImage/Source/LibJPEG/jaricom.c +153 -0
  127. data/vendor/FreeImage/Source/LibJPEG/jcapimin.c +288 -0
  128. data/vendor/FreeImage/Source/LibJPEG/jcapistd.c +162 -0
  129. data/vendor/FreeImage/Source/LibJPEG/jcarith.c +944 -0
  130. data/vendor/FreeImage/Source/LibJPEG/jccoefct.c +454 -0
  131. data/vendor/FreeImage/Source/LibJPEG/jccolor.c +604 -0
  132. data/vendor/FreeImage/Source/LibJPEG/jcdctmgr.c +477 -0
  133. data/vendor/FreeImage/Source/LibJPEG/jchuff.c +1573 -0
  134. data/vendor/FreeImage/Source/LibJPEG/jcinit.c +84 -0
  135. data/vendor/FreeImage/Source/LibJPEG/jcmainct.c +297 -0
  136. data/vendor/FreeImage/Source/LibJPEG/jcmarker.c +719 -0
  137. data/vendor/FreeImage/Source/LibJPEG/jcmaster.c +856 -0
  138. data/vendor/FreeImage/Source/LibJPEG/jcomapi.c +106 -0
  139. data/vendor/FreeImage/Source/LibJPEG/jconfig.h +161 -0
  140. data/vendor/FreeImage/Source/LibJPEG/jcparam.c +675 -0
  141. data/vendor/FreeImage/Source/LibJPEG/jcprepct.c +358 -0
  142. data/vendor/FreeImage/Source/LibJPEG/jcsample.c +545 -0
  143. data/vendor/FreeImage/Source/LibJPEG/jctrans.c +385 -0
  144. data/vendor/FreeImage/Source/LibJPEG/jdapimin.c +399 -0
  145. data/vendor/FreeImage/Source/LibJPEG/jdapistd.c +276 -0
  146. data/vendor/FreeImage/Source/LibJPEG/jdarith.c +796 -0
  147. data/vendor/FreeImage/Source/LibJPEG/jdatadst.c +270 -0
  148. data/vendor/FreeImage/Source/LibJPEG/jdatasrc.c +275 -0
  149. data/vendor/FreeImage/Source/LibJPEG/jdcoefct.c +741 -0
  150. data/vendor/FreeImage/Source/LibJPEG/jdcolor.c +748 -0
  151. data/vendor/FreeImage/Source/LibJPEG/jdct.h +393 -0
  152. data/vendor/FreeImage/Source/LibJPEG/jddctmgr.c +384 -0
  153. data/vendor/FreeImage/Source/LibJPEG/jdhuff.c +1554 -0
  154. data/vendor/FreeImage/Source/LibJPEG/jdinput.c +662 -0
  155. data/vendor/FreeImage/Source/LibJPEG/jdmainct.c +513 -0
  156. data/vendor/FreeImage/Source/LibJPEG/jdmarker.c +1511 -0
  157. data/vendor/FreeImage/Source/LibJPEG/jdmaster.c +543 -0
  158. data/vendor/FreeImage/Source/LibJPEG/jdmerge.c +401 -0
  159. data/vendor/FreeImage/Source/LibJPEG/jdpostct.c +290 -0
  160. data/vendor/FreeImage/Source/LibJPEG/jdsample.c +361 -0
  161. data/vendor/FreeImage/Source/LibJPEG/jdtrans.c +140 -0
  162. data/vendor/FreeImage/Source/LibJPEG/jerror.c +253 -0
  163. data/vendor/FreeImage/Source/LibJPEG/jerror.h +304 -0
  164. data/vendor/FreeImage/Source/LibJPEG/jfdctflt.c +174 -0
  165. data/vendor/FreeImage/Source/LibJPEG/jfdctfst.c +230 -0
  166. data/vendor/FreeImage/Source/LibJPEG/jfdctint.c +4406 -0
  167. data/vendor/FreeImage/Source/LibJPEG/jidctflt.c +235 -0
  168. data/vendor/FreeImage/Source/LibJPEG/jidctfst.c +368 -0
  169. data/vendor/FreeImage/Source/LibJPEG/jidctint.c +5179 -0
  170. data/vendor/FreeImage/Source/LibJPEG/jinclude.h +91 -0
  171. data/vendor/FreeImage/Source/LibJPEG/jmemansi.c +167 -0
  172. data/vendor/FreeImage/Source/LibJPEG/jmemdos.c +638 -0
  173. data/vendor/FreeImage/Source/LibJPEG/jmemmac.c +289 -0
  174. data/vendor/FreeImage/Source/LibJPEG/jmemmgr.c +1119 -0
  175. data/vendor/FreeImage/Source/LibJPEG/jmemname.c +276 -0
  176. data/vendor/FreeImage/Source/LibJPEG/jmemnobs.c +109 -0
  177. data/vendor/FreeImage/Source/LibJPEG/jmemsys.h +198 -0
  178. data/vendor/FreeImage/Source/LibJPEG/jmorecfg.h +442 -0
  179. data/vendor/FreeImage/Source/LibJPEG/jpegint.h +426 -0
  180. data/vendor/FreeImage/Source/LibJPEG/jpeglib.h +1180 -0
  181. data/vendor/FreeImage/Source/LibJPEG/jpegtran.c +577 -0
  182. data/vendor/FreeImage/Source/LibJPEG/jquant1.c +857 -0
  183. data/vendor/FreeImage/Source/LibJPEG/jquant2.c +1311 -0
  184. data/vendor/FreeImage/Source/LibJPEG/jutils.c +227 -0
  185. data/vendor/FreeImage/Source/LibJPEG/jversion.h +14 -0
  186. data/vendor/FreeImage/Source/LibJPEG/rdbmp.c +480 -0
  187. data/vendor/FreeImage/Source/LibJPEG/rdcolmap.c +253 -0
  188. data/vendor/FreeImage/Source/LibJPEG/rdgif.c +38 -0
  189. data/vendor/FreeImage/Source/LibJPEG/rdjpgcom.c +515 -0
  190. data/vendor/FreeImage/Source/LibJPEG/rdppm.c +459 -0
  191. data/vendor/FreeImage/Source/LibJPEG/rdrle.c +387 -0
  192. data/vendor/FreeImage/Source/LibJPEG/rdswitch.c +365 -0
  193. data/vendor/FreeImage/Source/LibJPEG/rdtarga.c +500 -0
  194. data/vendor/FreeImage/Source/LibJPEG/transupp.c +1763 -0
  195. data/vendor/FreeImage/Source/LibJPEG/transupp.h +219 -0
  196. data/vendor/FreeImage/Source/LibJPEG/wrbmp.c +442 -0
  197. data/vendor/FreeImage/Source/LibJPEG/wrgif.c +399 -0
  198. data/vendor/FreeImage/Source/LibJPEG/wrjpgcom.c +583 -0
  199. data/vendor/FreeImage/Source/LibJPEG/wrppm.c +269 -0
  200. data/vendor/FreeImage/Source/LibJPEG/wrrle.c +305 -0
  201. data/vendor/FreeImage/Source/LibJPEG/wrtarga.c +253 -0
  202. data/vendor/FreeImage/Source/LibJXR/common/include/guiddef.h +230 -0
  203. data/vendor/FreeImage/Source/LibJXR/common/include/wmsal.h +757 -0
  204. data/vendor/FreeImage/Source/LibJXR/common/include/wmspecstring.h +342 -0
  205. data/vendor/FreeImage/Source/LibJXR/common/include/wmspecstrings_adt.h +71 -0
  206. data/vendor/FreeImage/Source/LibJXR/common/include/wmspecstrings_strict.h +1096 -0
  207. data/vendor/FreeImage/Source/LibJXR/common/include/wmspecstrings_undef.h +406 -0
  208. data/vendor/FreeImage/Source/LibJXR/image/decode/JXRTranscode.c +987 -0
  209. data/vendor/FreeImage/Source/LibJXR/image/decode/decode.c +200 -0
  210. data/vendor/FreeImage/Source/LibJXR/image/decode/decode.h +143 -0
  211. data/vendor/FreeImage/Source/LibJXR/image/decode/postprocess.c +288 -0
  212. data/vendor/FreeImage/Source/LibJXR/image/decode/segdec.c +1205 -0
  213. data/vendor/FreeImage/Source/LibJXR/image/decode/strInvTransform.c +1888 -0
  214. data/vendor/FreeImage/Source/LibJXR/image/decode/strPredQuantDec.c +539 -0
  215. data/vendor/FreeImage/Source/LibJXR/image/decode/strdec.c +3628 -0
  216. data/vendor/FreeImage/Source/LibJXR/image/decode/strdec_x86.c +1640 -0
  217. data/vendor/FreeImage/Source/LibJXR/image/encode/encode.c +144 -0
  218. data/vendor/FreeImage/Source/LibJXR/image/encode/encode.h +113 -0
  219. data/vendor/FreeImage/Source/LibJXR/image/encode/segenc.c +1186 -0
  220. data/vendor/FreeImage/Source/LibJXR/image/encode/strFwdTransform.c +1111 -0
  221. data/vendor/FreeImage/Source/LibJXR/image/encode/strPredQuantEnc.c +511 -0
  222. data/vendor/FreeImage/Source/LibJXR/image/encode/strenc.c +2370 -0
  223. data/vendor/FreeImage/Source/LibJXR/image/encode/strenc_x86.c +409 -0
  224. data/vendor/FreeImage/Source/LibJXR/image/sys/adapthuff.c +511 -0
  225. data/vendor/FreeImage/Source/LibJXR/image/sys/ansi.h +61 -0
  226. data/vendor/FreeImage/Source/LibJXR/image/sys/common.h +131 -0
  227. data/vendor/FreeImage/Source/LibJXR/image/sys/image.c +183 -0
  228. data/vendor/FreeImage/Source/LibJXR/image/sys/perfTimer.h +115 -0
  229. data/vendor/FreeImage/Source/LibJXR/image/sys/perfTimerANSI.c +274 -0
  230. data/vendor/FreeImage/Source/LibJXR/image/sys/strPredQuant.c +306 -0
  231. data/vendor/FreeImage/Source/LibJXR/image/sys/strTransform.c +85 -0
  232. data/vendor/FreeImage/Source/LibJXR/image/sys/strTransform.h +50 -0
  233. data/vendor/FreeImage/Source/LibJXR/image/sys/strcodec.c +1251 -0
  234. data/vendor/FreeImage/Source/LibJXR/image/sys/strcodec.h +681 -0
  235. data/vendor/FreeImage/Source/LibJXR/image/sys/windowsmediaphoto.h +515 -0
  236. data/vendor/FreeImage/Source/LibJXR/image/sys/xplatform_image.h +84 -0
  237. data/vendor/FreeImage/Source/LibJXR/image/x86/x86.h +58 -0
  238. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRGlue.c +930 -0
  239. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRGlue.h +636 -0
  240. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRGlueJxr.c +2246 -0
  241. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRGluePFC.c +2338 -0
  242. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRMeta.c +905 -0
  243. data/vendor/FreeImage/Source/LibJXR/jxrgluelib/JXRMeta.h +258 -0
  244. data/vendor/FreeImage/Source/LibOpenJPEG/bio.c +188 -0
  245. data/vendor/FreeImage/Source/LibOpenJPEG/bio.h +128 -0
  246. data/vendor/FreeImage/Source/LibOpenJPEG/cidx_manager.c +239 -0
  247. data/vendor/FreeImage/Source/LibOpenJPEG/cidx_manager.h +68 -0
  248. data/vendor/FreeImage/Source/LibOpenJPEG/cio.c +644 -0
  249. data/vendor/FreeImage/Source/LibOpenJPEG/cio.h +393 -0
  250. data/vendor/FreeImage/Source/LibOpenJPEG/dwt.c +919 -0
  251. data/vendor/FreeImage/Source/LibOpenJPEG/dwt.h +116 -0
  252. data/vendor/FreeImage/Source/LibOpenJPEG/event.c +141 -0
  253. data/vendor/FreeImage/Source/LibOpenJPEG/event.h +97 -0
  254. data/vendor/FreeImage/Source/LibOpenJPEG/function_list.c +114 -0
  255. data/vendor/FreeImage/Source/LibOpenJPEG/function_list.h +126 -0
  256. data/vendor/FreeImage/Source/LibOpenJPEG/image.c +235 -0
  257. data/vendor/FreeImage/Source/LibOpenJPEG/image.h +63 -0
  258. data/vendor/FreeImage/Source/LibOpenJPEG/indexbox_manager.h +148 -0
  259. data/vendor/FreeImage/Source/LibOpenJPEG/invert.c +289 -0
  260. data/vendor/FreeImage/Source/LibOpenJPEG/invert.h +59 -0
  261. data/vendor/FreeImage/Source/LibOpenJPEG/j2k.c +10238 -0
  262. data/vendor/FreeImage/Source/LibOpenJPEG/j2k.h +838 -0
  263. data/vendor/FreeImage/Source/LibOpenJPEG/jp2.c +2776 -0
  264. data/vendor/FreeImage/Source/LibOpenJPEG/jp2.h +490 -0
  265. data/vendor/FreeImage/Source/LibOpenJPEG/mct.c +319 -0
  266. data/vendor/FreeImage/Source/LibOpenJPEG/mct.h +149 -0
  267. data/vendor/FreeImage/Source/LibOpenJPEG/mqc.c +604 -0
  268. data/vendor/FreeImage/Source/LibOpenJPEG/mqc.h +201 -0
  269. data/vendor/FreeImage/Source/LibOpenJPEG/openjpeg.c +955 -0
  270. data/vendor/FreeImage/Source/LibOpenJPEG/openjpeg.h +1475 -0
  271. data/vendor/FreeImage/Source/LibOpenJPEG/opj_clock.c +59 -0
  272. data/vendor/FreeImage/Source/LibOpenJPEG/opj_clock.h +54 -0
  273. data/vendor/FreeImage/Source/LibOpenJPEG/opj_codec.h +160 -0
  274. data/vendor/FreeImage/Source/LibOpenJPEG/opj_config.h +9 -0
  275. data/vendor/FreeImage/Source/LibOpenJPEG/opj_config_private.h +16 -0
  276. data/vendor/FreeImage/Source/LibOpenJPEG/opj_includes.h +175 -0
  277. data/vendor/FreeImage/Source/LibOpenJPEG/opj_intmath.h +172 -0
  278. data/vendor/FreeImage/Source/LibOpenJPEG/opj_inttypes.h +43 -0
  279. data/vendor/FreeImage/Source/LibOpenJPEG/opj_malloc.h +180 -0
  280. data/vendor/FreeImage/Source/LibOpenJPEG/opj_stdint.h +47 -0
  281. data/vendor/FreeImage/Source/LibOpenJPEG/phix_manager.c +191 -0
  282. data/vendor/FreeImage/Source/LibOpenJPEG/pi.c +1870 -0
  283. data/vendor/FreeImage/Source/LibOpenJPEG/pi.h +182 -0
  284. data/vendor/FreeImage/Source/LibOpenJPEG/ppix_manager.c +194 -0
  285. data/vendor/FreeImage/Source/LibOpenJPEG/raw.c +89 -0
  286. data/vendor/FreeImage/Source/LibOpenJPEG/raw.h +100 -0
  287. data/vendor/FreeImage/Source/LibOpenJPEG/t1.c +1751 -0
  288. data/vendor/FreeImage/Source/LibOpenJPEG/t1.h +157 -0
  289. data/vendor/FreeImage/Source/LibOpenJPEG/t1_generate_luts.c +276 -0
  290. data/vendor/FreeImage/Source/LibOpenJPEG/t1_luts.h +143 -0
  291. data/vendor/FreeImage/Source/LibOpenJPEG/t2.c +1334 -0
  292. data/vendor/FreeImage/Source/LibOpenJPEG/t2.h +127 -0
  293. data/vendor/FreeImage/Source/LibOpenJPEG/tcd.c +2123 -0
  294. data/vendor/FreeImage/Source/LibOpenJPEG/tcd.h +348 -0
  295. data/vendor/FreeImage/Source/LibOpenJPEG/tgt.c +331 -0
  296. data/vendor/FreeImage/Source/LibOpenJPEG/tgt.h +140 -0
  297. data/vendor/FreeImage/Source/LibOpenJPEG/thix_manager.c +134 -0
  298. data/vendor/FreeImage/Source/LibOpenJPEG/tpix_manager.c +185 -0
  299. data/vendor/FreeImage/Source/LibPNG/example.c +1061 -0
  300. data/vendor/FreeImage/Source/LibPNG/png.c +4493 -0
  301. data/vendor/FreeImage/Source/LibPNG/png.h +3282 -0
  302. data/vendor/FreeImage/Source/LibPNG/pngconf.h +644 -0
  303. data/vendor/FreeImage/Source/LibPNG/pngdebug.h +154 -0
  304. data/vendor/FreeImage/Source/LibPNG/pngerror.c +963 -0
  305. data/vendor/FreeImage/Source/LibPNG/pngget.c +1213 -0
  306. data/vendor/FreeImage/Source/LibPNG/pnginfo.h +260 -0
  307. data/vendor/FreeImage/Source/LibPNG/pnglibconf.h +218 -0
  308. data/vendor/FreeImage/Source/LibPNG/pngmem.c +281 -0
  309. data/vendor/FreeImage/Source/LibPNG/pngpread.c +1168 -0
  310. data/vendor/FreeImage/Source/LibPNG/pngpriv.h +1944 -0
  311. data/vendor/FreeImage/Source/LibPNG/pngread.c +4121 -0
  312. data/vendor/FreeImage/Source/LibPNG/pngrio.c +120 -0
  313. data/vendor/FreeImage/Source/LibPNG/pngrtran.c +4994 -0
  314. data/vendor/FreeImage/Source/LibPNG/pngrutil.c +4474 -0
  315. data/vendor/FreeImage/Source/LibPNG/pngset.c +1611 -0
  316. data/vendor/FreeImage/Source/LibPNG/pngstruct.h +489 -0
  317. data/vendor/FreeImage/Source/LibPNG/pngtest.c +2011 -0
  318. data/vendor/FreeImage/Source/LibPNG/pngtrans.c +849 -0
  319. data/vendor/FreeImage/Source/LibPNG/pngwio.c +168 -0
  320. data/vendor/FreeImage/Source/LibPNG/pngwrite.c +2455 -0
  321. data/vendor/FreeImage/Source/LibPNG/pngwtran.c +574 -0
  322. data/vendor/FreeImage/Source/LibPNG/pngwutil.c +3029 -0
  323. data/vendor/FreeImage/Source/LibRawLite/dcraw/dcraw.c +15462 -0
  324. data/vendor/FreeImage/Source/LibRawLite/internal/aahd_demosaic.cpp +706 -0
  325. data/vendor/FreeImage/Source/LibRawLite/internal/dcb_demosaicing.c +710 -0
  326. data/vendor/FreeImage/Source/LibRawLite/internal/dcraw_common.cpp +13593 -0
  327. data/vendor/FreeImage/Source/LibRawLite/internal/dcraw_fileio.cpp +240 -0
  328. data/vendor/FreeImage/Source/LibRawLite/internal/defines.h +167 -0
  329. data/vendor/FreeImage/Source/LibRawLite/internal/demosaic_packs.cpp +99 -0
  330. data/vendor/FreeImage/Source/LibRawLite/internal/dht_demosaic.cpp +873 -0
  331. data/vendor/FreeImage/Source/LibRawLite/internal/libraw_internal_funcs.h +282 -0
  332. data/vendor/FreeImage/Source/LibRawLite/internal/libraw_x3f.cpp +1919 -0
  333. data/vendor/FreeImage/Source/LibRawLite/internal/var_defines.h +216 -0
  334. data/vendor/FreeImage/Source/LibRawLite/internal/wf_filtering.cpp +1950 -0
  335. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw.h +338 -0
  336. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_alloc.h +99 -0
  337. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_const.h +233 -0
  338. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_datastream.h +238 -0
  339. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_internal.h +225 -0
  340. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_types.h +442 -0
  341. data/vendor/FreeImage/Source/LibRawLite/libraw/libraw_version.h +62 -0
  342. data/vendor/FreeImage/Source/LibRawLite/src/libraw_c_api.cpp +230 -0
  343. data/vendor/FreeImage/Source/LibRawLite/src/libraw_cxx.cpp +4533 -0
  344. data/vendor/FreeImage/Source/LibRawLite/src/libraw_datastream.cpp +703 -0
  345. data/vendor/FreeImage/Source/LibTIFF4/mkg3states.c +451 -0
  346. data/vendor/FreeImage/Source/LibTIFF4/mkspans.c +82 -0
  347. data/vendor/FreeImage/Source/LibTIFF4/t4.h +292 -0
  348. data/vendor/FreeImage/Source/LibTIFF4/tif_aux.c +358 -0
  349. data/vendor/FreeImage/Source/LibTIFF4/tif_close.c +140 -0
  350. data/vendor/FreeImage/Source/LibTIFF4/tif_codec.c +166 -0
  351. data/vendor/FreeImage/Source/LibTIFF4/tif_color.c +287 -0
  352. data/vendor/FreeImage/Source/LibTIFF4/tif_compress.c +304 -0
  353. data/vendor/FreeImage/Source/LibTIFF4/tif_config.h +97 -0
  354. data/vendor/FreeImage/Source/LibTIFF4/tif_config.vc.h +74 -0
  355. data/vendor/FreeImage/Source/LibTIFF4/tif_config.wince.h +71 -0
  356. data/vendor/FreeImage/Source/LibTIFF4/tif_dir.c +1700 -0
  357. data/vendor/FreeImage/Source/LibTIFF4/tif_dir.h +308 -0
  358. data/vendor/FreeImage/Source/LibTIFF4/tif_dirinfo.c +959 -0
  359. data/vendor/FreeImage/Source/LibTIFF4/tif_dirread.c +5640 -0
  360. data/vendor/FreeImage/Source/LibTIFF4/tif_dirwrite.c +2910 -0
  361. data/vendor/FreeImage/Source/LibTIFF4/tif_dumpmode.c +143 -0
  362. data/vendor/FreeImage/Source/LibTIFF4/tif_error.c +80 -0
  363. data/vendor/FreeImage/Source/LibTIFF4/tif_extension.c +118 -0
  364. data/vendor/FreeImage/Source/LibTIFF4/tif_fax3.c +1595 -0
  365. data/vendor/FreeImage/Source/LibTIFF4/tif_fax3.h +538 -0
  366. data/vendor/FreeImage/Source/LibTIFF4/tif_fax3sm.c +1260 -0
  367. data/vendor/FreeImage/Source/LibTIFF4/tif_flush.c +118 -0
  368. data/vendor/FreeImage/Source/LibTIFF4/tif_getimage.c +2890 -0
  369. data/vendor/FreeImage/Source/LibTIFF4/tif_jbig.c +213 -0
  370. data/vendor/FreeImage/Source/LibTIFF4/tif_jpeg.c +2354 -0
  371. data/vendor/FreeImage/Source/LibTIFF4/tif_jpeg_12.c +65 -0
  372. data/vendor/FreeImage/Source/LibTIFF4/tif_luv.c +1683 -0
  373. data/vendor/FreeImage/Source/LibTIFF4/tif_lzma.c +495 -0
  374. data/vendor/FreeImage/Source/LibTIFF4/tif_lzw.c +1169 -0
  375. data/vendor/FreeImage/Source/LibTIFF4/tif_next.c +181 -0
  376. data/vendor/FreeImage/Source/LibTIFF4/tif_ojpeg.c +2501 -0
  377. data/vendor/FreeImage/Source/LibTIFF4/tif_open.c +725 -0
  378. data/vendor/FreeImage/Source/LibTIFF4/tif_packbits.c +300 -0
  379. data/vendor/FreeImage/Source/LibTIFF4/tif_pixarlog.c +1442 -0
  380. data/vendor/FreeImage/Source/LibTIFF4/tif_predict.c +764 -0
  381. data/vendor/FreeImage/Source/LibTIFF4/tif_predict.h +77 -0
  382. data/vendor/FreeImage/Source/LibTIFF4/tif_print.c +716 -0
  383. data/vendor/FreeImage/Source/LibTIFF4/tif_read.c +1086 -0
  384. data/vendor/FreeImage/Source/LibTIFF4/tif_strip.c +383 -0
  385. data/vendor/FreeImage/Source/LibTIFF4/tif_swab.c +310 -0
  386. data/vendor/FreeImage/Source/LibTIFF4/tif_thunder.c +207 -0
  387. data/vendor/FreeImage/Source/LibTIFF4/tif_tile.c +299 -0
  388. data/vendor/FreeImage/Source/LibTIFF4/tif_unix.c +325 -0
  389. data/vendor/FreeImage/Source/LibTIFF4/tif_version.c +40 -0
  390. data/vendor/FreeImage/Source/LibTIFF4/tif_vms.c +603 -0
  391. data/vendor/FreeImage/Source/LibTIFF4/tif_warning.c +81 -0
  392. data/vendor/FreeImage/Source/LibTIFF4/tif_win32.c +443 -0
  393. data/vendor/FreeImage/Source/LibTIFF4/tif_wince.c +293 -0
  394. data/vendor/FreeImage/Source/LibTIFF4/tif_write.c +771 -0
  395. data/vendor/FreeImage/Source/LibTIFF4/tif_zip.c +472 -0
  396. data/vendor/FreeImage/Source/LibTIFF4/tiff.h +681 -0
  397. data/vendor/FreeImage/Source/LibTIFF4/tiffconf.h +170 -0
  398. data/vendor/FreeImage/Source/LibTIFF4/tiffconf.vc.h +160 -0
  399. data/vendor/FreeImage/Source/LibTIFF4/tiffconf.wince.h +121 -0
  400. data/vendor/FreeImage/Source/LibTIFF4/tiffio.h +557 -0
  401. data/vendor/FreeImage/Source/LibTIFF4/tiffiop.h +367 -0
  402. data/vendor/FreeImage/Source/LibTIFF4/tiffvers.h +9 -0
  403. data/vendor/FreeImage/Source/LibTIFF4/uvcode.h +180 -0
  404. data/vendor/FreeImage/Source/LibWebP/src/dec/alphai.h +55 -0
  405. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.alpha.c +167 -0
  406. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.buffer.c +249 -0
  407. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.frame.c +827 -0
  408. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.idec.c +857 -0
  409. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.io.c +640 -0
  410. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.quant.c +110 -0
  411. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.tree.c +525 -0
  412. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.vp8.c +663 -0
  413. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.vp8l.c +1584 -0
  414. data/vendor/FreeImage/Source/LibWebP/src/dec/dec.webp.c +834 -0
  415. data/vendor/FreeImage/Source/LibWebP/src/dec/decode_vp8.h +185 -0
  416. data/vendor/FreeImage/Source/LibWebP/src/dec/vp8i.h +353 -0
  417. data/vendor/FreeImage/Source/LibWebP/src/dec/vp8li.h +136 -0
  418. data/vendor/FreeImage/Source/LibWebP/src/dec/webpi.h +120 -0
  419. data/vendor/FreeImage/Source/LibWebP/src/demux/demux.demux.c +957 -0
  420. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.alpha_processing.c +377 -0
  421. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.alpha_processing_mips_dsp_r2.c +139 -0
  422. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.alpha_processing_sse2.c +296 -0
  423. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.argb.c +68 -0
  424. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.argb_mips_dsp_r2.c +108 -0
  425. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.argb_sse2.c +62 -0
  426. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.cost.c +412 -0
  427. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.cost_mips32.c +154 -0
  428. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.cost_mips_dsp_r2.c +107 -0
  429. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.cost_sse2.c +121 -0
  430. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.cpu.c +138 -0
  431. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec.c +760 -0
  432. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec_clip_tables.c +366 -0
  433. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec_mips32.c +585 -0
  434. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec_mips_dsp_r2.c +992 -0
  435. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec_neon.c +1489 -0
  436. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.dec_sse2.c +1284 -0
  437. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc.c +788 -0
  438. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc_avx2.c +24 -0
  439. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc_mips32.c +670 -0
  440. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc_mips_dsp_r2.c +1510 -0
  441. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc_neon.c +932 -0
  442. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.enc_sse2.c +940 -0
  443. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.filters.c +240 -0
  444. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.filters_mips_dsp_r2.c +404 -0
  445. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.filters_sse2.c +349 -0
  446. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.h +434 -0
  447. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.lossless.c +1838 -0
  448. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.lossless_mips32.c +416 -0
  449. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.lossless_mips_dsp_r2.c +921 -0
  450. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.lossless_neon.c +357 -0
  451. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.lossless_sse2.c +535 -0
  452. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.rescaler.c +115 -0
  453. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.rescaler_mips32.c +192 -0
  454. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.rescaler_mips_dsp_r2.c +210 -0
  455. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.upsampling.c +252 -0
  456. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.upsampling_mips_dsp_r2.c +280 -0
  457. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.upsampling_neon.c +267 -0
  458. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.upsampling_sse2.c +214 -0
  459. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.yuv.c +166 -0
  460. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.yuv_mips32.c +100 -0
  461. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.yuv_mips_dsp_r2.c +131 -0
  462. data/vendor/FreeImage/Source/LibWebP/src/dsp/dsp.yuv_sse2.c +322 -0
  463. data/vendor/FreeImage/Source/LibWebP/src/dsp/lossless.h +313 -0
  464. data/vendor/FreeImage/Source/LibWebP/src/dsp/mips_macro.h +200 -0
  465. data/vendor/FreeImage/Source/LibWebP/src/dsp/neon.h +82 -0
  466. data/vendor/FreeImage/Source/LibWebP/src/dsp/yuv.h +321 -0
  467. data/vendor/FreeImage/Source/LibWebP/src/dsp/yuv_tables_sse2.h +536 -0
  468. data/vendor/FreeImage/Source/LibWebP/src/enc/backward_references.h +202 -0
  469. data/vendor/FreeImage/Source/LibWebP/src/enc/cost.h +69 -0
  470. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.alpha.c +440 -0
  471. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.analysis.c +501 -0
  472. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.backward_references.c +1076 -0
  473. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.config.c +163 -0
  474. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.cost.c +355 -0
  475. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.filter.c +296 -0
  476. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.frame.c +850 -0
  477. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.histogram.c +897 -0
  478. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.iterator.c +456 -0
  479. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.near_lossless.c +160 -0
  480. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.picture.c +290 -0
  481. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.picture_csp.c +1100 -0
  482. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.picture_psnr.c +150 -0
  483. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.picture_rescale.c +285 -0
  484. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.picture_tools.c +206 -0
  485. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.quant.c +1191 -0
  486. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.syntax.c +383 -0
  487. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.token.c +285 -0
  488. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.tree.c +504 -0
  489. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.vp8l.c +1437 -0
  490. data/vendor/FreeImage/Source/LibWebP/src/enc/enc.webpenc.c +379 -0
  491. data/vendor/FreeImage/Source/LibWebP/src/enc/histogram.h +114 -0
  492. data/vendor/FreeImage/Source/LibWebP/src/enc/vp8enci.h +551 -0
  493. data/vendor/FreeImage/Source/LibWebP/src/enc/vp8li.h +78 -0
  494. data/vendor/FreeImage/Source/LibWebP/src/mux/mux.anim_encode.c +1241 -0
  495. data/vendor/FreeImage/Source/LibWebP/src/mux/mux.muxedit.c +696 -0
  496. data/vendor/FreeImage/Source/LibWebP/src/mux/mux.muxinternal.c +551 -0
  497. data/vendor/FreeImage/Source/LibWebP/src/mux/mux.muxread.c +544 -0
  498. data/vendor/FreeImage/Source/LibWebP/src/mux/muxi.h +232 -0
  499. data/vendor/FreeImage/Source/LibWebP/src/utils/bit_reader.h +168 -0
  500. data/vendor/FreeImage/Source/LibWebP/src/utils/bit_reader_inl.h +172 -0
  501. data/vendor/FreeImage/Source/LibWebP/src/utils/bit_writer.h +120 -0
  502. data/vendor/FreeImage/Source/LibWebP/src/utils/color_cache.h +74 -0
  503. data/vendor/FreeImage/Source/LibWebP/src/utils/endian_inl.h +100 -0
  504. data/vendor/FreeImage/Source/LibWebP/src/utils/filters.h +32 -0
  505. data/vendor/FreeImage/Source/LibWebP/src/utils/huffman.h +67 -0
  506. data/vendor/FreeImage/Source/LibWebP/src/utils/huffman_encode.h +60 -0
  507. data/vendor/FreeImage/Source/LibWebP/src/utils/quant_levels.h +36 -0
  508. data/vendor/FreeImage/Source/LibWebP/src/utils/quant_levels_dec.h +35 -0
  509. data/vendor/FreeImage/Source/LibWebP/src/utils/random.h +63 -0
  510. data/vendor/FreeImage/Source/LibWebP/src/utils/rescaler.h +78 -0
  511. data/vendor/FreeImage/Source/LibWebP/src/utils/thread.h +93 -0
  512. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.bit_reader.c +208 -0
  513. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.bit_writer.c +308 -0
  514. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.color_cache.c +49 -0
  515. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.filters.c +76 -0
  516. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.h +121 -0
  517. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.huffman.c +205 -0
  518. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.huffman_encode.c +417 -0
  519. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.quant_levels.c +140 -0
  520. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.quant_levels_dec.c +279 -0
  521. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.random.c +43 -0
  522. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.rescaler.c +82 -0
  523. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.thread.c +309 -0
  524. data/vendor/FreeImage/Source/LibWebP/src/utils/utils.utils.c +211 -0
  525. data/vendor/FreeImage/Source/LibWebP/src/webp/decode.h +493 -0
  526. data/vendor/FreeImage/Source/LibWebP/src/webp/demux.h +224 -0
  527. data/vendor/FreeImage/Source/LibWebP/src/webp/encode.h +515 -0
  528. data/vendor/FreeImage/Source/LibWebP/src/webp/format_constants.h +88 -0
  529. data/vendor/FreeImage/Source/LibWebP/src/webp/mux.h +507 -0
  530. data/vendor/FreeImage/Source/LibWebP/src/webp/mux_types.h +97 -0
  531. data/vendor/FreeImage/Source/LibWebP/src/webp/types.h +52 -0
  532. data/vendor/FreeImage/Source/MapIntrospector.h +212 -0
  533. data/vendor/FreeImage/Source/Metadata/Exif.cpp +1253 -0
  534. data/vendor/FreeImage/Source/Metadata/FIRational.cpp +176 -0
  535. data/vendor/FreeImage/Source/Metadata/FIRational.h +108 -0
  536. data/vendor/FreeImage/Source/Metadata/FreeImageTag.cpp +353 -0
  537. data/vendor/FreeImage/Source/Metadata/FreeImageTag.h +500 -0
  538. data/vendor/FreeImage/Source/Metadata/IPTC.cpp +342 -0
  539. data/vendor/FreeImage/Source/Metadata/TagConversion.cpp +1094 -0
  540. data/vendor/FreeImage/Source/Metadata/TagLib.cpp +1618 -0
  541. data/vendor/FreeImage/Source/Metadata/XTIFF.cpp +766 -0
  542. data/vendor/FreeImage/Source/OpenEXR/Half/eLut.cpp +114 -0
  543. data/vendor/FreeImage/Source/OpenEXR/Half/eLut.h +71 -0
  544. data/vendor/FreeImage/Source/OpenEXR/Half/half.cpp +310 -0
  545. data/vendor/FreeImage/Source/OpenEXR/Half/half.h +757 -0
  546. data/vendor/FreeImage/Source/OpenEXR/Half/halfExport.h +27 -0
  547. data/vendor/FreeImage/Source/OpenEXR/Half/halfFunction.h +179 -0
  548. data/vendor/FreeImage/Source/OpenEXR/Half/halfLimits.h +102 -0
  549. data/vendor/FreeImage/Source/OpenEXR/Half/toFloat.cpp +164 -0
  550. data/vendor/FreeImage/Source/OpenEXR/Half/toFloat.h +16391 -0
  551. data/vendor/FreeImage/Source/OpenEXR/Iex/Iex.h +60 -0
  552. data/vendor/FreeImage/Source/OpenEXR/Iex/IexBaseExc.cpp +156 -0
  553. data/vendor/FreeImage/Source/OpenEXR/Iex/IexBaseExc.h +264 -0
  554. data/vendor/FreeImage/Source/OpenEXR/Iex/IexErrnoExc.h +208 -0
  555. data/vendor/FreeImage/Source/OpenEXR/Iex/IexExport.h +51 -0
  556. data/vendor/FreeImage/Source/OpenEXR/Iex/IexForward.h +229 -0
  557. data/vendor/FreeImage/Source/OpenEXR/Iex/IexMacros.h +170 -0
  558. data/vendor/FreeImage/Source/OpenEXR/Iex/IexMathExc.h +57 -0
  559. data/vendor/FreeImage/Source/OpenEXR/Iex/IexNamespace.h +112 -0
  560. data/vendor/FreeImage/Source/OpenEXR/Iex/IexThrowErrnoExc.cpp +873 -0
  561. data/vendor/FreeImage/Source/OpenEXR/Iex/IexThrowErrnoExc.h +97 -0
  562. data/vendor/FreeImage/Source/OpenEXR/IexMath/IexMathFloatExc.cpp +113 -0
  563. data/vendor/FreeImage/Source/OpenEXR/IexMath/IexMathFloatExc.h +146 -0
  564. data/vendor/FreeImage/Source/OpenEXR/IexMath/IexMathFpu.cpp +530 -0
  565. data/vendor/FreeImage/Source/OpenEXR/IexMath/IexMathFpu.h +91 -0
  566. data/vendor/FreeImage/Source/OpenEXR/IexMath/IexMathIeeeExc.h +62 -0
  567. data/vendor/FreeImage/Source/OpenEXR/IlmBaseConfig.h +61 -0
  568. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfAcesFile.cpp +633 -0
  569. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfAcesFile.h +324 -0
  570. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfArray.h +285 -0
  571. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfAttribute.cpp +158 -0
  572. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfAttribute.h +407 -0
  573. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfAutoArray.h +95 -0
  574. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfB44Compressor.cpp +1072 -0
  575. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfB44Compressor.h +118 -0
  576. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfBoxAttribute.cpp +111 -0
  577. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfBoxAttribute.h +87 -0
  578. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCRgbaFile.cpp +1438 -0
  579. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCRgbaFile.h +555 -0
  580. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChannelList.cpp +322 -0
  581. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChannelList.h +436 -0
  582. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChannelListAttribute.cpp +150 -0
  583. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChannelListAttribute.h +74 -0
  584. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCheckedArithmetic.h +163 -0
  585. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChromaticities.cpp +151 -0
  586. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChromaticities.h +131 -0
  587. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChromaticitiesAttribute.cpp +87 -0
  588. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfChromaticitiesAttribute.h +73 -0
  589. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompositeDeepScanLine.cpp +591 -0
  590. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompositeDeepScanLine.h +142 -0
  591. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompression.h +84 -0
  592. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompressionAttribute.cpp +78 -0
  593. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompressionAttribute.h +64 -0
  594. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompressor.cpp +226 -0
  595. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfCompressor.h +265 -0
  596. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfConvert.cpp +143 -0
  597. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfConvert.h +107 -0
  598. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepCompositing.cpp +110 -0
  599. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepCompositing.h +132 -0
  600. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepFrameBuffer.cpp +230 -0
  601. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepFrameBuffer.h +339 -0
  602. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepImageState.h +96 -0
  603. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepImageStateAttribute.cpp +78 -0
  604. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepImageStateAttribute.h +68 -0
  605. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineInputFile.cpp +2025 -0
  606. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineInputFile.h +276 -0
  607. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineInputPart.cpp +149 -0
  608. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineInputPart.h +181 -0
  609. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineOutputFile.cpp +1552 -0
  610. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineOutputFile.h +244 -0
  611. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineOutputPart.cpp +107 -0
  612. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepScanLineOutputPart.h +168 -0
  613. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledInputFile.cpp +1979 -0
  614. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledInputFile.h +437 -0
  615. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledInputPart.cpp +273 -0
  616. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledInputPart.h +362 -0
  617. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledOutputFile.cpp +2055 -0
  618. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledOutputFile.h +475 -0
  619. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledOutputPart.cpp +250 -0
  620. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDeepTiledOutputPart.h +394 -0
  621. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDoubleAttribute.cpp +57 -0
  622. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDoubleAttribute.h +59 -0
  623. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDwaCompressor.cpp +3424 -0
  624. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDwaCompressor.h +210 -0
  625. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfDwaCompressorSimd.h +2145 -0
  626. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfEnvmap.cpp +335 -0
  627. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfEnvmap.h +336 -0
  628. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfEnvmapAttribute.cpp +76 -0
  629. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfEnvmapAttribute.h +68 -0
  630. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfExport.h +46 -0
  631. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFastHuf.cpp +768 -0
  632. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFastHuf.h +148 -0
  633. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFloatAttribute.cpp +57 -0
  634. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFloatAttribute.h +58 -0
  635. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFloatVectorAttribute.cpp +84 -0
  636. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFloatVectorAttribute.h +76 -0
  637. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfForward.h +127 -0
  638. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFrameBuffer.cpp +228 -0
  639. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFrameBuffer.h +386 -0
  640. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFramesPerSecond.cpp +76 -0
  641. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfFramesPerSecond.h +94 -0
  642. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfGenericInputFile.cpp +76 -0
  643. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfGenericInputFile.h +58 -0
  644. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfGenericOutputFile.cpp +112 -0
  645. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfGenericOutputFile.h +62 -0
  646. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfHeader.cpp +1283 -0
  647. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfHeader.h +699 -0
  648. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfHuf.cpp +1114 -0
  649. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfHuf.h +82 -0
  650. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfIO.cpp +110 -0
  651. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfIO.h +255 -0
  652. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputFile.cpp +895 -0
  653. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputFile.h +240 -0
  654. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputPart.cpp +114 -0
  655. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputPart.h +84 -0
  656. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputPartData.cpp +51 -0
  657. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputPartData.h +69 -0
  658. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInputStreamMutex.h +68 -0
  659. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfInt64.h +56 -0
  660. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfIntAttribute.cpp +57 -0
  661. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfIntAttribute.h +58 -0
  662. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfKeyCode.cpp +217 -0
  663. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfKeyCode.h +167 -0
  664. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfKeyCodeAttribute.cpp +99 -0
  665. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfKeyCodeAttribute.h +73 -0
  666. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfLineOrder.h +69 -0
  667. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfLineOrderAttribute.cpp +78 -0
  668. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfLineOrderAttribute.h +72 -0
  669. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfLut.cpp +178 -0
  670. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfLut.h +188 -0
  671. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMatrixAttribute.cpp +263 -0
  672. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMatrixAttribute.h +83 -0
  673. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMisc.cpp +1872 -0
  674. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMisc.h +466 -0
  675. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiPartInputFile.cpp +783 -0
  676. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiPartInputFile.h +128 -0
  677. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiPartOutputFile.cpp +519 -0
  678. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiPartOutputFile.h +118 -0
  679. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiView.cpp +435 -0
  680. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfMultiView.h +187 -0
  681. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfName.h +150 -0
  682. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfNamespace.h +115 -0
  683. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOpaqueAttribute.cpp +126 -0
  684. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOpaqueAttribute.h +110 -0
  685. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOptimizedPixelReading.h +646 -0
  686. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputFile.cpp +1378 -0
  687. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputFile.h +263 -0
  688. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputPart.cpp +105 -0
  689. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputPart.h +77 -0
  690. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputPartData.cpp +52 -0
  691. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputPartData.h +62 -0
  692. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfOutputStreamMutex.h +70 -0
  693. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPartHelper.h +262 -0
  694. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPartType.cpp +63 -0
  695. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPartType.h +62 -0
  696. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPixelType.h +67 -0
  697. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPizCompressor.cpp +667 -0
  698. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPizCompressor.h +117 -0
  699. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPreviewImage.cpp +104 -0
  700. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPreviewImage.h +135 -0
  701. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPreviewImageAttribute.cpp +103 -0
  702. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPreviewImageAttribute.h +70 -0
  703. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPxr24Compressor.cpp +553 -0
  704. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfPxr24Compressor.h +109 -0
  705. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRational.cpp +127 -0
  706. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRational.h +98 -0
  707. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRationalAttribute.cpp +74 -0
  708. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRationalAttribute.h +69 -0
  709. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRgba.h +109 -0
  710. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRgbaFile.cpp +1405 -0
  711. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRgbaFile.h +346 -0
  712. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRgbaYca.cpp +497 -0
  713. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRgbaYca.h +259 -0
  714. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRle.cpp +157 -0
  715. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRle.h +63 -0
  716. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRleCompressor.cpp +220 -0
  717. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfRleCompressor.h +80 -0
  718. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfScanLineInputFile.cpp +1702 -0
  719. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfScanLineInputFile.h +210 -0
  720. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfSimd.h +59 -0
  721. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStandardAttributes.cpp +125 -0
  722. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStandardAttributes.h +382 -0
  723. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStdIO.cpp +242 -0
  724. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStdIO.h +160 -0
  725. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStringAttribute.cpp +80 -0
  726. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStringAttribute.h +71 -0
  727. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStringVectorAttribute.cpp +100 -0
  728. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfStringVectorAttribute.h +74 -0
  729. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfSystemSpecific.cpp +129 -0
  730. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfSystemSpecific.h +172 -0
  731. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTestFile.cpp +216 -0
  732. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTestFile.h +97 -0
  733. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfThreading.cpp +62 -0
  734. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfThreading.h +95 -0
  735. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTileDescription.h +107 -0
  736. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTileDescriptionAttribute.cpp +86 -0
  737. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTileDescriptionAttribute.h +72 -0
  738. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTileOffsets.cpp +552 -0
  739. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTileOffsets.h +125 -0
  740. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledInputFile.cpp +1533 -0
  741. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledInputFile.h +401 -0
  742. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledInputPart.cpp +208 -0
  743. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledInputPart.h +100 -0
  744. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledMisc.cpp +389 -0
  745. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledMisc.h +106 -0
  746. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledOutputFile.cpp +1841 -0
  747. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledOutputFile.h +495 -0
  748. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledOutputPart.cpp +228 -0
  749. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledOutputPart.h +105 -0
  750. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledRgbaFile.cpp +1163 -0
  751. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTiledRgbaFile.h +482 -0
  752. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTimeCode.cpp +431 -0
  753. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTimeCode.h +242 -0
  754. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTimeCodeAttribute.cpp +79 -0
  755. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfTimeCodeAttribute.h +74 -0
  756. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfVecAttribute.cpp +217 -0
  757. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfVecAttribute.h +100 -0
  758. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfVersion.cpp +60 -0
  759. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfVersion.h +136 -0
  760. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfWav.cpp +391 -0
  761. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfWav.h +78 -0
  762. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfXdr.h +927 -0
  763. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfZip.cpp +196 -0
  764. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfZip.h +78 -0
  765. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfZipCompressor.cpp +127 -0
  766. data/vendor/FreeImage/Source/OpenEXR/IlmImf/ImfZipCompressor.h +89 -0
  767. data/vendor/FreeImage/Source/OpenEXR/IlmImf/b44ExpLogTable.cpp +136 -0
  768. data/vendor/FreeImage/Source/OpenEXR/IlmImf/b44ExpLogTable.h +16396 -0
  769. data/vendor/FreeImage/Source/OpenEXR/IlmImf/dwaLookups.cpp +573 -0
  770. data/vendor/FreeImage/Source/OpenEXR/IlmImf/dwaLookups.h +98334 -0
  771. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThread.cpp +80 -0
  772. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThread.h +143 -0
  773. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadExport.h +46 -0
  774. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadForward.h +52 -0
  775. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadMutex.cpp +59 -0
  776. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadMutex.h +160 -0
  777. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadMutexPosix.cpp +85 -0
  778. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadMutexWin32.cpp +79 -0
  779. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadNamespace.h +114 -0
  780. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadPool.cpp +483 -0
  781. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadPool.h +160 -0
  782. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadPosix.cpp +98 -0
  783. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadSemaphore.cpp +60 -0
  784. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadSemaphore.h +112 -0
  785. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadSemaphorePosix.cpp +106 -0
  786. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadSemaphorePosixCompat.cpp +155 -0
  787. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadSemaphoreWin32.cpp +153 -0
  788. data/vendor/FreeImage/Source/OpenEXR/IlmThread/IlmThreadWin32.cpp +100 -0
  789. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathBox.cpp +37 -0
  790. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathBox.h +849 -0
  791. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathBoxAlgo.h +1016 -0
  792. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathColor.h +736 -0
  793. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathColorAlgo.cpp +178 -0
  794. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathColorAlgo.h +257 -0
  795. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathEuler.h +926 -0
  796. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathExc.h +73 -0
  797. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathExport.h +46 -0
  798. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathForward.h +72 -0
  799. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathFrame.h +192 -0
  800. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathFrustum.h +741 -0
  801. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathFrustumTest.h +417 -0
  802. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathFun.cpp +181 -0
  803. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathFun.h +269 -0
  804. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathGL.h +166 -0
  805. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathGLU.h +54 -0
  806. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathHalfLimits.h +68 -0
  807. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathInt64.h +62 -0
  808. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathInterval.h +226 -0
  809. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathLimits.h +268 -0
  810. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathLine.h +185 -0
  811. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathLineAlgo.h +288 -0
  812. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathMath.h +208 -0
  813. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathMatrix.h +3441 -0
  814. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathMatrixAlgo.cpp +1252 -0
  815. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathMatrixAlgo.h +1425 -0
  816. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathNamespace.h +115 -0
  817. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathPlane.h +257 -0
  818. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathPlatform.h +112 -0
  819. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathQuat.h +964 -0
  820. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathRandom.cpp +194 -0
  821. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathRandom.h +401 -0
  822. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathRoots.h +219 -0
  823. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathShear.cpp +54 -0
  824. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathShear.h +656 -0
  825. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathSphere.h +177 -0
  826. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathVec.cpp +583 -0
  827. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathVec.h +2227 -0
  828. data/vendor/FreeImage/Source/OpenEXR/Imath/ImathVecAlgo.h +147 -0
  829. data/vendor/FreeImage/Source/OpenEXR/OpenEXRConfig.h +72 -0
  830. data/vendor/FreeImage/Source/Plugin.h +144 -0
  831. data/vendor/FreeImage/Source/Quantizers.h +354 -0
  832. data/vendor/FreeImage/Source/ToneMapping.h +44 -0
  833. data/vendor/FreeImage/Source/Utilities.h +516 -0
  834. data/vendor/FreeImage/Source/ZLib/adler32.c +179 -0
  835. data/vendor/FreeImage/Source/ZLib/compress.c +80 -0
  836. data/vendor/FreeImage/Source/ZLib/crc32.c +425 -0
  837. data/vendor/FreeImage/Source/ZLib/crc32.h +441 -0
  838. data/vendor/FreeImage/Source/ZLib/deflate.c +1967 -0
  839. data/vendor/FreeImage/Source/ZLib/deflate.h +346 -0
  840. data/vendor/FreeImage/Source/ZLib/gzclose.c +25 -0
  841. data/vendor/FreeImage/Source/ZLib/gzguts.h +209 -0
  842. data/vendor/FreeImage/Source/ZLib/gzlib.c +634 -0
  843. data/vendor/FreeImage/Source/ZLib/gzread.c +594 -0
  844. data/vendor/FreeImage/Source/ZLib/gzwrite.c +577 -0
  845. data/vendor/FreeImage/Source/ZLib/infback.c +640 -0
  846. data/vendor/FreeImage/Source/ZLib/inffast.c +340 -0
  847. data/vendor/FreeImage/Source/ZLib/inffast.h +11 -0
  848. data/vendor/FreeImage/Source/ZLib/inffixed.h +94 -0
  849. data/vendor/FreeImage/Source/ZLib/inflate.c +1512 -0
  850. data/vendor/FreeImage/Source/ZLib/inflate.h +122 -0
  851. data/vendor/FreeImage/Source/ZLib/inftrees.c +306 -0
  852. data/vendor/FreeImage/Source/ZLib/inftrees.h +62 -0
  853. data/vendor/FreeImage/Source/ZLib/trees.c +1226 -0
  854. data/vendor/FreeImage/Source/ZLib/trees.h +128 -0
  855. data/vendor/FreeImage/Source/ZLib/uncompr.c +59 -0
  856. data/vendor/FreeImage/Source/ZLib/zconf.h +511 -0
  857. data/vendor/FreeImage/Source/ZLib/zlib.h +1768 -0
  858. data/vendor/FreeImage/Source/ZLib/zutil.c +324 -0
  859. data/vendor/FreeImage/Source/ZLib/zutil.h +253 -0
  860. metadata +931 -0
@@ -0,0 +1,1475 @@
1
+ /*
2
+ * Copyright (c) 2002-2007, Communications and Remote Sensing Laboratory, Universite catholique de Louvain (UCL), Belgium
3
+ * Copyright (c) 2002-2007, Professor Benoit Macq
4
+ * Copyright (c) 2001-2003, David Janssens
5
+ * Copyright (c) 2002-2003, Yannick Verschueren
6
+ * Copyright (c) 2003-2007, Francois-Olivier Devaux and Antonin Descampe
7
+ * Copyright (c) 2005, Herve Drolon, FreeImage Team
8
+ * Copyright (c) 2006-2007, Parvatha Elangovan
9
+ * Copyright (c) 2008, Jerome Fimes, Communications & Systemes <jerome.fimes@c-s.fr>
10
+ * Copyright (c) 2010-2011, Kaori Hagihara
11
+ * Copyright (c) 2011-2012, Centre National d'Etudes Spatiales (CNES), France
12
+ * Copyright (c) 2012, CS Systemes d'Information, France
13
+ * All rights reserved.
14
+ *
15
+ * Redistribution and use in source and binary forms, with or without
16
+ * modification, are permitted provided that the following conditions
17
+ * are met:
18
+ * 1. Redistributions of source code must retain the above copyright
19
+ * notice, this list of conditions and the following disclaimer.
20
+ * 2. Redistributions in binary form must reproduce the above copyright
21
+ * notice, this list of conditions and the following disclaimer in the
22
+ * documentation and/or other materials provided with the distribution.
23
+ *
24
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS `AS IS'
25
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
26
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
27
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
28
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
29
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
30
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
31
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
32
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
33
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
34
+ * POSSIBILITY OF SUCH DAMAGE.
35
+ */
36
+ #ifndef OPENJPEG_H
37
+ #define OPENJPEG_H
38
+
39
+
40
+ /*
41
+ ==========================================================
42
+ Compiler directives
43
+ ==========================================================
44
+ */
45
+
46
+ /*
47
+ The inline keyword is supported by C99 but not by C90.
48
+ Most compilers implement their own version of this keyword ...
49
+ */
50
+ #ifndef INLINE
51
+ #if defined(_MSC_VER)
52
+ #define INLINE __forceinline
53
+ #elif defined(__GNUC__)
54
+ #define INLINE __inline__
55
+ #elif defined(__MWERKS__)
56
+ #define INLINE inline
57
+ #else
58
+ /* add other compilers here ... */
59
+ #define INLINE
60
+ #endif /* defined(<Compiler>) */
61
+ #endif /* INLINE */
62
+
63
+ /* deprecated attribute */
64
+ #ifdef __GNUC__
65
+ #define OPJ_DEPRECATED(func) func __attribute__ ((deprecated))
66
+ #elif defined(_MSC_VER)
67
+ #define OPJ_DEPRECATED(func) __declspec(deprecated) func
68
+ #else
69
+ #pragma message("WARNING: You need to implement DEPRECATED for this compiler")
70
+ #define OPJ_DEPRECATED(func) func
71
+ #endif
72
+
73
+ #if defined(OPJ_STATIC) || !defined(_WIN32)
74
+ #define OPJ_API
75
+ #define OPJ_LOCAL
76
+ #define OPJ_CALLCONV
77
+ #else
78
+ #define OPJ_CALLCONV __stdcall
79
+ /*
80
+ The following ifdef block is the standard way of creating macros which make exporting
81
+ from a DLL simpler. All files within this DLL are compiled with the OPJ_EXPORTS
82
+ symbol defined on the command line. this symbol should not be defined on any project
83
+ that uses this DLL. This way any other project whose source files include this file see
84
+ OPJ_API functions as being imported from a DLL, wheras this DLL sees symbols
85
+ defined with this macro as being exported.
86
+ */
87
+ #if defined(OPJ_EXPORTS) || defined(DLL_EXPORT)
88
+ #define OPJ_API __declspec(dllexport)
89
+ #else
90
+ #define OPJ_API __declspec(dllimport)
91
+ #endif /* OPJ_EXPORTS */
92
+ #endif /* !OPJ_STATIC || !_WIN32 */
93
+
94
+ typedef int OPJ_BOOL;
95
+ #define OPJ_TRUE 1
96
+ #define OPJ_FALSE 0
97
+
98
+ typedef char OPJ_CHAR;
99
+ typedef float OPJ_FLOAT32;
100
+ typedef double OPJ_FLOAT64;
101
+ typedef unsigned char OPJ_BYTE;
102
+
103
+ #include "opj_stdint.h"
104
+
105
+ typedef int8_t OPJ_INT8;
106
+ typedef uint8_t OPJ_UINT8;
107
+ typedef int16_t OPJ_INT16;
108
+ typedef uint16_t OPJ_UINT16;
109
+ typedef int32_t OPJ_INT32;
110
+ typedef uint32_t OPJ_UINT32;
111
+ typedef int64_t OPJ_INT64;
112
+ typedef uint64_t OPJ_UINT64;
113
+
114
+ typedef int64_t OPJ_OFF_T; /* 64-bit file offset type */
115
+
116
+ #include <stdio.h>
117
+ typedef size_t OPJ_SIZE_T;
118
+
119
+ /* Avoid compile-time warning because parameter is not used */
120
+ #define OPJ_ARG_NOT_USED(x) (void)(x)
121
+
122
+ /*
123
+ ==========================================================
124
+ Useful constant definitions
125
+ ==========================================================
126
+ */
127
+
128
+ #define OPJ_PATH_LEN 4096 /**< Maximum allowed size for filenames */
129
+
130
+ #define OPJ_J2K_MAXRLVLS 33 /**< Number of maximum resolution level authorized */
131
+ #define OPJ_J2K_MAXBANDS (3*OPJ_J2K_MAXRLVLS-2) /**< Number of maximum sub-band linked to number of resolution level */
132
+
133
+ #define OPJ_J2K_DEFAULT_NB_SEGS 10
134
+ #define OPJ_J2K_STREAM_CHUNK_SIZE 0x100000 /** 1 mega by default */
135
+ #define OPJ_J2K_DEFAULT_HEADER_SIZE 1000
136
+ #define OPJ_J2K_MCC_DEFAULT_NB_RECORDS 10
137
+ #define OPJ_J2K_MCT_DEFAULT_NB_RECORDS 10
138
+
139
+ /* UniPG>> */ /* NOT YET USED IN THE V2 VERSION OF OPENJPEG */
140
+ #define JPWL_MAX_NO_TILESPECS 16 /**< Maximum number of tile parts expected by JPWL: increase at your will */
141
+ #define JPWL_MAX_NO_PACKSPECS 16 /**< Maximum number of packet parts expected by JPWL: increase at your will */
142
+ #define JPWL_MAX_NO_MARKERS 512 /**< Maximum number of JPWL markers: increase at your will */
143
+ #define JPWL_PRIVATEINDEX_NAME "jpwl_index_privatefilename" /**< index file name used when JPWL is on */
144
+ #define JPWL_EXPECTED_COMPONENTS 3 /**< Expect this number of components, so you'll find better the first EPB */
145
+ #define JPWL_MAXIMUM_TILES 8192 /**< Expect this maximum number of tiles, to avoid some crashes */
146
+ #define JPWL_MAXIMUM_HAMMING 2 /**< Expect this maximum number of bit errors in marker id's */
147
+ #define JPWL_MAXIMUM_EPB_ROOM 65450 /**< Expect this maximum number of bytes for composition of EPBs */
148
+ /* <<UniPG */
149
+
150
+ /**
151
+ * EXPERIMENTAL FOR THE MOMENT
152
+ * Supported options about file information used only in j2k_dump
153
+ */
154
+ #define OPJ_IMG_INFO 1 /**< Basic image information provided to the user */
155
+ #define OPJ_J2K_MH_INFO 2 /**< Codestream information based only on the main header */
156
+ #define OPJ_J2K_TH_INFO 4 /**< Tile information based on the current tile header */
157
+ #define OPJ_J2K_TCH_INFO 8 /**< Tile/Component information of all tiles */
158
+ #define OPJ_J2K_MH_IND 16 /**< Codestream index based only on the main header */
159
+ #define OPJ_J2K_TH_IND 32 /**< Tile index based on the current tile */
160
+ /*FIXME #define OPJ_J2K_CSTR_IND 48*/ /**< */
161
+ #define OPJ_JP2_INFO 128 /**< JP2 file information */
162
+ #define OPJ_JP2_IND 256 /**< JP2 file index */
163
+
164
+
165
+ /*
166
+ ==========================================================
167
+ enum definitions
168
+ ==========================================================
169
+ */
170
+ /**
171
+ * Rsiz Capabilities
172
+ * */
173
+ typedef enum RSIZ_CAPABILITIES {
174
+ OPJ_STD_RSIZ = 0, /** Standard JPEG2000 profile*/
175
+ OPJ_CINEMA2K = 3, /** Profile name for a 2K image*/
176
+ OPJ_CINEMA4K = 4, /** Profile name for a 4K image*/
177
+ OPJ_MCT = 0x8100
178
+ } OPJ_RSIZ_CAPABILITIES;
179
+
180
+ /**
181
+ * Digital cinema operation mode
182
+ * */
183
+ typedef enum CINEMA_MODE {
184
+ OPJ_OFF = 0, /** Not Digital Cinema*/
185
+ OPJ_CINEMA2K_24 = 1, /** 2K Digital Cinema at 24 fps*/
186
+ OPJ_CINEMA2K_48 = 2, /** 2K Digital Cinema at 48 fps*/
187
+ OPJ_CINEMA4K_24 = 3 /** 4K Digital Cinema at 24 fps*/
188
+ }OPJ_CINEMA_MODE;
189
+
190
+ /**
191
+ * Progression order
192
+ * */
193
+ typedef enum PROG_ORDER {
194
+ OPJ_PROG_UNKNOWN = -1, /**< place-holder */
195
+ OPJ_LRCP = 0, /**< layer-resolution-component-precinct order */
196
+ OPJ_RLCP = 1, /**< resolution-layer-component-precinct order */
197
+ OPJ_RPCL = 2, /**< resolution-precinct-component-layer order */
198
+ OPJ_PCRL = 3, /**< precinct-component-resolution-layer order */
199
+ OPJ_CPRL = 4 /**< component-precinct-resolution-layer order */
200
+ } OPJ_PROG_ORDER;
201
+
202
+ /**
203
+ * Supported image color spaces
204
+ */
205
+ typedef enum COLOR_SPACE {
206
+ OPJ_CLRSPC_UNKNOWN = -1, /**< not supported by the library */
207
+ OPJ_CLRSPC_UNSPECIFIED = 0, /**< not specified in the codestream */
208
+ OPJ_CLRSPC_SRGB = 1, /**< sRGB */
209
+ OPJ_CLRSPC_GRAY = 2, /**< grayscale */
210
+ OPJ_CLRSPC_SYCC = 3, /**< YUV */
211
+ OPJ_CLRSPC_EYCC = 4 /**< e-YCC */
212
+ } OPJ_COLOR_SPACE;
213
+
214
+ /**
215
+ * Supported codec
216
+ */
217
+ typedef enum CODEC_FORMAT {
218
+ OPJ_CODEC_UNKNOWN = -1, /**< place-holder */
219
+ OPJ_CODEC_J2K = 0, /**< JPEG-2000 codestream : read/write */
220
+ OPJ_CODEC_JPT = 1, /**< JPT-stream (JPEG 2000, JPIP) : read only */
221
+ OPJ_CODEC_JP2 = 2 /**< JPEG-2000 file format : read/write */
222
+ } OPJ_CODEC_FORMAT;
223
+
224
+
225
+ /*
226
+ ==========================================================
227
+ event manager typedef definitions
228
+ ==========================================================
229
+ */
230
+
231
+ /**
232
+ * Callback function prototype for events
233
+ * @param msg Event message
234
+ * @param client_data Client object where will be return the event message
235
+ * */
236
+ typedef void (*opj_msg_callback) (const char *msg, void *client_data);
237
+
238
+ /*
239
+ ==========================================================
240
+ codec typedef definitions
241
+ ==========================================================
242
+ */
243
+
244
+ /**
245
+ * Progression order changes
246
+ *
247
+ */
248
+ typedef struct opj_poc {
249
+ /** Resolution num start, Component num start, given by POC */
250
+ OPJ_UINT32 resno0, compno0;
251
+ /** Layer num end,Resolution num end, Component num end, given by POC */
252
+ OPJ_UINT32 layno1, resno1, compno1;
253
+ /** Layer num start,Precinct num start, Precinct num end */
254
+ OPJ_UINT32 layno0, precno0, precno1;
255
+ /** Progression order enum*/
256
+ OPJ_PROG_ORDER prg1,prg;
257
+ /** Progression order string*/
258
+ OPJ_CHAR progorder[5];
259
+ /** Tile number */
260
+ OPJ_UINT32 tile;
261
+ /** Start and end values for Tile width and height*/
262
+ OPJ_INT32 tx0,tx1,ty0,ty1;
263
+ /** Start value, initialised in pi_initialise_encode*/
264
+ OPJ_UINT32 layS, resS, compS, prcS;
265
+ /** End value, initialised in pi_initialise_encode */
266
+ OPJ_UINT32 layE, resE, compE, prcE;
267
+ /** Start and end values of Tile width and height, initialised in pi_initialise_encode*/
268
+ OPJ_UINT32 txS,txE,tyS,tyE,dx,dy;
269
+ /** Temporary values for Tile parts, initialised in pi_create_encode */
270
+ OPJ_UINT32 lay_t, res_t, comp_t, prc_t,tx0_t,ty0_t;
271
+ } opj_poc_t;
272
+
273
+ /**
274
+ * Compression parameters
275
+ * */
276
+ typedef struct opj_cparameters {
277
+ /** size of tile: tile_size_on = false (not in argument) or = true (in argument) */
278
+ OPJ_BOOL tile_size_on;
279
+ /** XTOsiz */
280
+ int cp_tx0;
281
+ /** YTOsiz */
282
+ int cp_ty0;
283
+ /** XTsiz */
284
+ int cp_tdx;
285
+ /** YTsiz */
286
+ int cp_tdy;
287
+ /** allocation by rate/distortion */
288
+ int cp_disto_alloc;
289
+ /** allocation by fixed layer */
290
+ int cp_fixed_alloc;
291
+ /** add fixed_quality */
292
+ int cp_fixed_quality;
293
+ /** fixed layer */
294
+ int *cp_matrice;
295
+ /** comment for coding */
296
+ char *cp_comment;
297
+ /** csty : coding style */
298
+ int csty;
299
+ /** progression order (default OPJ_LRCP) */
300
+ OPJ_PROG_ORDER prog_order;
301
+ /** progression order changes */
302
+ opj_poc_t POC[32];
303
+ /** number of progression order changes (POC), default to 0 */
304
+ OPJ_UINT32 numpocs;
305
+ /** number of layers */
306
+ int tcp_numlayers;
307
+ /** rates of layers */
308
+ float tcp_rates[100];
309
+ /** different psnr for successive layers */
310
+ float tcp_distoratio[100];
311
+ /** number of resolutions */
312
+ int numresolution;
313
+ /** initial code block width, default to 64 */
314
+ int cblockw_init;
315
+ /** initial code block height, default to 64 */
316
+ int cblockh_init;
317
+ /** mode switch (cblk_style) */
318
+ int mode;
319
+ /** 1 : use the irreversible DWT 9-7, 0 : use lossless compression (default) */
320
+ int irreversible;
321
+ /** region of interest: affected component in [0..3], -1 means no ROI */
322
+ int roi_compno;
323
+ /** region of interest: upshift value */
324
+ int roi_shift;
325
+ /* number of precinct size specifications */
326
+ int res_spec;
327
+ /** initial precinct width */
328
+ int prcw_init[OPJ_J2K_MAXRLVLS];
329
+ /** initial precinct height */
330
+ int prch_init[OPJ_J2K_MAXRLVLS];
331
+
332
+ /**@name command line encoder parameters (not used inside the library) */
333
+ /*@{*/
334
+ /** input file name */
335
+ char infile[OPJ_PATH_LEN];
336
+ /** output file name */
337
+ char outfile[OPJ_PATH_LEN];
338
+ /** DEPRECATED. Index generation is now handeld with the opj_encode_with_info() function. Set to NULL */
339
+ int index_on;
340
+ /** DEPRECATED. Index generation is now handeld with the opj_encode_with_info() function. Set to NULL */
341
+ char index[OPJ_PATH_LEN];
342
+ /** subimage encoding: origin image offset in x direction */
343
+ int image_offset_x0;
344
+ /** subimage encoding: origin image offset in y direction */
345
+ int image_offset_y0;
346
+ /** subsampling value for dx */
347
+ int subsampling_dx;
348
+ /** subsampling value for dy */
349
+ int subsampling_dy;
350
+ /** input file format 0: PGX, 1: PxM, 2: BMP 3:TIF*/
351
+ int decod_format;
352
+ /** output file format 0: J2K, 1: JP2, 2: JPT */
353
+ int cod_format;
354
+ /*@}*/
355
+
356
+ /* UniPG>> */ /* NOT YET USED IN THE V2 VERSION OF OPENJPEG */
357
+ /**@name JPWL encoding parameters */
358
+ /*@{*/
359
+ /** enables writing of EPC in MH, thus activating JPWL */
360
+ OPJ_BOOL jpwl_epc_on;
361
+ /** error protection method for MH (0,1,16,32,37-128) */
362
+ int jpwl_hprot_MH;
363
+ /** tile number of header protection specification (>=0) */
364
+ int jpwl_hprot_TPH_tileno[JPWL_MAX_NO_TILESPECS];
365
+ /** error protection methods for TPHs (0,1,16,32,37-128) */
366
+ int jpwl_hprot_TPH[JPWL_MAX_NO_TILESPECS];
367
+ /** tile number of packet protection specification (>=0) */
368
+ int jpwl_pprot_tileno[JPWL_MAX_NO_PACKSPECS];
369
+ /** packet number of packet protection specification (>=0) */
370
+ int jpwl_pprot_packno[JPWL_MAX_NO_PACKSPECS];
371
+ /** error protection methods for packets (0,1,16,32,37-128) */
372
+ int jpwl_pprot[JPWL_MAX_NO_PACKSPECS];
373
+ /** enables writing of ESD, (0=no/1/2 bytes) */
374
+ int jpwl_sens_size;
375
+ /** sensitivity addressing size (0=auto/2/4 bytes) */
376
+ int jpwl_sens_addr;
377
+ /** sensitivity range (0-3) */
378
+ int jpwl_sens_range;
379
+ /** sensitivity method for MH (-1=no,0-7) */
380
+ int jpwl_sens_MH;
381
+ /** tile number of sensitivity specification (>=0) */
382
+ int jpwl_sens_TPH_tileno[JPWL_MAX_NO_TILESPECS];
383
+ /** sensitivity methods for TPHs (-1=no,0-7) */
384
+ int jpwl_sens_TPH[JPWL_MAX_NO_TILESPECS];
385
+ /*@}*/
386
+ /* <<UniPG */
387
+
388
+ /** Digital Cinema compliance 0-not compliant, 1-compliant*/
389
+ OPJ_CINEMA_MODE cp_cinema;
390
+ /** Maximum rate for each component. If == 0, component size limitation is not considered */
391
+ int max_comp_size;
392
+ /** Profile name*/
393
+ OPJ_RSIZ_CAPABILITIES cp_rsiz;
394
+ /** Tile part generation*/
395
+ char tp_on;
396
+ /** Flag for Tile part generation*/
397
+ char tp_flag;
398
+ /** MCT (multiple component transform) */
399
+ char tcp_mct;
400
+ /** Enable JPIP indexing*/
401
+ OPJ_BOOL jpip_on;
402
+ /** Naive implementation of MCT restricted to a single reversible array based
403
+ encoding without offset concerning all the components. */
404
+ void * mct_data;
405
+ } opj_cparameters_t;
406
+
407
+ #define OPJ_DPARAMETERS_IGNORE_PCLR_CMAP_CDEF_FLAG 0x0001
408
+
409
+ /**
410
+ * Decompression parameters
411
+ * */
412
+ typedef struct opj_dparameters {
413
+ /**
414
+ Set the number of highest resolution levels to be discarded.
415
+ The image resolution is effectively divided by 2 to the power of the number of discarded levels.
416
+ The reduce factor is limited by the smallest total number of decomposition levels among tiles.
417
+ if != 0, then original dimension divided by 2^(reduce);
418
+ if == 0 or not used, image is decoded to the full resolution
419
+ */
420
+ OPJ_UINT32 cp_reduce;
421
+ /**
422
+ Set the maximum number of quality layers to decode.
423
+ If there are less quality layers than the specified number, all the quality layers are decoded.
424
+ if != 0, then only the first "layer" layers are decoded;
425
+ if == 0 or not used, all the quality layers are decoded
426
+ */
427
+ OPJ_UINT32 cp_layer;
428
+
429
+ /**@name command line decoder parameters (not used inside the library) */
430
+ /*@{*/
431
+ /** input file name */
432
+ char infile[OPJ_PATH_LEN];
433
+ /** output file name */
434
+ char outfile[OPJ_PATH_LEN];
435
+ /** input file format 0: J2K, 1: JP2, 2: JPT */
436
+ int decod_format;
437
+ /** output file format 0: PGX, 1: PxM, 2: BMP */
438
+ int cod_format;
439
+
440
+ /** Decoding area left boundary */
441
+ OPJ_UINT32 DA_x0;
442
+ /** Decoding area right boundary */
443
+ OPJ_UINT32 DA_x1;
444
+ /** Decoding area up boundary */
445
+ OPJ_UINT32 DA_y0;
446
+ /** Decoding area bottom boundary */
447
+ OPJ_UINT32 DA_y1;
448
+ /** Verbose mode */
449
+ OPJ_BOOL m_verbose;
450
+
451
+ /** tile number ot the decoded tile*/
452
+ OPJ_UINT32 tile_index;
453
+ /** Nb of tile to decode */
454
+ OPJ_UINT32 nb_tile_to_decode;
455
+
456
+ /*@}*/
457
+
458
+ /* UniPG>> */ /* NOT YET USED IN THE V2 VERSION OF OPENJPEG */
459
+ /**@name JPWL decoding parameters */
460
+ /*@{*/
461
+ /** activates the JPWL correction capabilities */
462
+ OPJ_BOOL jpwl_correct;
463
+ /** expected number of components */
464
+ int jpwl_exp_comps;
465
+ /** maximum number of tiles */
466
+ int jpwl_max_tiles;
467
+ /*@}*/
468
+ /* <<UniPG */
469
+
470
+ unsigned int flags;
471
+
472
+ } opj_dparameters_t;
473
+
474
+
475
+ /**
476
+ * JPEG2000 codec V2.
477
+ * */
478
+ typedef void * opj_codec_t;
479
+
480
+ /*
481
+ ==========================================================
482
+ I/O stream typedef definitions
483
+ ==========================================================
484
+ */
485
+
486
+ /**
487
+ * Stream open flags.
488
+ * */
489
+ /** The stream was opened for reading. */
490
+ #define OPJ_STREAM_READ OPJ_TRUE
491
+ /** The stream was opened for writing. */
492
+ #define OPJ_STREAM_WRITE OPJ_FALSE
493
+
494
+ /*
495
+ * Callback function prototype for read function
496
+ */
497
+ typedef OPJ_SIZE_T (* opj_stream_read_fn) (void * p_buffer, OPJ_SIZE_T p_nb_bytes, void * p_user_data) ;
498
+
499
+ /*
500
+ * Callback function prototype for write function
501
+ */
502
+ typedef OPJ_SIZE_T (* opj_stream_write_fn) (void * p_buffer, OPJ_SIZE_T p_nb_bytes, void * p_user_data) ;
503
+
504
+ /*
505
+ * Callback function prototype for skip function
506
+ */
507
+ typedef OPJ_OFF_T (* opj_stream_skip_fn) (OPJ_OFF_T p_nb_bytes, void * p_user_data) ;
508
+
509
+ /*
510
+ * Callback function prototype for seek function
511
+ */
512
+ typedef OPJ_BOOL (* opj_stream_seek_fn) (OPJ_OFF_T p_nb_bytes, void * p_user_data) ;
513
+
514
+ /*
515
+ * Callback function prototype for free user data function
516
+ */
517
+ typedef void (* opj_stream_free_user_data_fn) (void * p_user_data) ;
518
+
519
+ /*
520
+ * JPEG2000 Stream.
521
+ */
522
+ typedef void * opj_stream_t;
523
+
524
+ /*
525
+ ==========================================================
526
+ image typedef definitions
527
+ ==========================================================
528
+ */
529
+
530
+ /**
531
+ * Defines a single image component
532
+ * */
533
+ typedef struct opj_image_comp {
534
+ /** XRsiz: horizontal separation of a sample of ith component with respect to the reference grid */
535
+ OPJ_UINT32 dx;
536
+ /** YRsiz: vertical separation of a sample of ith component with respect to the reference grid */
537
+ OPJ_UINT32 dy;
538
+ /** data width */
539
+ OPJ_UINT32 w;
540
+ /** data height */
541
+ OPJ_UINT32 h;
542
+ /** x component offset compared to the whole image */
543
+ OPJ_UINT32 x0;
544
+ /** y component offset compared to the whole image */
545
+ OPJ_UINT32 y0;
546
+ /** precision */
547
+ OPJ_UINT32 prec;
548
+ /** image depth in bits */
549
+ OPJ_UINT32 bpp;
550
+ /** signed (1) / unsigned (0) */
551
+ OPJ_UINT32 sgnd;
552
+ /** number of decoded resolution */
553
+ OPJ_UINT32 resno_decoded;
554
+ /** number of division by 2 of the out image compared to the original size of image */
555
+ OPJ_UINT32 factor;
556
+ /** image component data */
557
+ OPJ_INT32 *data;
558
+ /** alpha channel */
559
+ OPJ_UINT16 alpha;
560
+ } opj_image_comp_t;
561
+
562
+ /**
563
+ * Defines image data and characteristics
564
+ * */
565
+ typedef struct opj_image {
566
+ /** XOsiz: horizontal offset from the origin of the reference grid to the left side of the image area */
567
+ OPJ_UINT32 x0;
568
+ /** YOsiz: vertical offset from the origin of the reference grid to the top side of the image area */
569
+ OPJ_UINT32 y0;
570
+ /** Xsiz: width of the reference grid */
571
+ OPJ_UINT32 x1;
572
+ /** Ysiz: height of the reference grid */
573
+ OPJ_UINT32 y1;
574
+ /** number of components in the image */
575
+ OPJ_UINT32 numcomps;
576
+ /** color space: sRGB, Greyscale or YUV */
577
+ OPJ_COLOR_SPACE color_space;
578
+ /** image components */
579
+ opj_image_comp_t *comps;
580
+ /** 'restricted' ICC profile */
581
+ OPJ_BYTE *icc_profile_buf;
582
+ /** size of ICC profile */
583
+ OPJ_UINT32 icc_profile_len;
584
+ } opj_image_t;
585
+
586
+
587
+ /**
588
+ * Component parameters structure used by the opj_image_create function
589
+ * */
590
+ typedef struct opj_image_comptparm {
591
+ /** XRsiz: horizontal separation of a sample of ith component with respect to the reference grid */
592
+ OPJ_UINT32 dx;
593
+ /** YRsiz: vertical separation of a sample of ith component with respect to the reference grid */
594
+ OPJ_UINT32 dy;
595
+ /** data width */
596
+ OPJ_UINT32 w;
597
+ /** data height */
598
+ OPJ_UINT32 h;
599
+ /** x component offset compared to the whole image */
600
+ OPJ_UINT32 x0;
601
+ /** y component offset compared to the whole image */
602
+ OPJ_UINT32 y0;
603
+ /** precision */
604
+ OPJ_UINT32 prec;
605
+ /** image depth in bits */
606
+ OPJ_UINT32 bpp;
607
+ /** signed (1) / unsigned (0) */
608
+ OPJ_UINT32 sgnd;
609
+ } opj_image_cmptparm_t;
610
+
611
+
612
+ /*
613
+ ==========================================================
614
+ Information on the JPEG 2000 codestream
615
+ ==========================================================
616
+ */
617
+ /* QUITE EXPERIMENTAL FOR THE MOMENT */
618
+
619
+ /**
620
+ * Index structure : Information concerning a packet inside tile
621
+ * */
622
+ typedef struct opj_packet_info {
623
+ /** packet start position (including SOP marker if it exists) */
624
+ OPJ_OFF_T start_pos;
625
+ /** end of packet header position (including EPH marker if it exists)*/
626
+ OPJ_OFF_T end_ph_pos;
627
+ /** packet end position */
628
+ OPJ_OFF_T end_pos;
629
+ /** packet distorsion */
630
+ double disto;
631
+ } opj_packet_info_t;
632
+
633
+
634
+ /* UniPG>> */
635
+ /**
636
+ * Marker structure
637
+ * */
638
+ typedef struct opj_marker_info {
639
+ /** marker type */
640
+ unsigned short int type;
641
+ /** position in codestream */
642
+ OPJ_OFF_T pos;
643
+ /** length, marker val included */
644
+ int len;
645
+ } opj_marker_info_t;
646
+ /* <<UniPG */
647
+
648
+ /**
649
+ * Index structure : Information concerning tile-parts
650
+ */
651
+ typedef struct opj_tp_info {
652
+ /** start position of tile part */
653
+ int tp_start_pos;
654
+ /** end position of tile part header */
655
+ int tp_end_header;
656
+ /** end position of tile part */
657
+ int tp_end_pos;
658
+ /** start packet of tile part */
659
+ int tp_start_pack;
660
+ /** number of packets of tile part */
661
+ int tp_numpacks;
662
+ } opj_tp_info_t;
663
+
664
+ /**
665
+ * Index structure : information regarding tiles
666
+ */
667
+ typedef struct opj_tile_info {
668
+ /** value of thresh for each layer by tile cfr. Marcela */
669
+ double *thresh;
670
+ /** number of tile */
671
+ int tileno;
672
+ /** start position */
673
+ int start_pos;
674
+ /** end position of the header */
675
+ int end_header;
676
+ /** end position */
677
+ int end_pos;
678
+ /** precinct number for each resolution level (width) */
679
+ int pw[33];
680
+ /** precinct number for each resolution level (height) */
681
+ int ph[33];
682
+ /** precinct size (in power of 2), in X for each resolution level */
683
+ int pdx[33];
684
+ /** precinct size (in power of 2), in Y for each resolution level */
685
+ int pdy[33];
686
+ /** information concerning packets inside tile */
687
+ opj_packet_info_t *packet;
688
+ /** add fixed_quality */
689
+ int numpix;
690
+ /** add fixed_quality */
691
+ double distotile;
692
+ /** number of markers */
693
+ int marknum;
694
+ /** list of markers */
695
+ opj_marker_info_t *marker;
696
+ /** actual size of markers array */
697
+ int maxmarknum;
698
+ /** number of tile parts */
699
+ int num_tps;
700
+ /** information concerning tile parts */
701
+ opj_tp_info_t *tp;
702
+ } opj_tile_info_t;
703
+
704
+ /**
705
+ * Index structure of the codestream
706
+ */
707
+ typedef struct opj_codestream_info {
708
+ /** maximum distortion reduction on the whole image (add for Marcela) */
709
+ double D_max;
710
+ /** packet number */
711
+ int packno;
712
+ /** writing the packet in the index with t2_encode_packets */
713
+ int index_write;
714
+ /** image width */
715
+ int image_w;
716
+ /** image height */
717
+ int image_h;
718
+ /** progression order */
719
+ OPJ_PROG_ORDER prog;
720
+ /** tile size in x */
721
+ int tile_x;
722
+ /** tile size in y */
723
+ int tile_y;
724
+ /** */
725
+ int tile_Ox;
726
+ /** */
727
+ int tile_Oy;
728
+ /** number of tiles in X */
729
+ int tw;
730
+ /** number of tiles in Y */
731
+ int th;
732
+ /** component numbers */
733
+ int numcomps;
734
+ /** number of layer */
735
+ int numlayers;
736
+ /** number of decomposition for each component */
737
+ int *numdecompos;
738
+ /* UniPG>> */
739
+ /** number of markers */
740
+ int marknum;
741
+ /** list of markers */
742
+ opj_marker_info_t *marker;
743
+ /** actual size of markers array */
744
+ int maxmarknum;
745
+ /* <<UniPG */
746
+ /** main header position */
747
+ int main_head_start;
748
+ /** main header position */
749
+ int main_head_end;
750
+ /** codestream's size */
751
+ int codestream_size;
752
+ /** information regarding tiles inside image */
753
+ opj_tile_info_t *tile;
754
+ } opj_codestream_info_t;
755
+
756
+ /* <----------------------------------------------------------- */
757
+ /* new output managment of the codestream information and index */
758
+
759
+ /**
760
+ * Tile-component coding parameters information
761
+ */
762
+ typedef struct opj_tccp_info
763
+ {
764
+ /** component index */
765
+ OPJ_UINT32 compno;
766
+ /** coding style */
767
+ OPJ_UINT32 csty;
768
+ /** number of resolutions */
769
+ OPJ_UINT32 numresolutions;
770
+ /** code-blocks width */
771
+ OPJ_UINT32 cblkw;
772
+ /** code-blocks height */
773
+ OPJ_UINT32 cblkh;
774
+ /** code-block coding style */
775
+ OPJ_UINT32 cblksty;
776
+ /** discrete wavelet transform identifier */
777
+ OPJ_UINT32 qmfbid;
778
+ /** quantisation style */
779
+ OPJ_UINT32 qntsty;
780
+ /** stepsizes used for quantization */
781
+ OPJ_UINT32 stepsizes_mant[OPJ_J2K_MAXBANDS];
782
+ /** stepsizes used for quantization */
783
+ OPJ_UINT32 stepsizes_expn[OPJ_J2K_MAXBANDS];
784
+ /** number of guard bits */
785
+ OPJ_UINT32 numgbits;
786
+ /** Region Of Interest shift */
787
+ OPJ_INT32 roishift;
788
+ /** precinct width */
789
+ OPJ_UINT32 prcw[OPJ_J2K_MAXRLVLS];
790
+ /** precinct height */
791
+ OPJ_UINT32 prch[OPJ_J2K_MAXRLVLS];
792
+ }
793
+ opj_tccp_info_t;
794
+
795
+ /**
796
+ * Tile coding parameters information
797
+ */
798
+ typedef struct opj_tile_v2_info {
799
+
800
+ /** number (index) of tile */
801
+ int tileno;
802
+ /** coding style */
803
+ OPJ_UINT32 csty;
804
+ /** progression order */
805
+ OPJ_PROG_ORDER prg;
806
+ /** number of layers */
807
+ OPJ_UINT32 numlayers;
808
+ /** multi-component transform identifier */
809
+ OPJ_UINT32 mct;
810
+
811
+ /** information concerning tile component parameters*/
812
+ opj_tccp_info_t *tccp_info;
813
+
814
+ } opj_tile_info_v2_t;
815
+
816
+ /**
817
+ * Information structure about the codestream (FIXME should be expand and enhance)
818
+ */
819
+ typedef struct opj_codestream_info_v2 {
820
+ /* Tile info */
821
+ /** tile origin in x = XTOsiz */
822
+ OPJ_UINT32 tx0;
823
+ /** tile origin in y = YTOsiz */
824
+ OPJ_UINT32 ty0;
825
+ /** tile size in x = XTsiz */
826
+ OPJ_UINT32 tdx;
827
+ /** tile size in y = YTsiz */
828
+ OPJ_UINT32 tdy;
829
+ /** number of tiles in X */
830
+ OPJ_UINT32 tw;
831
+ /** number of tiles in Y */
832
+ OPJ_UINT32 th;
833
+
834
+ /** number of components*/
835
+ OPJ_UINT32 nbcomps;
836
+
837
+ /** Default information regarding tiles inside image */
838
+ opj_tile_info_v2_t m_default_tile_info;
839
+
840
+ /** information regarding tiles inside image */
841
+ opj_tile_info_v2_t *tile_info; /* FIXME not used for the moment */
842
+
843
+ } opj_codestream_info_v2_t;
844
+
845
+
846
+ /**
847
+ * Index structure about a tile part
848
+ */
849
+ typedef struct opj_tp_index {
850
+ /** start position */
851
+ OPJ_OFF_T start_pos;
852
+ /** end position of the header */
853
+ OPJ_OFF_T end_header;
854
+ /** end position */
855
+ OPJ_OFF_T end_pos;
856
+
857
+ } opj_tp_index_t;
858
+
859
+ /**
860
+ * Index structure about a tile
861
+ */
862
+ typedef struct opj_tile_index {
863
+ /** tile index */
864
+ OPJ_UINT32 tileno;
865
+
866
+ /** number of tile parts */
867
+ OPJ_UINT32 nb_tps;
868
+ /** current nb of tile part (allocated)*/
869
+ OPJ_UINT32 current_nb_tps;
870
+ /** current tile-part index */
871
+ OPJ_UINT32 current_tpsno;
872
+ /** information concerning tile parts */
873
+ opj_tp_index_t *tp_index;
874
+
875
+ /* UniPG>> */ /* NOT USED FOR THE MOMENT IN THE V2 VERSION */
876
+ /** number of markers */
877
+ OPJ_UINT32 marknum;
878
+ /** list of markers */
879
+ opj_marker_info_t *marker;
880
+ /** actual size of markers array */
881
+ OPJ_UINT32 maxmarknum;
882
+ /* <<UniPG */
883
+
884
+ /** packet number */
885
+ OPJ_UINT32 nb_packet;
886
+ /** information concerning packets inside tile */
887
+ opj_packet_info_t *packet_index;
888
+
889
+ } opj_tile_index_t;
890
+
891
+ /**
892
+ * Index structure of the codestream (FIXME should be expand and enhance)
893
+ */
894
+ typedef struct opj_codestream_index {
895
+ /** main header start position (SOC position) */
896
+ OPJ_OFF_T main_head_start;
897
+ /** main header end position (first SOT position) */
898
+ OPJ_OFF_T main_head_end;
899
+
900
+ /** codestream's size */
901
+ OPJ_UINT64 codestream_size;
902
+
903
+ /* UniPG>> */ /* NOT USED FOR THE MOMENT IN THE V2 VERSION */
904
+ /** number of markers */
905
+ OPJ_UINT32 marknum;
906
+ /** list of markers */
907
+ opj_marker_info_t *marker;
908
+ /** actual size of markers array */
909
+ OPJ_UINT32 maxmarknum;
910
+ /* <<UniPG */
911
+
912
+ /** */
913
+ OPJ_UINT32 nb_of_tiles;
914
+ /** */
915
+ opj_tile_index_t *tile_index; /* FIXME not used for the moment */
916
+
917
+ }opj_codestream_index_t;
918
+ /* -----------------------------------------------------------> */
919
+
920
+ /*
921
+ ==========================================================
922
+ Metadata from the JP2file
923
+ ==========================================================
924
+ */
925
+
926
+ /**
927
+ * Info structure of the JP2 file
928
+ * EXPERIMENTAL FOR THE MOMENT
929
+ */
930
+ typedef struct opj_jp2_metadata {
931
+ /** */
932
+ OPJ_INT32 not_used;
933
+
934
+ } opj_jp2_metadata_t;
935
+
936
+ /**
937
+ * Index structure of the JP2 file
938
+ * EXPERIMENTAL FOR THE MOMENT
939
+ */
940
+ typedef struct opj_jp2_index {
941
+ /** */
942
+ OPJ_INT32 not_used;
943
+
944
+ } opj_jp2_index_t;
945
+
946
+
947
+ #ifdef __cplusplus
948
+ extern "C" {
949
+ #endif
950
+
951
+
952
+ /*
953
+ ==========================================================
954
+ openjpeg version
955
+ ==========================================================
956
+ */
957
+
958
+ /* Get the version of the openjpeg library*/
959
+ OPJ_API const char * OPJ_CALLCONV opj_version(void);
960
+
961
+ /*
962
+ ==========================================================
963
+ image functions definitions
964
+ ==========================================================
965
+ */
966
+
967
+ /**
968
+ * Create an image
969
+ *
970
+ * @param numcmpts number of components
971
+ * @param cmptparms components parameters
972
+ * @param clrspc image color space
973
+ * @return returns a new image structure if successful, returns NULL otherwise
974
+ * */
975
+ OPJ_API opj_image_t* OPJ_CALLCONV opj_image_create(OPJ_UINT32 numcmpts, opj_image_cmptparm_t *cmptparms, OPJ_COLOR_SPACE clrspc);
976
+
977
+ /**
978
+ * Deallocate any resources associated with an image
979
+ *
980
+ * @param image image to be destroyed
981
+ */
982
+ OPJ_API void OPJ_CALLCONV opj_image_destroy(opj_image_t *image);
983
+
984
+ /**
985
+ * Creates an image without allocating memory for the image (used in the new version of the library).
986
+ *
987
+ * @param numcmpts the number of components
988
+ * @param cmptparms the components parameters
989
+ * @param clrspc the image color space
990
+ *
991
+ * @return a new image structure if successful, NULL otherwise.
992
+ */
993
+ OPJ_API opj_image_t* OPJ_CALLCONV opj_image_tile_create(OPJ_UINT32 numcmpts, opj_image_cmptparm_t *cmptparms, OPJ_COLOR_SPACE clrspc);
994
+
995
+ /*
996
+ ==========================================================
997
+ stream functions definitions
998
+ ==========================================================
999
+ */
1000
+
1001
+ /**
1002
+ * Creates an abstract stream. This function does nothing except allocating memory and initializing the abstract stream.
1003
+ *
1004
+ * @param p_is_input if set to true then the stream will be an input stream, an output stream else.
1005
+ *
1006
+ * @return a stream object.
1007
+ */
1008
+ OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_default_create(OPJ_BOOL p_is_input);
1009
+
1010
+ /**
1011
+ * Creates an abstract stream. This function does nothing except allocating memory and initializing the abstract stream.
1012
+ *
1013
+ * @param p_buffer_size FIXME DOC
1014
+ * @param p_is_input if set to true then the stream will be an input stream, an output stream else.
1015
+ *
1016
+ * @return a stream object.
1017
+ */
1018
+ OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create(OPJ_SIZE_T p_buffer_size, OPJ_BOOL p_is_input);
1019
+
1020
+ /**
1021
+ * Destroys a stream created by opj_create_stream. This function does NOT close the abstract stream. If needed the user must
1022
+ * close its own implementation of the stream.
1023
+ *
1024
+ * @param p_stream the stream to destroy.
1025
+ */
1026
+ OPJ_API void OPJ_CALLCONV opj_stream_destroy(opj_stream_t* p_stream);
1027
+
1028
+ /**
1029
+ * Destroys a stream created by opj_create_stream. This function does NOT close the abstract stream.
1030
+ * If needed the user must close its own implementation of the stream.
1031
+ *
1032
+ * @param p_stream the stream to destroy.
1033
+ */
1034
+ OPJ_API void OPJ_CALLCONV opj_stream_destroy_v3(opj_stream_t* p_stream);
1035
+
1036
+ /**
1037
+ * Sets the given function to be used as a read function.
1038
+ * @param p_stream the stream to modify
1039
+ * @param p_function the function to use a read function.
1040
+ */
1041
+ OPJ_API void OPJ_CALLCONV opj_stream_set_read_function(opj_stream_t* p_stream, opj_stream_read_fn p_function);
1042
+
1043
+ /**
1044
+ * Sets the given function to be used as a write function.
1045
+ * @param p_stream the stream to modify
1046
+ * @param p_function the function to use a write function.
1047
+ */
1048
+ OPJ_API void OPJ_CALLCONV opj_stream_set_write_function(opj_stream_t* p_stream, opj_stream_write_fn p_function);
1049
+
1050
+ /**
1051
+ * Sets the given function to be used as a skip function.
1052
+ * @param p_stream the stream to modify
1053
+ * @param p_function the function to use a skip function.
1054
+ */
1055
+ OPJ_API void OPJ_CALLCONV opj_stream_set_skip_function(opj_stream_t* p_stream, opj_stream_skip_fn p_function);
1056
+
1057
+ /**
1058
+ * Sets the given function to be used as a seek function, the stream is then seekable.
1059
+ * @param p_stream the stream to modify
1060
+ * @param p_function the function to use a skip function.
1061
+ */
1062
+ OPJ_API void OPJ_CALLCONV opj_stream_set_seek_function(opj_stream_t* p_stream, opj_stream_seek_fn p_function);
1063
+
1064
+ /**
1065
+ * Sets the given data to be used as a user data for the stream.
1066
+ * @param p_stream the stream to modify
1067
+ * @param p_data the data to set.
1068
+ * @param p_function the function to free p_data when opj_stream_destroy() is called.
1069
+ */
1070
+ OPJ_API void OPJ_CALLCONV opj_stream_set_user_data (opj_stream_t* p_stream, void * p_data, opj_stream_free_user_data_fn p_function);
1071
+
1072
+ /**
1073
+ * Sets the length of the user data for the stream.
1074
+ *
1075
+ * @param p_stream the stream to modify
1076
+ * @param data_length length of the user_data.
1077
+ */
1078
+ OPJ_API void OPJ_CALLCONV opj_stream_set_user_data_length(opj_stream_t* p_stream, OPJ_UINT64 data_length);
1079
+
1080
+ /**
1081
+ * Create a stream from a file identified with its filename with default parameters (helper function)
1082
+ * @param fname the filename of the file to stream
1083
+ * @param p_is_read_stream whether the stream is a read stream (true) or not (false)
1084
+ */
1085
+ OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_default_file_stream_v3 (const char *fname, OPJ_BOOL p_is_read_stream);
1086
+
1087
+ /** Create a stream from a file identified with its filename with a specific buffer size
1088
+ * @param fname the filename of the file to stream
1089
+ * @param p_buffer_size size of the chunk used to stream
1090
+ * @param p_is_read_stream whether the stream is a read stream (true) or not (false)
1091
+ */
1092
+ OPJ_API opj_stream_t* OPJ_CALLCONV opj_stream_create_file_stream_v3 (const char *fname,
1093
+ OPJ_SIZE_T p_buffer_size,
1094
+ OPJ_BOOL p_is_read_stream);
1095
+
1096
+ /*
1097
+ ==========================================================
1098
+ event manager functions definitions
1099
+ ==========================================================
1100
+ */
1101
+ /**
1102
+ * Set the info handler use by openjpeg.
1103
+ * @param p_codec the codec previously initialise
1104
+ * @param p_callback the callback function which will be used
1105
+ * @param p_user_data client object where will be returned the message
1106
+ */
1107
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_info_handler(opj_codec_t * p_codec,
1108
+ opj_msg_callback p_callback,
1109
+ void * p_user_data);
1110
+ /**
1111
+ * Set the warning handler use by openjpeg.
1112
+ * @param p_codec the codec previously initialise
1113
+ * @param p_callback the callback function which will be used
1114
+ * @param p_user_data client object where will be returned the message
1115
+ */
1116
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_warning_handler(opj_codec_t * p_codec,
1117
+ opj_msg_callback p_callback,
1118
+ void * p_user_data);
1119
+ /**
1120
+ * Set the error handler use by openjpeg.
1121
+ * @param p_codec the codec previously initialise
1122
+ * @param p_callback the callback function which will be used
1123
+ * @param p_user_data client object where will be returned the message
1124
+ */
1125
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_error_handler(opj_codec_t * p_codec,
1126
+ opj_msg_callback p_callback,
1127
+ void * p_user_data);
1128
+
1129
+ /*
1130
+ ==========================================================
1131
+ codec functions definitions
1132
+ ==========================================================
1133
+ */
1134
+
1135
+ /**
1136
+ * Creates a J2K/JP2 decompression structure
1137
+ * @param format Decoder to select
1138
+ *
1139
+ * @return Returns a handle to a decompressor if successful, returns NULL otherwise
1140
+ * */
1141
+ OPJ_API opj_codec_t* OPJ_CALLCONV opj_create_decompress(OPJ_CODEC_FORMAT format);
1142
+
1143
+ /**
1144
+ * Destroy a decompressor handle
1145
+ *
1146
+ * @param p_codec decompressor handle to destroy
1147
+ */
1148
+ OPJ_API void OPJ_CALLCONV opj_destroy_codec(opj_codec_t * p_codec);
1149
+
1150
+ /**
1151
+ * Read after the codestream if necessary
1152
+ * @param p_codec the JPEG2000 codec to read.
1153
+ * @param p_stream the JPEG2000 stream.
1154
+ */
1155
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_decompress ( opj_codec_t *p_codec,
1156
+ opj_stream_t *p_stream);
1157
+
1158
+
1159
+ /**
1160
+ * Set decoding parameters to default values
1161
+ * @param parameters Decompression parameters
1162
+ */
1163
+ OPJ_API void OPJ_CALLCONV opj_set_default_decoder_parameters(opj_dparameters_t *parameters);
1164
+
1165
+ /**
1166
+ * Setup the decoder with decompression parameters provided by the user and with the message handler
1167
+ * provided by the user.
1168
+ *
1169
+ * @param p_codec decompressor handler
1170
+ * @param parameters decompression parameters
1171
+ *
1172
+ * @return true if the decoder is correctly set
1173
+ */
1174
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_decoder(opj_codec_t *p_codec,
1175
+ opj_dparameters_t *parameters );
1176
+
1177
+ /**
1178
+ * Decodes an image header.
1179
+ *
1180
+ * @param p_stream the jpeg2000 stream.
1181
+ * @param p_codec the jpeg2000 codec to read.
1182
+ * @param p_image the image structure initialized with the characteristics of encoded image.
1183
+ *
1184
+ * @return true if the main header of the codestream and the JP2 header is correctly read.
1185
+ */
1186
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_read_header ( opj_stream_t *p_stream,
1187
+ opj_codec_t *p_codec,
1188
+ opj_image_t **p_image);
1189
+
1190
+ /**
1191
+ * Sets the given area to be decoded. This function should be called right after opj_read_header and before any tile header reading.
1192
+ *
1193
+ * @param p_codec the jpeg2000 codec.
1194
+ * @param p_image the decoded image previously setted by opj_read_header
1195
+ * @param p_start_x the left position of the rectangle to decode (in image coordinates).
1196
+ * @param p_end_x the right position of the rectangle to decode (in image coordinates).
1197
+ * @param p_start_y the up position of the rectangle to decode (in image coordinates).
1198
+ * @param p_end_y the bottom position of the rectangle to decode (in image coordinates).
1199
+ *
1200
+ * @return true if the area could be set.
1201
+ */
1202
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decode_area( opj_codec_t *p_codec,
1203
+ opj_image_t* p_image,
1204
+ OPJ_INT32 p_start_x, OPJ_INT32 p_start_y,
1205
+ OPJ_INT32 p_end_x, OPJ_INT32 p_end_y );
1206
+
1207
+ /**
1208
+ * Decode an image from a JPEG-2000 codestream
1209
+ *
1210
+ * @param p_decompressor decompressor handle
1211
+ * @param p_stream Input buffer stream
1212
+ * @param p_image the decoded image
1213
+ * @return true if success, otherwise false
1214
+ * */
1215
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_decode( opj_codec_t *p_decompressor,
1216
+ opj_stream_t *p_stream,
1217
+ opj_image_t *p_image);
1218
+
1219
+ /**
1220
+ * Get the decoded tile from the codec
1221
+ *
1222
+ * @param p_codec the jpeg2000 codec.
1223
+ * @param p_stream input streamm
1224
+ * @param p_image output image
1225
+ * @param tile_index index of the tile which will be decode
1226
+ *
1227
+ * @return true if success, otherwise false
1228
+ */
1229
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_get_decoded_tile( opj_codec_t *p_codec,
1230
+ opj_stream_t *p_stream,
1231
+ opj_image_t *p_image,
1232
+ OPJ_UINT32 tile_index);
1233
+
1234
+ /**
1235
+ * Set the resolution factor of the decoded image
1236
+ * @param p_codec the jpeg2000 codec.
1237
+ * @param res_factor resolution factor to set
1238
+ *
1239
+ * @return true if success, otherwise false
1240
+ */
1241
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_decoded_resolution_factor(opj_codec_t *p_codec, OPJ_UINT32 res_factor);
1242
+
1243
+ /**
1244
+ * Writes a tile with the given data.
1245
+ *
1246
+ * @param p_codec the jpeg2000 codec.
1247
+ * @param p_tile_index the index of the tile to write. At the moment, the tiles must be written from 0 to n-1 in sequence.
1248
+ * @param p_data pointer to the data to write. Data is arranged in sequence, data_comp0, then data_comp1, then ... NO INTERLEAVING should be set.
1249
+ * @param p_data_size this value os used to make sure the data being written is correct. The size must be equal to the sum for each component of
1250
+ * tile_width * tile_height * component_size. component_size can be 1,2 or 4 bytes, depending on the precision of the given component.
1251
+ * @param p_stream the stream to write data to.
1252
+ *
1253
+ * @return true if the data could be written.
1254
+ */
1255
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_write_tile ( opj_codec_t *p_codec,
1256
+ OPJ_UINT32 p_tile_index,
1257
+ OPJ_BYTE * p_data,
1258
+ OPJ_UINT32 p_data_size,
1259
+ opj_stream_t *p_stream );
1260
+
1261
+ /**
1262
+ * Reads a tile header. This function is compulsory and allows one to know the size of the tile thta will be decoded.
1263
+ * The user may need to refer to the image got by opj_read_header to understand the size being taken by the tile.
1264
+ *
1265
+ * @param p_codec the jpeg2000 codec.
1266
+ * @param p_tile_index pointer to a value that will hold the index of the tile being decoded, in case of success.
1267
+ * @param p_data_size pointer to a value that will hold the maximum size of the decoded data, in case of success. In case
1268
+ * of truncated codestreams, the actual number of bytes decoded may be lower. The computation of the size is the same
1269
+ * as depicted in opj_write_tile.
1270
+ * @param p_tile_x0 pointer to a value that will hold the x0 pos of the tile (in the image).
1271
+ * @param p_tile_y0 pointer to a value that will hold the y0 pos of the tile (in the image).
1272
+ * @param p_tile_x1 pointer to a value that will hold the x1 pos of the tile (in the image).
1273
+ * @param p_tile_y1 pointer to a value that will hold the y1 pos of the tile (in the image).
1274
+ * @param p_nb_comps pointer to a value that will hold the number of components in the tile.
1275
+ * @param p_should_go_on pointer to a boolean that will hold the fact that the decoding should go on. In case the
1276
+ * codestream is over at the time of the call, the value will be set to false. The user should then stop
1277
+ * the decoding.
1278
+ * @param p_stream the stream to decode.
1279
+ * @return true if the tile header could be decoded. In case the decoding should end, the returned value is still true.
1280
+ * returning false may be the result of a shortage of memory or an internal error.
1281
+ */
1282
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_read_tile_header( opj_codec_t *p_codec,
1283
+ opj_stream_t * p_stream,
1284
+ OPJ_UINT32 * p_tile_index,
1285
+ OPJ_UINT32 * p_data_size,
1286
+ OPJ_INT32 * p_tile_x0, OPJ_INT32 * p_tile_y0,
1287
+ OPJ_INT32 * p_tile_x1, OPJ_INT32 * p_tile_y1,
1288
+ OPJ_UINT32 * p_nb_comps,
1289
+ OPJ_BOOL * p_should_go_on );
1290
+
1291
+ /**
1292
+ * Reads a tile data. This function is compulsory and allows one to decode tile data. opj_read_tile_header should be called before.
1293
+ * The user may need to refer to the image got by opj_read_header to understand the size being taken by the tile.
1294
+ *
1295
+ * @param p_codec the jpeg2000 codec.
1296
+ * @param p_tile_index the index of the tile being decoded, this should be the value set by opj_read_tile_header.
1297
+ * @param p_data pointer to a memory block that will hold the decoded data.
1298
+ * @param p_data_size size of p_data. p_data_size should be bigger or equal to the value set by opj_read_tile_header.
1299
+ * @param p_stream the stream to decode.
1300
+ *
1301
+ * @return true if the data could be decoded.
1302
+ */
1303
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_decode_tile_data( opj_codec_t *p_codec,
1304
+ OPJ_UINT32 p_tile_index,
1305
+ OPJ_BYTE * p_data,
1306
+ OPJ_UINT32 p_data_size,
1307
+ opj_stream_t *p_stream );
1308
+
1309
+ /* COMPRESSION FUNCTIONS*/
1310
+
1311
+ /**
1312
+ * Creates a J2K/JP2 compression structure
1313
+ * @param format Coder to select
1314
+ * @return Returns a handle to a compressor if successful, returns NULL otherwise
1315
+ */
1316
+ OPJ_API opj_codec_t* OPJ_CALLCONV opj_create_compress(OPJ_CODEC_FORMAT format);
1317
+
1318
+ /**
1319
+ Set encoding parameters to default values, that means :
1320
+ <ul>
1321
+ <li>Lossless
1322
+ <li>1 tile
1323
+ <li>Size of precinct : 2^15 x 2^15 (means 1 precinct)
1324
+ <li>Size of code-block : 64 x 64
1325
+ <li>Number of resolutions: 6
1326
+ <li>No SOP marker in the codestream
1327
+ <li>No EPH marker in the codestream
1328
+ <li>No sub-sampling in x or y direction
1329
+ <li>No mode switch activated
1330
+ <li>Progression order: LRCP
1331
+ <li>No index file
1332
+ <li>No ROI upshifted
1333
+ <li>No offset of the origin of the image
1334
+ <li>No offset of the origin of the tiles
1335
+ <li>Reversible DWT 5-3
1336
+ </ul>
1337
+ @param parameters Compression parameters
1338
+ */
1339
+ OPJ_API void OPJ_CALLCONV opj_set_default_encoder_parameters(opj_cparameters_t *parameters);
1340
+
1341
+ /**
1342
+ * Setup the encoder parameters using the current image and using user parameters.
1343
+ * @param p_codec Compressor handle
1344
+ * @param parameters Compression parameters
1345
+ * @param image Input filled image
1346
+ */
1347
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_setup_encoder(opj_codec_t *p_codec,
1348
+ opj_cparameters_t *parameters,
1349
+ opj_image_t *image);
1350
+
1351
+ /**
1352
+ * Start to compress the current image.
1353
+ * @param p_codec Compressor handle
1354
+ * @param image Input filled image
1355
+ * @param p_stream Input stgream
1356
+ */
1357
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_start_compress ( opj_codec_t *p_codec,
1358
+ opj_image_t * p_image,
1359
+ opj_stream_t *p_stream);
1360
+
1361
+ /**
1362
+ * End to compress the current image.
1363
+ * @param p_codec Compressor handle
1364
+ * @param p_stream Input stgream
1365
+ */
1366
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_end_compress (opj_codec_t *p_codec,
1367
+ opj_stream_t *p_stream);
1368
+
1369
+ /**
1370
+ * Encode an image into a JPEG-2000 codestream
1371
+ * @param p_codec compressor handle
1372
+ * @param p_stream Output buffer stream
1373
+ *
1374
+ * @return Returns true if successful, returns false otherwise
1375
+ */
1376
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_encode(opj_codec_t *p_codec,
1377
+ opj_stream_t *p_stream);
1378
+ /*
1379
+ ==========================================================
1380
+ codec output functions definitions
1381
+ ==========================================================
1382
+ */
1383
+ /* EXPERIMENTAL FUNCTIONS FOR NOW, USED ONLY IN J2K_DUMP*/
1384
+
1385
+ /**
1386
+ Destroy Codestream information after compression or decompression
1387
+ @param cstr_info Codestream information structure
1388
+ */
1389
+ OPJ_API void OPJ_CALLCONV opj_destroy_cstr_info(opj_codestream_info_v2_t **cstr_info);
1390
+
1391
+
1392
+ /**
1393
+ * Dump the codec information into the output stream
1394
+ *
1395
+ * @param p_codec the jpeg2000 codec.
1396
+ * @param info_flag type of information dump.
1397
+ * @param output_stream output stream where dump the informations get from the codec.
1398
+ *
1399
+ */
1400
+ OPJ_API void OPJ_CALLCONV opj_dump_codec( opj_codec_t *p_codec,
1401
+ OPJ_INT32 info_flag,
1402
+ FILE* output_stream);
1403
+
1404
+ /**
1405
+ * Get the codestream information from the codec
1406
+ *
1407
+ * @param p_codec the jpeg2000 codec.
1408
+ *
1409
+ * @return a pointer to a codestream information structure.
1410
+ *
1411
+ */
1412
+ OPJ_API opj_codestream_info_v2_t* OPJ_CALLCONV opj_get_cstr_info(opj_codec_t *p_codec);
1413
+
1414
+ /**
1415
+ * Get the codestream index from the codec
1416
+ *
1417
+ * @param p_codec the jpeg2000 codec.
1418
+ *
1419
+ * @return a pointer to a codestream index structure.
1420
+ *
1421
+ */
1422
+ OPJ_API opj_codestream_index_t * OPJ_CALLCONV opj_get_cstr_index(opj_codec_t *p_codec);
1423
+
1424
+ OPJ_API void OPJ_CALLCONV opj_destroy_cstr_index(opj_codestream_index_t **p_cstr_index);
1425
+
1426
+
1427
+ /**
1428
+ * Get the JP2 file information from the codec FIXME
1429
+ *
1430
+ * @param p_codec the jpeg2000 codec.
1431
+ *
1432
+ * @return a pointer to a JP2 metadata structure.
1433
+ *
1434
+ */
1435
+ OPJ_API opj_jp2_metadata_t* OPJ_CALLCONV opj_get_jp2_metadata(opj_codec_t *p_codec);
1436
+
1437
+ /**
1438
+ * Get the JP2 file index from the codec FIXME
1439
+ *
1440
+ * @param p_codec the jpeg2000 codec.
1441
+ *
1442
+ * @return a pointer to a JP2 index structure.
1443
+ *
1444
+ */
1445
+ OPJ_API opj_jp2_index_t* OPJ_CALLCONV opj_get_jp2_index(opj_codec_t *p_codec);
1446
+
1447
+
1448
+ /*
1449
+ ==========================================================
1450
+ MCT functions
1451
+ ==========================================================
1452
+ */
1453
+
1454
+ /**
1455
+ * Sets the MCT matrix to use.
1456
+ *
1457
+ * @param parameters the parameters to change.
1458
+ * @param pEncodingMatrix the encoding matrix.
1459
+ * @param p_dc_shift the dc shift coefficients to use.
1460
+ * @param pNbComp the number of components of the image.
1461
+ *
1462
+ * @return true if the parameters could be set.
1463
+ */
1464
+ OPJ_API OPJ_BOOL OPJ_CALLCONV opj_set_MCT( opj_cparameters_t *parameters,
1465
+ OPJ_FLOAT32 * pEncodingMatrix,
1466
+ OPJ_INT32 * p_dc_shift,
1467
+ OPJ_UINT32 pNbComp);
1468
+
1469
+
1470
+
1471
+ #ifdef __cplusplus
1472
+ }
1473
+ #endif
1474
+
1475
+ #endif /* OPENJPEG_H */