Skip to content

Commit

Permalink
Mix PSG and DMA more pleasingly
Browse files Browse the repository at this point in the history
Final mixing levels to be determined.
  • Loading branch information
frno7 committed Jan 6, 2025
1 parent a4b221b commit dc0d2e4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/psgplay/psgplay.c
Original file line number Diff line number Diff line change
Expand Up @@ -286,14 +286,14 @@ static inline struct psgplay_stereo stereo_mix(struct mixer *m,

return (struct psgplay_stereo) {
/* Simplistic half volume each to PSG and sound. */
.left = m->gain.left * (d.sound.left + s) / 2,
.right = m->gain.right * (d.sound.right + s) / 2
.left = m->gain.left * (2*d.sound.left + 4*s) / (2*4),
.right = m->gain.right * (2*d.sound.right + 4*s) / (2*4)
};
} else
return (struct psgplay_stereo) {
/* Simplistic half volume each to PSG and sound. */
.left = (d.sound.left + s) / 2,
.right = (d.sound.right + s) / 2
.left = (2*d.sound.left + 4*s) / (2*4),
.right = (2*d.sound.right + 4*s) / (2*4)
};
}

Expand Down

0 comments on commit dc0d2e4

Please sign in to comment.