Skip to content

Commit

Permalink
Fix destX calculation in FrameBufferList::renderBuffer()
Browse files Browse the repository at this point in the history
Fixed black boarders size in Banjo-Kazooie.
  • Loading branch information
gonetz committed Sep 7, 2018
1 parent be49e9e commit 15188da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/FrameBuffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1342,8 +1342,8 @@ void FrameBufferList::renderBuffer()
const s32 hEnd = _SHIFTR(*REG.VI_H_START, 0, 10);
const s32 hx1 = max(0, h0 + 640 - hEnd);
//const s32 hx1 = hx0 + rdpRes.vi_hres;
dstX0 = (s32)((hx0 + XoffsetRight) * dstScaleX);
dstX1 = m_overscan.getDrawingWidth() - (s32)((hx1 + Xdivot) * dstScaleX);
dstX0 = (s32)((hx0 * viScaleX + XoffsetRight) * dstScaleX);
dstX1 = m_overscan.getDrawingWidth() - (s32)((hx1 * viScaleX + Xdivot) * dstScaleX);

const f32 srcScaleY = pFilteredBuffer->m_scale;
CachedTexture * pBufferTexture = pFilteredBuffer->m_pTexture;
Expand Down

0 comments on commit 15188da

Please sign in to comment.