libretro: Final fix for 32-bit framebuffer alignment issues (hopefully).

This commit is contained in:
Stephen Anthony 2019-08-03 19:22:33 -02:30
parent 0135c873a4
commit 4d75dcb462
2 changed files with 5 additions and 2 deletions

View File

@ -18,6 +18,8 @@
#include "bspf.hxx"
#include "OSystem.hxx"
#include "AtariNTSC.hxx"
#include "TIAConstants.hxx"
#include "FBSurfaceLIBRETRO.hxx"
#include "FrameBufferLIBRETRO.hxx"
@ -47,7 +49,8 @@ unique_ptr<FBSurface>
unique_ptr<FBSurface> ptr = make_unique<FBSurfaceLIBRETRO>
(const_cast<FrameBufferLIBRETRO&>(*this), w, h, data);
if(w == 565 && h == 320)
if(w == AtariNTSC::outWidth(TIAConstants::frameBufferWidth) &&
h == TIAConstants::frameBufferHeight)
{
uInt32 pitch;
ptr.get()->basePtr(myRenderSurface, pitch);

View File

@ -450,7 +450,7 @@ void retro_get_system_av_info(struct retro_system_av_info *info)
info->geometry.base_width = stella.getRenderWidth() - crop_left * (stella.getVideoZoom() == 1 ? 2 : 1);
info->geometry.base_height = stella.getRenderHeight();
info->geometry.max_width = ((stella.getVideoWidthMax() + 3) / 4) * 4;
info->geometry.max_width = stella.getVideoWidthMax();
info->geometry.max_height = stella.getVideoHeightMax();
info->geometry.aspect_ratio = stella.getVideoAspectPar() * (float) info->geometry.base_width / (float) info->geometry.base_height;