Atari 2600 - expose Display Type in order to have the PAL flag recorded into movies

This commit is contained in:
adelikat 2014-05-23 18:04:31 +00:00
parent 27fa8d9a61
commit 4c0f693e70
1 changed files with 11 additions and 5 deletions

View File

@ -280,15 +280,14 @@ namespace BizHawk.Emulation.Cores.Atari.Atari2600
};
// TODO: add to game db so we only run DetectPal() on unknown games
bool pal;
if (_game["PAL"])
pal = true;
_pal = true;
else if (_game["NTSC"])
pal = false;
_pal = false;
else
pal = DetectPal(_game, Rom);
_pal = DetectPal(_game, Rom);
_tia = new TIA(this, pal);
_tia = new TIA(this, _pal);
_tia.GetFrameRate(out CoreComm.VsyncNum, out CoreComm.VsyncDen);
// dcfilter coefficent is from real observed hardware behavior: a latched "1" will fully decay by ~170 or so tia sound cycles
@ -310,6 +309,13 @@ namespace BizHawk.Emulation.Cores.Atari.Atari2600
_mapper.GetType());
}
private bool _pal;
public DisplayType DisplayType
{
get { return _pal ? DisplayType.PAL : Common.DisplayType.NTSC; }
}
public void HardReset()
{
Ram = new byte[128];