mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
Some minor changes to VideoCommon, improved SawWave sound, the denied sound in ZWW sounds better (compared it to real HW to be sure).
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3810 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -62,13 +62,13 @@
|
|||||||
#define BPMEM_COPYFILTER1 0x54
|
#define BPMEM_COPYFILTER1 0x54
|
||||||
#define BPMEM_CLEARBBOX1 0x55
|
#define BPMEM_CLEARBBOX1 0x55
|
||||||
#define BPMEM_CLEARBBOX2 0x56
|
#define BPMEM_CLEARBBOX2 0x56
|
||||||
// what about 0x57?
|
#define BPMEM_UNKOWN_57 0x57
|
||||||
#define BPMEM_UNKNOWN 0x58
|
#define BPMEM_UNKNOWN 0x58
|
||||||
#define BPMEM_SCISSOROFFSET 0x59
|
#define BPMEM_SCISSOROFFSET 0x59
|
||||||
#define BPMEM_UNKNOWN1 0x60
|
#define BPMEM_UNKNOWN_60 0x60
|
||||||
#define BPMEM_UNKNOWN2 0x61
|
#define BPMEM_UNKNOWN_61 0x61
|
||||||
#define BPMEM_UNKNOWN3 0x62
|
#define BPMEM_UNKNOWN_62 0x62
|
||||||
#define BPMEM_UNKNOWN4 0x63
|
#define BPMEM_UNKNOWN_63 0x63
|
||||||
#define BPMEM_LOADTLUT0 0x64
|
#define BPMEM_LOADTLUT0 0x64
|
||||||
#define BPMEM_LOADTLUT1 0x65
|
#define BPMEM_LOADTLUT1 0x65
|
||||||
#define BPMEM_TEXINVALIDATE 0x66
|
#define BPMEM_TEXINVALIDATE 0x66
|
||||||
|
@ -379,10 +379,13 @@ void BPWritten(const Bypass& bp)
|
|||||||
PanicAlert("Unknown is not 0xF! val = 0x%08x", bp.newvalue);
|
PanicAlert("Unknown is not 0xF! val = 0x%08x", bp.newvalue);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BPMEM_UNKNOWN1:
|
case BPMEM_UNKOWN_57: // Sunshine uses this: 0xAAA, 0x000, over and over, copy filter related?
|
||||||
case BPMEM_UNKNOWN2:
|
break;
|
||||||
case BPMEM_UNKNOWN3:
|
|
||||||
case BPMEM_UNKNOWN4:
|
case BPMEM_UNKNOWN_60:
|
||||||
|
case BPMEM_UNKNOWN_61:
|
||||||
|
case BPMEM_UNKNOWN_62:
|
||||||
|
case BPMEM_UNKNOWN_63:
|
||||||
// Cases added due to: http://code.google.com/p/dolphin-emu/issues/detail?id=360#c90
|
// Cases added due to: http://code.google.com/p/dolphin-emu/issues/detail?id=360#c90
|
||||||
// Are these related to BBox?
|
// Are these related to BBox?
|
||||||
break;
|
break;
|
||||||
@ -588,7 +591,7 @@ void BPWritten(const Bypass& bp)
|
|||||||
case BPMEM_TEV_ALPHA_ENV+32:
|
case BPMEM_TEV_ALPHA_ENV+32:
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
WARN_LOG(VIDEO, "Unknown Bypass opcode: address = 0x%08x value = 0x%08x", bp.address, bp.newvalue);
|
WARN_LOG(VIDEO, "Unknown BP opcode: address = 0x%08x value = 0x%08x", bp.address, bp.newvalue);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -257,6 +257,7 @@ static void Decode()
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x44:
|
case 0x44:
|
||||||
|
DEBUG_LOG(VIDEO, "GX 0x44: %08x", Cmd);
|
||||||
// zelda 4 swords calls it and checks the metrics registers after that
|
// zelda 4 swords calls it and checks the metrics registers after that
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -15,6 +15,8 @@
|
|||||||
// Official SVN repository and contact information can be found at
|
// Official SVN repository and contact information can be found at
|
||||||
// http://code.google.com/p/dolphin-emu/
|
// http://code.google.com/p/dolphin-emu/
|
||||||
|
|
||||||
|
#include <math.h>
|
||||||
|
|
||||||
#include "../Globals.h"
|
#include "../Globals.h"
|
||||||
#include "UCodes.h"
|
#include "UCodes.h"
|
||||||
#include "UCode_Zelda.h"
|
#include "UCode_Zelda.h"
|
||||||
@ -95,10 +97,11 @@ _lRestart:
|
|||||||
|
|
||||||
void CUCode_Zelda::RenderSynth_SawWave(ZeldaVoicePB &PB, s32* _Buffer, int _Size)
|
void CUCode_Zelda::RenderSynth_SawWave(ZeldaVoicePB &PB, s32* _Buffer, int _Size)
|
||||||
{
|
{
|
||||||
s32 ratio = PB.RatioInt * 2;
|
s32 ratio = (s32)ceil((float)PB.RatioInt / 3);
|
||||||
s64 pos = PB.CurSampleFrac;
|
s64 pos = PB.CurSampleFrac;
|
||||||
|
|
||||||
for (int i = 0; i < 0x50; i++) {
|
for (int i = 0; i < _Size; i++)
|
||||||
|
{
|
||||||
pos += ratio;
|
pos += ratio;
|
||||||
_Buffer[i] = pos & 0xFFFF;
|
_Buffer[i] = pos & 0xFFFF;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user