mirror of
https://github.com/transistorfet/moa.git
synced 2024-11-21 19:30:52 +00:00
Fixed the biasing of DAC data in ym2612
It was using the DAC value as a positive offset, which makes a slight click at the start and end of the SEGA voice at the start of a game. now subtracts half the value and amplifies it a bit so that it crosses the 0 value
This commit is contained in:
parent
0876d85626
commit
d58bae77ea
@ -272,7 +272,7 @@ impl Steppable for Ym2612 {
|
||||
|
||||
if self.dac_enabled {
|
||||
if let Some(data) = self.dac.pop_front() {
|
||||
sample += data as f32 / 255.0;
|
||||
sample += ((data as f32 - 128.0) / 255.0) * 2.0;
|
||||
}
|
||||
} else if self.channels[6].on != 0 {
|
||||
sample += self.channels[6].get_sample();
|
||||
|
Loading…
Reference in New Issue
Block a user