Files
parallel-ps2/tests/cdvd
LibretroAdmin e43530a198 CDVD: the image readers in C89, lending sectors where they lie
The flat, CSO, CHD and gzip readers, the image layer above them and the
ISO API are C89. A sector is lent where the reader holds it - the mapping,
a cached chunk, or a stored CSO frame in the mapping - and copied once,
into the drive's buffer; the drive's fetched sector is kept aside only if
another read comes before its hand-over. The chunk cache keeps eight
chunks, least recently used out, so interleaved streams keep theirs. A
gzip chunk is 2 MiB decoded from the access point before it, not a whole
4 MiB span, and a read that follows the live stream goes on from it with
its input still buffered.

tests/cdvdread is C89 and adds CHD DVD and CD images (chdman), three
interleaved streams, a read between the drive's fetch and its hand-over,
and readSector's modes through CDVDapi_Iso.
2026-10-27 15:18:43 +01:00
..