jsnes icon indicating copy to clipboard operation
jsnes copied to clipboard

Some minor accuracy fixes pertaining to audio & rendering

Open jimmy-dsi opened this issue 2 years ago • 1 comments

Hello,

I've added some changes to fix a few of the minor emulation inaccuracies I've noticed. Here are the main ones:

  • The functionality of the BG clipping and Sprite clipping now work independently of each other, and the leftmost column now shows the BG color instead of a solid black (except for when TV clipping is enabled).
  • Interpolation has been removed from the triangle channel so that it retains its characteristic "stair-step" wave pattern.
  • Fixed an issue with the rightmost column of the screen not rendering correctly when TV clipping is disabled.
  • All APU channels are now center-panned by default.
  • NTSC palette modified to align more closely with the actual NTSC colors.

I've also added on a few small extra features:

  • In addition to the APU panning table, I've added an APU volume mixer table, plus a table of "channel enable" flags, intended to be enabled/disable by the user via a GUI (and function independently of the register-controlled isEnabled flags).
  • Added an "onFrameStart" callback option to the NES object, which is triggered when the top scanline is rendered as opposed to the bottom scanline like "onFrame".
  • The TV clipping PPU flag has now been split into 2 separate flags for horizontal and vertical clipping. Only vertical is enabled by default.

jimmy-dsi avatar Apr 15 '22 06:04 jimmy-dsi

Thanks! Works great for me. Clipping was so annoying!

viktoras25 avatar Jun 08 '22 18:06 viktoras25