Commit Graph

28 Commits

Author SHA1 Message Date
DRC
040c688263 Fix an issue that prevented tjEncodeYUV3() and TJCompressor.encodeYUV() from working properly if the source image was very tiny. Basically, jpeg_start_compress() was attempting to write the JPEG headers, which was overrunning the YUV buffer. This patch removes the call to jpeg_start_compress() in tjEncodeYUV3() and replaces it with calls to the individual routines that are necessary to initialize the color converter and downsampler. TJUnitTest has also been modified to test for this condition (the buffer size regression test now works in YUV mode.) 2014-02-11 09:45:18 +00:00
DRC
a7fa97cda5 Extend the TurboJPEG Java API to support compressing JPEG images from YUV planar images 2013-10-31 05:04:51 +00:00
DRC
0fb3247f9a Add CMYK support to the TurboJPEG Java API & clean up a few things in the C API 2013-08-23 04:45:43 +00:00
DRC
45b2cca4c0 Add 4:1:1 subsampling support in the TurboJPEG Java API 2013-08-18 11:04:21 +00:00
DRC
22be928d5a Fix incorrect data output and buffer overruns in the new tjDecompressToYUV2() function whenever scaling is used along with a 4:2:0 JPEG image; extend tjunittest and TJUnitTest to test for these issues. 2013-05-07 21:17:35 +00:00
DRC
6586b254ee Clean up the output of tjunittest and TJUnitTest 2013-05-04 23:41:33 +00:00
DRC
4fcdeb795d Extend the TurboJPEG Java API to support generating YUV images with arbitrary padding and to support image scaling when decompressing to YUV 2013-04-28 01:32:52 +00:00
DRC
aaa5ae742a Code formatting tweaks 2013-04-27 12:38:20 +00:00
DRC
6de1345133 Fix the behavior of the alpha-enabled colorspace constants whenever libjpeg-turbo is built without SIMD support and merged upsampling is used. 2012-03-16 14:30:46 +00:00
DRC
c1e4151607 Added new alpha channel colorspace constants/pixel formats, so applications can specify that they need the unused byte in a 4-component RGB output buffer set to 0xFF when decompressing. 2011-12-19 02:21:03 +00:00
DRC
d345306ecc When decompressing to a 4-byte RGB buffer, set the unused byte to 0xFF so it can be interpreted as an opaque alpha channel. 2011-09-08 23:54:40 +00:00
DRC
869095444e Use random noise to ensure that the JPEG image generated in the buffer size test exceeds the size of the uncompressed source image. 2011-07-12 06:22:06 +00:00
DRC
489864aefa Re-work TJBUFSIZE() to take into account the level of chrominance subsampling 2011-07-12 03:17:23 +00:00
DRC
de8be2e9f0 Re-factor checkBufYUV() function to more closely resemble re-factored checkBuf() function 2011-05-27 02:10:42 +00:00
DRC
c2ddde57c4 Refactor slightly to match new C code 2011-05-23 05:49:08 +00:00
DRC
90a42bb4d2 Slight refactor to put ScalingFactor into its own class (mainly because the $ in the class name was wreaking havoc on the build scripts, but also to add a few convenience methods to it) and to create a separate loader class so we can provide a .jar file with the MinGW distribution that loads the correct DLL 2011-04-02 02:09:03 +00:00
DRC
2139a653b0 Use a different naming convention, to avoid conflict with jpegut 2011-03-31 20:58:03 +00:00
DRC
892ed7e6b4 Clean up compiler warnings 2011-03-31 10:06:17 +00:00
DRC
f90d1d84c7 More Java API cleanup 2011-03-16 00:02:53 +00:00
DRC
22faf366c3 Java code cleanup + Java docs 2011-03-15 20:52:02 +00:00
DRC
696f25e052 Handle 4:4:0 (transposed 4:2:2 subsampling) 2011-03-04 13:04:24 +00:00
DRC
a43dd1aeb7 Print stack trace on error 2011-03-04 09:54:59 +00:00
DRC
e701ed74c0 Use consistent formatting conventions 2011-03-01 20:03:32 +00:00
DRC
be085e08b3 tjGetScaledSize() would never be able to accommodate scaling factors > 1, so replace it with a function that returns a list of fractional scaling factors that TurboJPEG supports. 2011-03-01 09:53:07 +00:00
DRC
407cd22df3 2011-02-28 22:23:37 +00:00
DRC
8755a6805a Implement YUV encode/decode methods at the Java level; Remove some of the arguments from the Java API and replace with get/set methods; General API cleanup; Fix BufferedImage grayscale tests in TJUnitTest 2011-02-25 06:11:03 +00:00
DRC
a311c1cd21 Support for compressing from/decompressing to a BufferedImage in the Java wrapper 2011-02-23 12:09:56 +00:00
DRC
4802041125 More JNI cleanup + added unit test and fixed bugs uncovered by it 2011-02-23 02:20:49 +00:00