PAL emphasis swap for red and green. all PAL PPUs have these swapped.

http://forums.nesdev.com/viewtopic.php?f=3&t=13264
This commit is contained in:
feos-tas 2015-09-19 10:51:25 +00:00
parent 0ed69d8830
commit bb89a6d254
3 changed files with 7 additions and 0 deletions

View File

@ -56,6 +56,7 @@ int palnotch = 64;
bool palhdtv = 0;
bool palmonochrome = 0;
bool palupdate = 1;
bool paldeemphswap = 0;
static int silt;
@ -88,6 +89,8 @@ static void CalculateShift(uint32 *CBM, int *cshiftr, int *cshiftl)
int InitBlitToHigh(int b, uint32 rmask, uint32 gmask, uint32 bmask, int efx, int specfilt, int specfilteropt)
{
paldeemphswap = 0;
// -Video Modes Tag-
if(specfilt == 3) // NTSC 2x
{
@ -187,6 +190,7 @@ int InitBlitToHigh(int b, uint32 rmask, uint32 gmask, uint32 bmask, int efx, int
{
palrgb = (uint32 *)FCEU_dmalloc((256+512)*16*sizeof(uint32));
moire = (float *)FCEU_dmalloc( 16*sizeof(float));
paldeemphswap = 1;
}
silt = specfilt;

View File

@ -786,6 +786,8 @@ static DECLFW(B2000) {
static DECLFW(B2001) {
FCEUPPU_LineUpdate();
if (paldeemphswap)
V = (V&0x9F)|((V&0x40)>>1)|((V&0x20)<<1);
PPUGenLatch = V;
PPU[1] = V;
if (V & 0xE0)

View File

@ -36,6 +36,7 @@ void FFCEUX_PPUWrite_Default(uint32 A, uint8 V);
extern int g_rasterpos;
extern uint8 PPU[4];
extern bool DMC_7bit;
extern bool paldeemphswap;
enum PPUPHASE {
PPUPHASE_VBL, PPUPHASE_BG, PPUPHASE_OBJ