Difference between revisions of "FF7/PSX/Sound/Code Map"

From Final Fantasy Inside
< FF7
Jump to navigation Jump to search
m (Add headings)
m (Unification of terms with other pages etc.)
Line 9: Line 9:
 
|-
 
|-
 
|0x80029818
 
|0x80029818
|void AkaoLoadInstrSet(const void *akaoSampleSet, const void *akaoInstrSet)
+
|void AkaoLoadInstrSet(const void *sampleSet, const void *instrSet)
 
|Load additional instrument set
 
|Load additional instrument set
  
''akaoSampleSet'': corresponding to SOUND/INSTR2.ALL
+
''sampleSet'': corresponding to SOUND/INSTR2.ALL
  
''akaoInstrSet'': corresponding to SOUND/INSTR2.DAT
+
''instrSet'': corresponding to SOUND/INSTR2.DAT
 
|-
 
|-
 
|0x8002988C
 
|0x8002988C
|void AkaoInit(const void *akaoSampleSet, const void *akaoInstrSet)
+
|void AkaoInit(const void *sampleSet, const void *instrSet)
 
|Initialize sound driver and load initial instruments
 
|Initialize sound driver and load initial instruments
  
''akaoSampleSet'': corresponding to SOUND/INSTR.ALL
+
''sampleSet'': corresponding to SOUND/INSTR.ALL
  
''akaoInstrSet'': corresponding to SOUND/INSTR.DAT
+
''instrSet'': corresponding to SOUND/INSTR.DAT
 
|-
 
|-
 
|0x8002DA7C
 
|0x8002DA7C
 
|int AkaoLoadSeq(void)
 
|int AkaoLoadSeq(void)
|Load and start playing new AKAO sequence
+
|Load and start playing new [[FF7/PSX/Sound/AKAO frames|AKAO sequence]]
  
 
Parameters are given from a global structure
 
Parameters are given from a global structure
Line 34: Line 34:
 
|0x80030E7C
 
|0x80030E7C
 
|void _AkaoDispatchVoice(struct MusicPlayerTrack *track, void *a1, int a2)
 
|void _AkaoDispatchVoice(struct MusicPlayerTrack *track, void *a1, int a2)
|Dispatch voice commands until the next note or end of track
+
|Dispatch voice opcodes until the next note or end of track
 
|-
 
|-
 
|0x80036298
 
|0x80036298
Line 45: Line 45:
 
|-
 
|-
 
|0x80049948
 
|0x80049948
|const unsigned char VOICE_COMMAND_LENGTHS[0x60]
+
|const unsigned char VOICE_OPCODE_LENGTHS[0x60]
|Length table for voice commands 0xa0-0xff
+
|Length table for voice opcodes 0xa0-0xff
  
 
0 for end of track and branches
 
0 for end of track and branches
 
|-
 
|-
 
|0x80049AA8
 
|0x80049AA8
|void (* const VOICE_COMMANDS[0x60])(struct MusicPlayerTrack *, void *, int)
+
|void (* const VOICE_OPCODES[0x60])(struct MusicPlayerTrack *, void *, int)
|Address table for voice commands 0xa0-0xff
+
|Address table for voice opcodes 0xa0-0xff
 
|-
 
|-
 
|0x80049C44
 
|0x80049C44

Revision as of 14:15, 8 May 2020

Code Map

Introduces functions, variables and data related to sound, contained in SCUS_941.63 (game program of US version). Note that all symbol names below are for convenience only.

PSX Address Declaration Description
0x80029818 void AkaoLoadInstrSet(const void *sampleSet, const void *instrSet) Load additional instrument set

sampleSet: corresponding to SOUND/INSTR2.ALL

instrSet: corresponding to SOUND/INSTR2.DAT

0x8002988C void AkaoInit(const void *sampleSet, const void *instrSet) Initialize sound driver and load initial instruments

sampleSet: corresponding to SOUND/INSTR.ALL

instrSet: corresponding to SOUND/INSTR.DAT

0x8002DA7C int AkaoLoadSeq(void) Load and start playing new AKAO sequence

Parameters are given from a global structure

Returns: 0 for success, 1 for already loaded, and -1 for invalid signature

0x80030E7C void _AkaoDispatchVoice(struct MusicPlayerTrack *track, void *a1, int a2) Dispatch voice opcodes until the next note or end of track
0x80036298 void SpuInit(void) Initialize SPU (PsyQ library function)
0x8003D0C0 int ResetCallback() Initialize all system callbacks (PsyQ library function)
0x80049948 const unsigned char VOICE_OPCODE_LENGTHS[0x60] Length table for voice opcodes 0xa0-0xff

0 for end of track and branches

0x80049AA8 void (* const VOICE_OPCODES[0x60])(struct MusicPlayerTrack *, void *, int) Address table for voice opcodes 0xa0-0xff
0x80049C44 const unsigned short VOLUME_TABLE_L[256]
0x80049E44 const unsigned short VOLUME_TABLE_R[256]
0x80083580 unsigned char g_AkaoSeqData[] RAM area to load AKAO sequence data

Structures

struct MusicPlayerTrack {
};