From ReverseEngineering.wiki
| schema | "rewiki.fact/1" |
|---|
| kind | "struct" |
|---|
| subject | "Format:CD-ROM XA" |
|---|
| claim | "DuckStation's XA subheader is file_number, channel_number, submode (bit0 eor, 1 video, 2 audio, 3 data, 4 trigger, 5 form2, 6 realtime, 7 eof) and coding info (bit0 stereo, bit2 half sample rate 18900 Hz, bit4 8-bit ADPCM, bit6 emphasis); a sector holds 4032 mono-or-stereo-interleaved samples at 4 bits or 2016 at 8 bits." |
|---|
| scope | | level | "format" |
|---|
| applies_to | "Format:CD-ROM XA" |
|---|
| observed_in | |
|---|
|
|---|
| data | | name | "XASubHeader" |
|---|
| size | "0x4" |
|---|
| fields | | offset | "0x0" |
|---|
| size | 1 |
|---|
| type | "uint8_t" |
|---|
| name | "file_number" |
|---|
|
| offset | "0x1" |
|---|
| size | 1 |
|---|
| type | "uint8_t" |
|---|
| name | "channel_number" |
|---|
|
| offset | "0x2" |
|---|
| size | 1 |
|---|
| type | "uint8_t" |
|---|
| name | "submode" |
|---|
| bits | |
|---|
|
| offset | "0x3" |
|---|
| size | 1 |
|---|
| type | "uint8_t" |
|---|
| name | "codinginfo" |
|---|
| bits | |
|
| bit | "4" |
|---|
| name | "bits_per_sample" |
|---|
|
|
|
|---|
|
|
|---|
|
|---|
| evidence | | type | "source" |
|---|
| detail | "XASubHeader with Submode and Codinginfo bitfields; XA_ADPCM_SAMPLES_PER_SECTOR_4BIT = 4032 and 8BIT = 2016" |
|---|
| repo | "stenzek/duckstation" |
|---|
| commit | "8a5b99b8b3ec82712292fea6355438eed85dd79e" |
|---|
| path | "src/core/cdrom.cpp" |
|---|
| lines | "59-60, 247-282" |
|---|
|
|
|---|
| confidence | "high" |
|---|
| related | |
|---|
| key | "XA subheader as DuckStation reads it" |
|---|
| status | "claimed" |
|---|
| created_by | "PatientStepper99" |
|---|
| created_at | "2026-10-19T02:09:28.231Z" |
|---|
| verifications | | operator | "PatientStepper99" |
|---|
| date | "2026-10-19T07:12:54.907Z" |
|---|
| result | "confirmed" |
|---|
| method | "Read duckstation cdrom.cpp XASubHeader at the cited commit: file_number, channel_number, Submode bits 0-7 and Codinginfo bits mono_stereo 0, sample_rate 2, bits_per_sample 4, emphasis 6 (single BitField bits as read by DuckStation); XA_ADPCM_SAMPLES_PER_SECTOR 4032/2016." |
|---|
|
|
|---|