mirror of
https://github.com/syoyo/tinygltf.git
synced 2026-06-08 03:03:50 +00:00
tests/tester_v3_c_v1port.c mirrors 18 parse/load test cases from tester.cc against the pure-C v3 runtime: parse-error, datauri-in-glb, extension-with-empty-object, extension-overwrite, four bounds-checking cases, glb-invalid-length, integer-out-of-bounds, pbr-khr-texture-transform (verifies KHR_texture_transform scale via tg3_value introspection), image-uri-spaces (single + multiple), empty-skeleton-id, filesize-check, load-issue-416-model, zero-sized-bin-chunk-glb, images-as-is, inverse-bind-matrices-optional, default-material. Header comment lists tester.cc cases skipped because they exercise the v3 writer or v1-internal helpers (out of scope). Wiring max_external_file_size in the parser exposed by the filesize-check port: the option was declared in tg3_parse_options but never enforced. tg3__load_external_file now rejects loaded files larger than the cap with TG3_ERR_FILE_TOO_LARGE and frees the buffer the fs callback returned to avoid a leak. The 134-model verifier and the existing tester_v3_c security regressions still pass. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>