mirror of
https://github.com/izzy2lost/dolphin.git
synced 2026-06-19 01:16:48 -07:00
Some preparations for Wii AX (much work remains)
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1101 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@@ -141,8 +141,8 @@ int vectorLength2 = 100; // for console version
|
||||
|
||||
// should we worry about the additonal memory these lists require? bool will allocate
|
||||
// very little memory
|
||||
std::vector< std::vector<bool> > vector1(64, std::vector<bool>(vectorLength,0));
|
||||
std::vector< std::vector<bool> > vector2(64, std::vector<bool>(vectorLength2,0));
|
||||
std::vector< std::vector<bool> > vector1(64, std::vector<bool>(vectorLength, 0));
|
||||
std::vector< std::vector<bool> > vector2(64, std::vector<bool>(vectorLength2, 0));
|
||||
std::vector<int> numberRunning(64);
|
||||
|
||||
|
||||
@@ -301,12 +301,12 @@ void CUCode_AX::Logging(short* _pBuffer, int _iSize, int a)
|
||||
}
|
||||
else
|
||||
{
|
||||
Conditions = (numberRunning.at(i) > 0 || PBs[i].audio_addr.looping);
|
||||
Conditions = numberRunning.at(i) > 0 || PBs[i].audio_addr.looping;
|
||||
}
|
||||
// --------------
|
||||
|
||||
|
||||
if(Conditions)
|
||||
if (Conditions)
|
||||
{
|
||||
// AXPB base
|
||||
gcoef[i] = PBs[i].unknown1;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -20,6 +20,11 @@
|
||||
|
||||
#include "UCode_AXStructs.h"
|
||||
|
||||
enum
|
||||
{
|
||||
NUMBER_OF_PBS = 64
|
||||
};
|
||||
|
||||
class CUCode_AX : public IUCode
|
||||
{
|
||||
public:
|
||||
@@ -34,12 +39,6 @@ public:
|
||||
void Logging(short* _pBuffer, int _iSize, int a);
|
||||
|
||||
private:
|
||||
|
||||
enum
|
||||
{
|
||||
NUMBER_OF_PBS = 64
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
MAIL_AX_ALIST = 0xBABE0000,
|
||||
@@ -64,7 +63,6 @@ private:
|
||||
void SendMail(u32 _uMail);
|
||||
int ReadOutPBs(int a, AXParamBlock *_pPBs, int _num);
|
||||
void WriteBackPBs(AXParamBlock *_pPBs, int _num);
|
||||
s16 ADPCM_Step(AXParamBlock& pb, u32& samplePos, u32 newSamplePos, u16 frac);
|
||||
};
|
||||
|
||||
#endif // _UCODE_AX
|
||||
|
||||
@@ -29,6 +29,17 @@ struct PBMixer
|
||||
u16 unknown4[6];
|
||||
};
|
||||
|
||||
struct PBMixerWii
|
||||
{
|
||||
u16 volume_left;
|
||||
u16 unknown;
|
||||
u16 volume_right;
|
||||
u16 unknown2;
|
||||
|
||||
u16 unknown3[12];
|
||||
u16 unknown4[8];
|
||||
};
|
||||
|
||||
struct PBInitialTimeDelay
|
||||
{
|
||||
u16 on;
|
||||
@@ -51,11 +62,23 @@ struct PBUpdates
|
||||
u16 data_lo;
|
||||
};
|
||||
|
||||
struct PBUnknown
|
||||
struct PBUpdatesWii
|
||||
{
|
||||
u16 num_updates[3];
|
||||
u16 data_hi; // These point to main RAM. Not sure about the structure of the data.
|
||||
u16 data_lo;
|
||||
};
|
||||
|
||||
struct PBDpop
|
||||
{
|
||||
s16 unknown[9];
|
||||
};
|
||||
|
||||
struct PBDpopWii
|
||||
{
|
||||
s16 unknown[12];
|
||||
};
|
||||
|
||||
struct PBVolumeEnvelope
|
||||
{
|
||||
u16 cur_volume;
|
||||
@@ -121,7 +144,7 @@ struct AXParamBlock
|
||||
/* 9 */ PBMixer mixer;
|
||||
/* 27 */ PBInitialTimeDelay initial_time_delay;
|
||||
/* 34 */ PBUpdates updates;
|
||||
/* 41 */ PBUnknown unknown2;
|
||||
/* 41 */ PBDpop dpop;
|
||||
/* 50 */ PBVolumeEnvelope vol_env;
|
||||
/* 52 */ PBUnknown2 unknown3;
|
||||
/* 55 */ PBAudioAddr audio_addr;
|
||||
@@ -131,6 +154,43 @@ struct AXParamBlock
|
||||
/* 93 */ u16 unknown_maybe_padding[3];
|
||||
};
|
||||
|
||||
struct PBLpf
|
||||
{
|
||||
u16 enabled;
|
||||
u16 yn1;
|
||||
u16 a0;
|
||||
u16 b0;
|
||||
};
|
||||
|
||||
struct AXParamBlockWii
|
||||
{
|
||||
u16 next_pb_hi;
|
||||
u16 next_pb_lo;
|
||||
|
||||
u16 this_pb_hi;
|
||||
u16 this_pb_lo;
|
||||
|
||||
u16 src_type; // Type of sample rate converter (none, ?, linear)
|
||||
u16 coef_select;
|
||||
|
||||
u16 mixer_control;
|
||||
u16 running; // 1=RUN 0=STOP
|
||||
u16 is_stream; // 1 = stream, 0 = one shot
|
||||
|
||||
PBMixerWii mixer;
|
||||
PBInitialTimeDelay initial_time_delay;
|
||||
PBUpdatesWii updates;
|
||||
PBDpopWii dpop;
|
||||
PBVolumeEnvelope vol_env;
|
||||
PBUnknown2 unknown3;
|
||||
PBAudioAddr audio_addr;
|
||||
PBADPCMInfo adpcm;
|
||||
PBSampleRateConverter src;
|
||||
PBADPCMLoopInfo adpcm_loop_info;
|
||||
PBLpf lpf;
|
||||
u16 pad[22];
|
||||
};
|
||||
|
||||
enum {
|
||||
AUDIOFORMAT_ADPCM = 0,
|
||||
AUDIOFORMAT_PCM8 = 0x19,
|
||||
|
||||
Reference in New Issue
Block a user