mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
Refactor update of buffer end address.
Add removeIntersections() after end address update.
This commit is contained in:
parent
7d7b5fcee3
commit
fc70172327
|
@ -655,6 +655,13 @@ FrameBuffer * FrameBufferList::findTmpBuffer(u32 _address)
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void FrameBufferList::updateCurrentBufferEndAddress()
|
||||||
|
{
|
||||||
|
if (m_pCurrent == nullptr)
|
||||||
|
return;
|
||||||
|
m_pCurrent->updateEndAddress();
|
||||||
|
removeIntersections();
|
||||||
|
}
|
||||||
|
|
||||||
void FrameBufferList::_createScreenSizeBuffer()
|
void FrameBufferList::_createScreenSizeBuffer()
|
||||||
{
|
{
|
||||||
|
|
|
@ -109,6 +109,7 @@ public:
|
||||||
FrameBuffer * findTmpBuffer(u32 _address);
|
FrameBuffer * findTmpBuffer(u32 _address);
|
||||||
FrameBuffer * getCurrent() const {return m_pCurrent;}
|
FrameBuffer * getCurrent() const {return m_pCurrent;}
|
||||||
void setCurrent(FrameBuffer * _pCurrent) { m_pCurrent = _pCurrent; }
|
void setCurrent(FrameBuffer * _pCurrent) { m_pCurrent = _pCurrent; }
|
||||||
|
void updateCurrentBufferEndAddress();
|
||||||
void renderBuffer();
|
void renderBuffer();
|
||||||
void setBufferChanged(f32 _maxY);
|
void setBufferChanged(f32 _maxY);
|
||||||
void clearBuffersChanged();
|
void clearBuffersChanged();
|
||||||
|
|
|
@ -837,17 +837,15 @@ void gDPFullSync()
|
||||||
|
|
||||||
dwnd().getDrawer().flush();
|
dwnd().getDrawer().flush();
|
||||||
|
|
||||||
FrameBuffer * pCurrentBuffer = frameBufferList().getCurrent();
|
frameBufferList().updateCurrentBufferEndAddress();
|
||||||
if (pCurrentBuffer != nullptr)
|
|
||||||
pCurrentBuffer->updateEndAddress();
|
|
||||||
|
|
||||||
const bool sync = config.frameBufferEmulation.copyToRDRAM == Config::ctSync;
|
FrameBuffer * pCurrentBuffer = frameBufferList().getCurrent();
|
||||||
if ((config.frameBufferEmulation.copyToRDRAM != Config::ctDisable || (config.generalEmulation.hacks & hack_subscreen) != 0) &&
|
if ((config.frameBufferEmulation.copyToRDRAM != Config::ctDisable || (config.generalEmulation.hacks & hack_subscreen) != 0) &&
|
||||||
!FBInfo::fbInfo.isSupported() &&
|
!FBInfo::fbInfo.isSupported() &&
|
||||||
pCurrentBuffer != nullptr &&
|
pCurrentBuffer != nullptr &&
|
||||||
!pCurrentBuffer->isAuxiliary()
|
!pCurrentBuffer->isAuxiliary()
|
||||||
)
|
)
|
||||||
FrameBuffer_CopyToRDRAM(gDP.colorImage.address, sync);
|
FrameBuffer_CopyToRDRAM(gDP.colorImage.address, config.frameBufferEmulation.copyToRDRAM == Config::ctSync);
|
||||||
|
|
||||||
if (RSP.LLE) {
|
if (RSP.LLE) {
|
||||||
if (config.frameBufferEmulation.copyDepthToRDRAM != Config::cdDisable && !FBInfo::fbInfo.isSupported())
|
if (config.frameBufferEmulation.copyDepthToRDRAM != Config::cdDisable && !FBInfo::fbInfo.isSupported())
|
||||||
|
|
Loading…
Reference in New Issue
Block a user