BCWAV: Difference between revisions

Steveice10 (talk | contribs)
mNo edit summary
PabloMK7 (talk | contribs)
B doesn't stand for Banner, but for Binary (same all of the other NW4C related file formats).
 
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[[Category:File formats]]
[[Category:File formats]]
This document is about the format of Banner's CTR Wave files (BCWAV).
This document is about the format of Binary CTR Wave files (BCWAV). The structure is very similar to Microsoft's Wave file.
 
The structure is very similar to Microsoft's Wave file.
 
Banner CWAV total channels must be 2, and the length of the audio in seconds must be 3 seconds or less.


=== Overview ===
=== Overview ===
Line 79: Line 75:
| 0x018 || 4 || Reserved
| 0x018 || 4 || Reserved
|-
|-
| 0x01C || 4 + Count * 8 || [[#Channel Info|Channel Info]] [[#Reference Table|Reference Table]]
| 0x01C || X || [[#Channel Info|Channel Info]] [[#Reference Table|Reference Table]]
|-
| X || X || [[#Channel Info|Channel Info]] Entries
|}
|}


The info block is aligned to 0x20 bytes.
If encoding is DSP ADPCM:
 
{| class="wikitable" border="1"
|-
! OFFSET !! SIZE !!  DESCRIPTION
|-
| X || X || [[#DSP ADPCM Info|DSP ADPCM Info]] Entries
|}


=== Data Block ===
If encoding is IMA ADPCM:


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 90: Line 95:
! OFFSET !! SIZE !!  DESCRIPTION
! OFFSET !! SIZE !!  DESCRIPTION
|-
|-
| 0x000 || 8 || [[#Block Header|Block Header]]
| X || X || [[#IMA ADPCM Info|IMA ADPCM Info]] Entries
|-
| 0x008 || [[#Block Header|Block Header]] Size - 8 || Data
|}
|}


The data block is aligned to 0x20 bytes, as well as the data field's actual sample data.
The info block is aligned to 0x20 bytes.


=== Encoding ===
==== Encoding ====


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 112: Line 115:
|}
|}


=== Channel Info ===
==== Channel Info ====


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 120: Line 123:
| 0x000 || 8 || Samples [[#Reference|Reference]] (Offset relative to [[#Data Block|Data Block]] Data field)
| 0x000 || 8 || Samples [[#Reference|Reference]] (Offset relative to [[#Data Block|Data Block]] Data field)
|-
|-
| 0x008 || 8 || ADPCM Info [[#Reference|Reference]]  (Offset relative to [[#Channel Info|Channel Info]] start)
| 0x008 || 8 || ADPCM Info [[#Reference|Reference]]  (Offset relative to Samples [[#Reference|Reference]] field)
|-
|-
| 0x010 || 4 || Reserved
| 0x010 || 4 || Reserved
|}
|}


=== DSP ADPCM Info ===
===== DSP ADPCM Info =====


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 140: Line 143:
|}
|}


=== DSP ADPCM Param ===
====== DSP ADPCM Param ======


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 149: Line 152:
|}
|}


=== DSP ADPCM Context ===
====== DSP ADPCM Context ======


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 164: Line 167:
|}
|}


=== IMA ADPCM Info ===
===== IMA ADPCM Info =====


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 175: Line 178:
|}
|}


=== IMA ADPCM Context ===
====== IMA ADPCM Context ======


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 187: Line 190:
| 0x003 || 1 || Padding
| 0x003 || 1 || Padding
|}
|}
=== Data Block ===
{| class="wikitable" border="1"
|-
! OFFSET !! SIZE !!  DESCRIPTION
|-
| 0x000 || 8 || [[#Block Header|Block Header]]
|-
| 0x008 || [[#Block Header|Block Header]] Size Value - 8 || Data
|}
The data block is aligned to 0x20 bytes, as well as the data field's actual sample data.


=== Reference Table ===
=== Reference Table ===