Skip to content

Commit

Permalink
PCE: Fixed noise period when frequency register is set to 0x1F
Browse files Browse the repository at this point in the history
Fixes noise issues in some games (Cyber Cross, Eternal City, Victory Run, etc.)
  • Loading branch information
SourMesen committed Sep 5, 2024
1 parent e24eecd commit 816e77e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Core/PCE/PcePsgChannel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ void PcePsgChannel::SetOutputOffset(uint8_t offset)
uint32_t PcePsgChannel::GetNoisePeriod()
{
if(_state.NoiseFrequency == 0x1F) {
return (0x1F + 1) * 64;
return 32;
} else {
return ((~_state.NoiseFrequency) & 0x1F) * 64;
}
Expand Down

0 comments on commit 816e77e

Please sign in to comment.