Changes

285 bytes added ,  14:38, 20 December 2020
B doesn't stand for Banner, but for Binary (same all of the other NW4C related file formats).
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]] (Offsets relative to this field)
+
| 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 125: Line 128:  
|}
 
|}
   −
=== 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 ===
Line 196: Line 212:  
| 0x000 || 4 || Count
 
| 0x000 || 4 || Count
 
|-
 
|-
| 0x004 || Count * 8 || [[#Reference|References]]
+
| 0x004 || Count * 8 || [[#Reference|References]] (Offsets relative to Count field)
 
|}
 
|}
  
24

edits