Play and reverse audio while rewinding.

 - Include the current output level for the noise and triangle channels
   in save states; previously they were wrong right after loading a
   state. Also save the output level and sweep target period for the
   pulse channels instead of trying to be clever.

 - Make sure the output level is updated at the beginning of a frame by
   invalidating any cached output level in apu.cpp (by setting
   'channel_updated' false).

 - Record the length of each frame as it is saved in the rewind buffer.
   This is needed to properly reverse audio as we do not know the length
   of recorded frames in advance.

 - Reverse audio within a frame by inverting deltas and adding them to
   blip_buf in reverse. Work around issues at frame boundaries by
   setting the signal level to zero (see set_audio_signal_level()).
   Thanks to Blargg for help.

 - Treat the reset button as yet another controller button and save its
   state per-frame. This makes rewinding work across resets.