Add VRC6 support

2 Pulse channels:
- 8 level pulse duty cycle, DAC mode(just ignores duty cycle)/pulse wave mode, 4 bit volume.
- Furnace support PCM playback in pulse channels with duty cycle ignore mode.

Sawtooth:
- nothing but 6 bit volume (8 bit accumulator in technically) and 12 bit frequency (periodic).

VRC6 instrument:
- 6 bit Volume macro for finer sawtooth volume handling, also 3 bit Duty cycle macro for pulse channels.

Duty, PCM mode command and Duty macro affects for pulse channel only.
This commit is contained in:
cam900 2022-03-28 01:06:56 +09:00
parent 09b5dd556e
commit ef104ce0b0
17 changed files with 1228 additions and 3 deletions

View file

@ -48,6 +48,7 @@
#include "platform/bubsyswsg.h"
#include "platform/pet.h"
#include "platform/vic20.h"
#include "platform/vrc6.h"
#include "platform/dummy.h"
#include "../ta-log.h"
#include "song.h"
@ -283,6 +284,9 @@ void DivDispatchContainer::init(DivSystem sys, DivEngine* eng, int chanCount, do
case DIV_SYSTEM_VIC20:
dispatch=new DivPlatformVIC20;
break;
case DIV_SYSTEM_VRC6:
dispatch=new DivPlatformVRC6;
break;
default:
logW("this system is not supported yet! using dummy platform.\n");
dispatch=new DivPlatformDummy;