diff options
author | 2021-06-21 13:53:49 -0700 | |
---|---|---|
committer | 2021-06-21 13:53:49 -0700 | |
commit | 32dbba7d2d4513774b2d877b4c88f2d0760bcf54 (patch) | |
tree | f9e6426cf8dc28413c456bdbcd450c85cb302422 /src/devices/video/voodoo.cpp | |
parent | 5522729235b3ce81c839f3932c1aadc14de59e2b (diff) | |
parent | 2709c0143a8c7009715242c135b28403eeffce8b (diff) |
Merge branch 'master' into deprecateddeprecated
Diffstat (limited to 'src/devices/video/voodoo.cpp')
-rw-r--r-- | src/devices/video/voodoo.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/devices/video/voodoo.cpp b/src/devices/video/voodoo.cpp index 180a8d454c3..2b57e67e3de 100644 --- a/src/devices/video/voodoo.cpp +++ b/src/devices/video/voodoo.cpp @@ -3129,7 +3129,7 @@ int32_t voodoo_device::register_w(voodoo_device *vd, offs_t offset, uint32_t dat attoseconds_t refresh = vd->m_screen->frame_period().attoseconds(); attoseconds_t stdperiod, medperiod, vgaperiod; attoseconds_t stddiff, meddiff, vgadiff; - rectangle visarea; + rectangle visarea; if (vd->vd_type == TYPE_VOODOO_2) { @@ -3151,7 +3151,7 @@ int32_t voodoo_device::register_w(voodoo_device *vd, offs_t offset, uint32_t dat } /* create a new visarea */ - visarea.set(hbp, hbp + hvis - 1, vbp, vbp + vvis - 1); + visarea.set(hbp, hbp + std::max(hvis - 1, 0), vbp, vbp + std::max(vvis - 1, 0)); /* keep within bounds */ visarea.max_x = (std::min)(visarea.max_x, htotal - 1); |