summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author hap <happppp@users.noreply.github.com>2020-01-06 13:54:31 +0100
committer hap <happppp@users.noreply.github.com>2020-01-06 13:54:31 +0100
commit974b9339cb4a72f55c4905e05b951457988e93f1 (patch)
tree141f6552aae4a3d593cdddadffc2f4b02059a281
parent26f6a7ca93f3fd89d4f8751101569b0e52f5f401 (diff)
psx refresh rate more decimals (nw)
-rw-r--r--src/devices/video/psx.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/devices/video/psx.cpp b/src/devices/video/psx.cpp
index d6ffca8ade1..e5bcad362d8 100644
--- a/src/devices/video/psx.cpp
+++ b/src/devices/video/psx.cpp
@@ -418,12 +418,12 @@ int psxgpu_device::DebugTextureDisplay( bitmap_rgb32 &bitmap )
void psxgpu_device::updatevisiblearea()
{
rectangle visarea;
- float refresh;
+ double refresh;
if( ( n_gpustatus & ( 1 << 0x14 ) ) != 0 )
{
/* pal */
- refresh = 50;
+ refresh = 50; // TODO: it's not exactly 50Hz
switch( ( n_gpustatus >> 0x13 ) & 1 )
{
case 0:
@@ -437,14 +437,16 @@ void psxgpu_device::updatevisiblearea()
else
{
/* ntsc */
+ // refresh rate derived from 53.693175MHz
+ // TODO: emulate display timings at lower level
switch( ( n_gpustatus >> 0x13 ) & 1 )
{
case 0:
- refresh = 59.82;
+ refresh = 59.8260978565;
n_screenheight = 240;
break;
case 1:
- refresh = 59.94;
+ refresh = 59.9400523286;
n_screenheight = 480;
break;
}