mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
Correct FrameBufferList::removeBuffers : remove all buffers with given width.
Fixed issue with Pokemon Stadium, which set zero VI height before interlace mode switch.
This commit is contained in:
parent
3ac4f2ddb1
commit
4ff13a30e6
|
@ -422,11 +422,11 @@ void FrameBufferList::removeBuffer(u32 _address )
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void FrameBufferList::removeBuffers(u32 _width, u32 _height)
|
void FrameBufferList::removeBuffers(u32 _width)
|
||||||
{
|
{
|
||||||
m_pCurrent = NULL;
|
m_pCurrent = NULL;
|
||||||
for (FrameBuffers::iterator iter = m_list.begin(); iter != m_list.end(); ++iter) {
|
for (FrameBuffers::iterator iter = m_list.begin(); iter != m_list.end(); ++iter) {
|
||||||
while (iter->m_width == _width && iter->m_height == _height) {
|
while (iter->m_width == _width) {
|
||||||
iter = m_list.erase(iter);
|
iter = m_list.erase(iter);
|
||||||
if (iter == m_list.end())
|
if (iter == m_list.end())
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -50,7 +50,7 @@ public:
|
||||||
void destroy();
|
void destroy();
|
||||||
void saveBuffer(u32 _address, u16 _format, u16 _size, u16 _width, u16 _height, bool _cfb);
|
void saveBuffer(u32 _address, u16 _format, u16 _size, u16 _width, u16 _height, bool _cfb);
|
||||||
void removeBuffer(u32 _address);
|
void removeBuffer(u32 _address);
|
||||||
void removeBuffers(u32 _width, u32 _height);
|
void removeBuffers(u32 _width);
|
||||||
void attachDepthBuffer();
|
void attachDepthBuffer();
|
||||||
FrameBuffer * findBuffer(u32 _startAddress);
|
FrameBuffer * findBuffer(u32 _startAddress);
|
||||||
FrameBuffer * findTmpBuffer(u32 _address);
|
FrameBuffer * findTmpBuffer(u32 _address);
|
||||||
|
|
4
VI.cpp
4
VI.cpp
|
@ -67,8 +67,8 @@ void VI_UpdateSize()
|
||||||
// const int divot = ((*REG.VI_STATUS) >> 4) & 1;
|
// const int divot = ((*REG.VI_STATUS) >> 4) & 1;
|
||||||
|
|
||||||
if (config.frameBufferEmulation.enable && (interlacedPrev != VI.interlaced || widthPrev != VI.width || heightPrev != VI.height)) {
|
if (config.frameBufferEmulation.enable && (interlacedPrev != VI.interlaced || widthPrev != VI.width || heightPrev != VI.height)) {
|
||||||
frameBufferList().removeBuffers(widthPrev, heightPrev);
|
frameBufferList().removeBuffers(widthPrev);
|
||||||
frameBufferList().removeBuffers(VI.width, VI.height);
|
frameBufferList().removeBuffers(VI.width);
|
||||||
depthBufferList().destroy();
|
depthBufferList().destroy();
|
||||||
depthBufferList().init();
|
depthBufferList().init();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user