Checking in more sound channel volume work
This commit is contained in:
parent
5bcdc96445
commit
39138fa0b5
|
@ -890,7 +890,6 @@ LRESULT FAR PASCAL AppWndProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam)
|
||||||
POINT pt;
|
POINT pt;
|
||||||
RECT file_rect;
|
RECT file_rect;
|
||||||
RECT help_rect;
|
RECT help_rect;
|
||||||
RECT clientrect;
|
|
||||||
int x = 0;
|
int x = 0;
|
||||||
|
|
||||||
switch(msg)
|
switch(msg)
|
||||||
|
|
|
@ -56,7 +56,7 @@ void SexyFilter(int32 *in, int32 *out, int32 count)
|
||||||
mul2=(24<<16)/FSettings.SndRate;
|
mul2=(24<<16)/FSettings.SndRate;
|
||||||
vmul=(FSettings.SoundVolume<<16)*3/4/100;
|
vmul=(FSettings.SoundVolume<<16)*3/4/100;
|
||||||
|
|
||||||
FCEU_DispMessage("SoundVolume %d, vmul %d",FSettings.SoundVolume,vmul);
|
//FCEU_DispMessage("SoundVolume %d, vmul %d",FSettings.SoundVolume,vmul);
|
||||||
if(FSettings.soundq) vmul/=4;
|
if(FSettings.soundq) vmul/=4;
|
||||||
else vmul*=2; /* TODO: Increase volume in low quality sound rendering code itself */
|
else vmul*=2; /* TODO: Increase volume in low quality sound rendering code itself */
|
||||||
|
|
||||||
|
|
|
@ -573,11 +573,11 @@ static INLINE void RDoSQ(int x) //Int x decides if this is Square Wave 1 or 2
|
||||||
amp=EnvUnits[x].Speed;
|
amp=EnvUnits[x].Speed;
|
||||||
else
|
else
|
||||||
amp=EnvUnits[x].decvolume; //Set the volume of the Square Wave
|
amp=EnvUnits[x].decvolume; //Set the volume of the Square Wave
|
||||||
//int32 zzz = amp;
|
|
||||||
//if (x==0) amp<<=128; //Alter sqaurewave volumes here
|
//Modify Square wave volume based on channel volume modifiers
|
||||||
//else amp>>=8;
|
if (x && FSettings.Square2Volume != 150) amp = amp << (FSettings.Square2Volume / 5); //&& FSettings.Sqauare2 added to save processing power if volume is at default
|
||||||
// FCEU_DispMessage("Before = %d After = %d",zzz,amp); //Debug
|
else if (FSettings.Square1Volume != 150) amp = amp << (FSettings.Square1Volume / 5);
|
||||||
// printf("%d\n",amp);
|
|
||||||
amp<<=24;
|
amp<<=24;
|
||||||
|
|
||||||
rthresh=RectDuties[(PSG[(x<<2)]&0xC0)>>6];
|
rthresh=RectDuties[(PSG[(x<<2)]&0xC0)>>6];
|
||||||
|
@ -717,7 +717,7 @@ static void RDoTriangle(void)
|
||||||
{
|
{
|
||||||
uint32 V; //mbg merge 7/17/06 made uitn32
|
uint32 V; //mbg merge 7/17/06 made uitn32
|
||||||
int32 tcout;
|
int32 tcout;
|
||||||
|
if (FSettings.TriangleVolume < 150) return; //On/Off for now
|
||||||
tcout=(tristep&0xF);
|
tcout=(tristep&0xF);
|
||||||
if(!(tristep&0x10)) tcout^=0xF;
|
if(!(tristep&0x10)) tcout^=0xF;
|
||||||
tcout=(tcout*3) << 16; //(tcout<<1);
|
tcout=(tcout*3) << 16; //(tcout<<1);
|
||||||
|
@ -891,6 +891,8 @@ static void RDoNoise(void)
|
||||||
amptab[0]=EnvUnits[2].Speed;
|
amptab[0]=EnvUnits[2].Speed;
|
||||||
else
|
else
|
||||||
amptab[0]=EnvUnits[2].decvolume;
|
amptab[0]=EnvUnits[2].decvolume;
|
||||||
|
//Modfiy Noise channel volume based on channel volume setting
|
||||||
|
if (FSettings.NoiseVolume != 150) amptab[0] = amptab[0] << ((150 - FSettings.NoiseVolume) / 5); //if() to reduce save processing power if volume modifier is the default setting
|
||||||
|
|
||||||
amptab[0]<<=16;
|
amptab[0]<<=16;
|
||||||
amptab[1]=0;
|
amptab[1]=0;
|
||||||
|
|
Loading…
Reference in New Issue