Commit Graph
2444 Commits
Author SHA1 Message Date
Dylan M. Taylor 543e5d4983 Validate GIF frame length before copying 2026-11-14 00:34:24 +00:00
Dylan M. Taylor 387c64892b Merge pull request #1219 from dylanmtaylor/codex/csv-strict-utf8
Add strict UTF-8 decoding for delimited text
2026-11-13 19:14:46 -05:00
Dylan M. Taylor d61671b6de Preserve JPEG XL metadata and associated alpha 2026-11-13 23:47:44 +00:00
Dylan M. Taylor 46cb7eeaf0 fix(xfl): validate archive record boundaries 2026-11-13 23:41:15 +00:00
Dylan M. Taylor d5e9fd7a49 Preserve GIF writer default disposal 2026-11-13 23:37:55 +00:00
Dylan M. Taylor 7bb6c90076 Merge pull request #1228 from storytold/codex/craft-dwg-extraction
Add shared DWG-DXF byte bridge
2026-11-13 18:35:13 -05:00
Dylan M. Taylor 2b9a325f57 Merge pull request #1224 from storytold/codex/xlsx-orphan-shared-strings
Preserve XLSX shared strings without a relationship
2026-11-13 18:34:55 -05:00
Dylan M. Taylor 6eac66c1fe Merge remote-tracking branch 'origin/main' into codex/eps-postscript-vm 2026-11-13 23:20:31 +00:00
Dylan M. Taylor 4d322fc5a4 Merge pull request #1218 from dylanmtaylor/codex/eps-postscript-api
Add reusable PostScript EPS scanner
2026-11-13 18:18:50 -05:00
Dylan M. Taylor ade25d64eb Expose structured JPEG XL pixel limits 2026-11-13 23:13:26 +00:00
Dylan M. Taylor 8fcb191515 Preserve JPEG XL color rendering options 2026-11-13 23:06:05 +00:00
Dylan M. Taylor 85d63a6fdb Merge remote-tracking branch 'origin/main' into codex/anicraft-xfl-format 2026-11-13 23:01:29 +00:00
Dylan M. Taylor 86621fbab3 Keep GIF render batches palette-quantized 2026-11-13 22:49:33 +00:00
Dylan M. Taylor 9405f3652b Merge remote-tracking branch 'origin/main' into codex/craft-jxl-extraction 2026-11-13 22:47:47 +00:00
Dylan M. Taylor 4d3e920954 Add shared JPEG XL decoder and encoder 2026-11-13 22:47:47 +00:00
Dylan M. Taylor 888bffcbb3 Add shared DWG-DXF byte bridge 2026-11-13 22:45:07 +00:00
Dylan M. Taylor 92afe40396 Format XFL reader diagnostic test 2026-11-13 22:33:13 +00:00
Dylan M. Taylor 389aef0fda Use neutral errors in shared XFL reader 2026-11-13 22:27:35 +00:00
Dylan M. Taylor f399135165 Merge remote-tracking branch 'origin/main' into codex/gif-animation-writer 2026-11-13 22:22:08 +00:00
Bra1nZ ef03e1b1df fix(print): trust one side of a legacy V3 driver's paper metric
Legacy V3 GDI drivers (HP LaserJet P1102) keep the paper metric in their
DEVMODE extension and report MediaSizeWidth = 0 while the height is right,
so verify_ticket refused with "a paper without a size (a roll?)" and
nothing was sent (storytold/craft-libs#7230).

verify_ticket now fails closed only when neither side is known or the
request itself names no sheet; otherwise it goes on with the requested
size, but only while the side the driver did report agrees with the
request to a quarter of a millimetre. matching_paper gains a partial
record as a candidate of last resort, and driver_ticket takes the wanted
size from the sheet the job asked for, not from the zero record.
The fallback is logged; log moves to the common dependencies so the
warning compiles on Windows too (caught by the windows-gnu check).
2026-11-14 01:19:29 +03:00
Dylan M. Taylor 68b8171b0d Merge pull request #1215 from dylanmtaylor/codex/lightcraft-gif-frame-decode
gif: bound frame decoding and expose ICC metadata
2026-11-13 17:18:28 -05:00
Dylan M. Taylor a9080bf1fd Merge remote-tracking branch 'origin/main' into codex/eps-postscript-api 2026-11-13 22:16:25 +00:00
Dylan M. Taylor 2fea4b4ce2 Merge pull request #1217 from dylanmtaylor/codex/eps-embedded-font-fix
Fix EPS embedded font token scanning
2026-11-13 17:15:50 -05:00
Dylan M. Taylor 6d0b33c0cd Read conventional XLSX shared strings without a relationship 2026-11-13 22:11:05 +00:00
Dylan M. Taylor 6159ef9c39 Bound streaming GIF writer lifecycle 2026-11-13 22:09:54 +00:00
Dylan M. Taylor 8b8603c6e7 Support streaming animated GIF output 2026-11-13 22:08:57 +00:00
Dylan M. Taylor b4d1e249d9 Add bounded XFL FLA package reader 2026-11-13 22:05:11 +00:00
Dylan M. Taylor 2b4f6b4f87 Add shared animated GIF writer 2026-11-13 22:05:00 +00:00
Dylan M. Taylor d62c51645e Add bounded PostScript VM primitives 2026-11-13 21:59:03 +00:00
dotCooCoo 8a2c27ee2d craft-hdr: refuse buffers past isize::MAX bytes when limits are raised
With a raised max_pixels on wasm32, a picture could pass every check and
then ask vec! for more than isize::MAX bytes for its scan line or its
float picture, which panics with a capacity overflow instead of returning
an error.

- decode checks the byte count of the scan line and of the float picture
  against isize::MAX before allocating either, and returns
  LimitExceeded("pixel count") when one is over.
- Each header line is measured as text after invalid bytes become U+FFFD,
  and a line over isize::MAX bytes is LimitExceeded("header length").
- The resolution line reads its first four tokens without collecting the
  rest.
- The size checks take the bound as a value, and tests check them against
  the 32-bit bound without allocating.
2026-11-13 13:43:35 -08:00
Dylan M. Taylor 69e457a8eb Add strict UTF-8 text decoder 2026-11-13 21:38:11 +00:00
Dylan M. Taylor ab51daff1a Respect PostScript delimiters after literal names 2026-11-13 21:29:53 +00:00
dotCooCoo 261e7a4c5c craft-texture: keep image planes within isize::MAX bytes when limits are raised
With raised Limits, a gray image over 512 MiB could be converted to
color on wasm32, where the color plane needs more than isize::MAX bytes
and vec! panics with capacity overflow.

- Limits::check returns TooLarge when the byte count is over isize::MAX,
  so the try_ forms report the size instead of OutOfMemory.
- map, to_color and to_kind clamp each side to 1..=MAX_SIDE when the
  result would be over isize::MAX bytes, and map the top-left part.
- The size checks are pure functions that take the bound as a value, and
  three tests check them against the 32-bit bound without allocating.
2026-11-13 13:28:35 -08:00
Dylan M. Taylor 74337e8fc5 fix(gif): report frame cap after merging 2026-11-13 21:27:44 +00:00
Dylan M. Taylor 4cc86fc7cf Add reusable PostScript EPS scanner 2026-11-13 21:21:47 +00:00
Dylan M. Taylor 24a011ae59 Fix lexical EPS embedded font scanning 2026-11-13 21:17:24 +00:00
dotCooCoo 3c3a83151d craft-texture: add bounded float image planes and texture sampling
Adds crates/texture (craft-texture), the first step of RFC-0032
(storytold/craft-contrib#50). The code comes from MaterialCraft
crates/image/src/lib.rs at 31330629, with its six tests unchanged. No app
uses the crate yet.

Changes from the source:
- Image fields are private; from_data checks the size and the buffer
  length, so a zero side can no longer reach a panic and a short buffer
  is rejected instead of read with defaults.
- Limits caps the side, pixels and bytes; the try_ constructors and
  try_map, try_to_kind, try_resize and try_to_rgba8_display reserve
  memory first and return an error.
- Repeat sampling reduces the coordinate to its fractional part, so the
  period holds at large coordinates.
- Bilinear sampling sums the four weighted texels and skips zero weights;
  box shrinking sums in f64.
- generate_uv clamps the size before computing pixel centers.
- linear_to_srgb(NaN) returns NaN.
- rayon is behind the parallel feature.
2026-11-13 13:14:55 -08:00
Dylan M. Taylor 830e897714 Merge craft-libs main after GIF limits 2026-11-13 21:09:43 +00:00
Dylan M. Taylor b5b8a7750d Merge pull request #1192 from dylanmtaylor/codex/effectcraft-shared-format-cutover
fix: bound GIF allocations and clarify WebP canvas limits
2026-11-13 16:06:01 -05:00
Dylan M. Taylor 61cfc7f3d1 Merge pull request #1212 from storytold/codex/craft-eps-fontscan
Extract embedded PostScript font scanning to craft-eps
2026-11-13 16:05:35 -05:00
Dylan M. Taylor acfcaa1b0e Merge pull request #1209 from storytold/fix/csv-delimiter-quote-boundaries
fix(csv): preserve quoted delimiter coherence
2026-11-13 15:51:25 -05:00
Dylan M. Taylor 669d62e755 docs(gif): clarify combined allocation budget 2026-11-13 20:36:02 +00:00
Dylan M. Taylor dd21ee372d Merge remote-tracking branch 'origin/main' into codex/effectcraft-gif-review-fix 2026-11-13 20:11:02 +00:00
Dylan M. Taylor 142102fc94 Merge remote-tracking branch 'origin/main' into codex/craft-eps-fontscan 2026-11-13 20:02:18 +00:00
Dylan M. Taylor ededdd75c9 gif: expose first-frame data byte count 2026-11-13 19:51:49 +00:00
Dylan M. Taylor 0b73ba5337 Clarify GIF decoder combined allocation budget 2026-11-13 19:43:38 +00:00
Dylan M. Taylor 415dc3204c fix(csv): preserve bounded delimiter sampling 2026-11-13 19:25:10 +00:00
Dylan M. Taylor 3c51d88330 gif: stop at requested frame limit 2026-11-13 19:20:05 +00:00
Dylan M. Taylor aefb34b3c2 Merge remote-tracking branch 'origin/main' into codex/lightcraft-gif-frame-decode 2026-11-13 19:16:53 +00:00
Dylan M. Taylor a8b889fe2a gif: expose bounded first-frame pixel coverage and ICC metadata 2026-11-13 19:16:25 +00:00