5225225
1774b362d3
x
2021-07-15 18:08:40 +01:00
5225225
f0666aebbf
Fix overflow when calculating strip height for multiple images
2021-05-29 22:52:42 +01:00
5225225
65a1fbe8ae
Test for short JPEG tag
2021-05-29 22:12:35 +01:00
5225225
03b6ed413b
Fix out of bounds subtraction with invalid JPEG table
2021-05-29 22:12:35 +01:00
5225225
5b7814c994
Check for OOM when creating LZWReader
2021-05-29 22:12:35 +01:00
5225225
a15d619471
Fix OOM in Jpeg decoding buffer allocation
2021-05-29 22:12:35 +01:00
HeroicKatora
153ed48ee7
Merge pull request #136 from TomasKralCZ/padding_skip
...
remove padding_buffer
2021-05-29 15:13:20 +02:00
5225225
2bb37a4ecd
Do checked multiplication for samples per strip
2021-05-29 12:37:15 +01:00
5225225
b41ac105ab
Use checked multiplication when calculating buffer size
2021-05-29 12:36:59 +01:00
5225225
1e10b9803b
Add check for an invalid strip count
2021-05-29 12:36:50 +01:00
5225225
2f4e491874
Check for where tag count * tag size overflows
2021-05-28 20:32:30 +01:00
5225225
eda5a8ac30
Fix division by zero issue with malformed file
2021-05-28 14:44:50 +01:00
Tomáš Král
ad0f75222a
remove padding_buffer
2021-05-21 18:06:05 +02:00
HeroicKatora
4df26011d9
Merge pull request #133 from TomasKralCZ/inversion
...
expand_strip() and expand_tile() cleanup
2021-05-18 18:37:25 +02:00
Tomáš Král
4dc7c2a986
add comment in expand_strip()
2021-05-18 18:31:17 +02:00
Tomáš Král
b7c4f668ae
remove redundant subrange and outdated comments
2021-05-16 12:00:15 +02:00
Ingvar Stepanyan
b7e8f210d1
Remove InflateError
...
It was left in but marked as deprecated as part of #132 to avoid breaking API changes.
However, #130 is going to mark a 0.7.0 release, so we can remove it altogether for simplicity.
2021-05-15 21:43:42 +01:00
Tomáš Král
371a9b53c3
fix u64::MAX error on older compilers
2021-05-15 21:31:11 +02:00
Tomáš Král
d0e4f37a28
implement subrange for DecodingBuffer
2021-05-15 21:14:00 +02:00
Tomáš Král
46c7efd836
remove unneeded mutability
2021-05-15 19:55:48 +02:00
Tomáš Král
65832e01bd
Merge branch 'master' into inversion
2021-05-15 19:49:01 +02:00
Tomáš Král
521b58dc07
expand_strip and expand_tile cleanup
2021-05-15 18:12:34 +02:00
Ingvar Stepanyan
a6fb855121
Improve deflate support
...
- Switch to streaming decompression via `flate2`. Aside from performance improvements and lower RAM consumption, this fixes a bug where `max_uncompressed_length` was precalculated for a single tile but then used as a hard limit on the whole data, failing to decompress any tiled images.
- Deprecate `InflateError` - this was used for wrapping `miniz_oxide` raw status, but `flate2` already reports them as `io::Error` instead. This makes errors from both Lzw and Deflate modes more consistent - they're all now just `io::Error`.
- Add support for new `Deflate` tag in addition to `OldDeflate` - format-wise it's same Zlib, and on practice decodes successfully with the same underlying code.
- Slightly simplify partial reads from the `Reader` by using the `std::io::copy` helper instead of doing it manually.
Fixes #131 .
2021-05-08 15:34:14 +01:00
Tomáš Král
d4ce174236
Merge remote-tracking branch 'upstream/master' into tiles
2021-04-14 13:32:56 +02:00
HeroicKatora
a43aa1fbc7
Merge pull request #126 from fintelia/better-decompress
...
Simplify de-compression logic
2021-04-12 18:36:07 +02:00
HeroicKatora
69c34ac33c
Merge pull request #128 from fintelia/simplify-expand3
...
Simplify expand_strip
2021-04-12 18:35:48 +02:00
Tomáš Král
00e0eb9006
incremental tile decoding, refactoring
2021-04-12 15:09:39 +02:00
Tomáš Král
ebd0e266f7
Merge remote-tracking branch 'upstream/master' into tiles
2021-04-12 14:52:38 +02:00
Philipp Oppermann
47dfa0aa3e
Merge branch 'master' into encode-bigtiff
2021-04-12 11:34:41 +02:00
Jonathan Behrens
1eb9c4fab7
fix borrow check issue on rustc 1.34.2
2021-04-10 21:45:04 -04:00
Jonathan Behrens
201b95f749
Improve expand_strip and remove read_{u16, u32, ...}_into
2021-04-10 21:34:57 -04:00
Jonathan Behrens
7641dcbd3f
Refactoring to simplify expand_strip function
2021-04-10 15:02:16 -04:00
Jonathan Behrens
60c6e0cd90
Simplify de-compression logic
2021-04-10 14:49:04 -04:00
Tomáš Král
65a1c553af
TileAttributes doc comments, padding buffer limit check
2021-04-06 20:42:48 +02:00
Tomáš Král
68f2182918
fixed WhiteIsZero processing
2021-04-04 19:34:14 +02:00
Tomáš Král
b2a7e35c85
added basic tiled-based decoding
2021-04-04 18:15:28 +02:00
Kal Conley
5ca2730416
Add SMinSampleValue and SMaxSampleValue tags
2021-04-03 18:45:01 +02:00
HeroicKatora
8fcacc829f
Merge pull request #119 from kalcutter/missing-tags-and-i64
...
Implement missing tag types and signed 64-bit support
2021-03-24 12:25:01 +01:00
Philipp Oppermann
59d0b7389d
Run rustfmt
2021-03-24 11:11:56 +01:00
Philipp Oppermann
0ac444b63f
Improve documentation
2021-03-24 11:10:42 +01:00
Philipp Oppermann
ce1ee6776f
Move TiffValue trait to separate module
2021-03-24 10:47:23 +01:00
Philipp Oppermann
29a020e5ec
Clarify TODO
2021-03-23 14:44:39 +01:00
Philipp Oppermann
9021985477
Provide documentation for TiffKind helper trait
2021-03-23 14:42:05 +01:00
Philipp Oppermann
dc04282290
Fix: Use the correctly parametrized directory and image encoder types
2021-03-23 14:29:45 +01:00
Philipp Oppermann
4cfed1c7b1
Make encoders generic to support BigTiff too
2021-03-23 13:49:54 +01:00
Philipp Oppermann
745ed62808
Change associated const types of TiffValue to usize/u8
...
This allows us to reuse the trait for BigTiff encoding. It also makes things safer for normal Tiff since we properly error on 32 bit overflows now.
2021-03-23 10:56:33 +01:00
Emmanuel Antony
f5754159cb
Modified the validation for ascii tag type
2021-03-20 08:47:47 +05:30
Kal Conley
d086e289dd
Implement missing tag types and signed 64-bit support
2021-03-17 01:24:32 +01:00
Vadim Dyadkin
3de87a7001
Open tif files containing i32 arrays
2021-02-20 18:25:29 +01:00
HagaiHargil
8a8e3ed753
Rustfmt
2020-12-13 12:03:53 +02:00