@@ -3268,8 +3268,6 @@ GPUEngineA::GPUEngineA()
32683268 _isLineCaptureNative[3 ][l] = true ;
32693269 }
32703270
3271- _3DFramebufferMain = (Color4u8 *)malloc_alignedPage (GPU_FRAMEBUFFER_NATIVE_WIDTH * GPU_FRAMEBUFFER_NATIVE_HEIGHT * sizeof (Color4u8));
3272- _3DFramebuffer16 = (u16 *)malloc_alignedPage (GPU_FRAMEBUFFER_NATIVE_WIDTH * GPU_FRAMEBUFFER_NATIVE_HEIGHT * sizeof (u16 ));
32733271 _captureWorkingDisplay16 = (u16 *)malloc_alignedPage (GPU_FRAMEBUFFER_NATIVE_WIDTH * sizeof (u16 ));
32743272 _captureWorkingA16 = (u16 *)malloc_alignedPage (GPU_FRAMEBUFFER_NATIVE_WIDTH * sizeof (u16 ));
32753273 _captureWorkingB16 = (u16 *)malloc_alignedPage (GPU_FRAMEBUFFER_NATIVE_WIDTH * sizeof (u16 ));
@@ -3279,8 +3277,6 @@ GPUEngineA::GPUEngineA()
32793277
32803278GPUEngineA::~GPUEngineA ()
32813279{
3282- free_aligned (this ->_3DFramebufferMain );
3283- free_aligned (this ->_3DFramebuffer16 );
32843280 free_aligned (this ->_captureWorkingDisplay16 );
32853281 free_aligned (this ->_captureWorkingA16 );
32863282 free_aligned (this ->_captureWorkingB16 );
@@ -3305,10 +3301,6 @@ void GPUEngineA::Reset()
33053301 this ->GPUEngineBase ::Reset ();
33063302
33073303 const size_t customWidth = this ->_targetDisplay ->GetWidth ();
3308- const size_t customHeight = this ->_targetDisplay ->GetHeight ();
3309-
3310- memset (this ->_3DFramebufferMain , 0 , customWidth * customHeight * sizeof (Color4u8));
3311- memset (this ->_3DFramebuffer16 , 0 , customWidth * customHeight * sizeof (u16 ));
33123304 memset (this ->_captureWorkingDisplay16 , 0 , customWidth * _gpuLargestDstLineCount * sizeof (u16 ));
33133305 memset (this ->_captureWorkingA16 , 0 , customWidth * _gpuLargestDstLineCount * sizeof (u16 ));
33143306 memset (this ->_captureWorkingB16 , 0 , customWidth * _gpuLargestDstLineCount * sizeof (u16 ));
@@ -3399,16 +3391,6 @@ void GPUEngineA::ParseReg_DISPCAPCNT()
33993391 this->_dispCapCnt.srcA, this->_dispCapCnt.srcB);*/
34003392}
34013393
3402- Color4u8* GPUEngineA::Get3DFramebufferMain () const
3403- {
3404- return this ->_3DFramebufferMain ;
3405- }
3406-
3407- u16 * GPUEngineA::Get3DFramebuffer16 () const
3408- {
3409- return this ->_3DFramebuffer16 ;
3410- }
3411-
34123394bool GPUEngineA::IsLineCaptureNative (const size_t blockID, const size_t blockLine)
34133395{
34143396 return this ->_isLineCaptureNative [blockID][blockLine];
@@ -3423,16 +3405,12 @@ void GPUEngineA::AllocateWorkingBuffers(NDSColorFormat requestedColorFormat, siz
34233405{
34243406 this ->GPUEngineBase ::AllocateWorkingBuffers (requestedColorFormat, w, h);
34253407
3426- Color4u8 *old3DFramebufferMain = this ->_3DFramebufferMain ;
3427- u16 *old3DFramebuffer16 = this ->_3DFramebuffer16 ;
34283408 u16 *oldCaptureWorkingDisplay16 = this ->_captureWorkingDisplay16 ;
34293409 u16 *oldCaptureWorkingA16 = this ->_captureWorkingA16 ;
34303410 u16 *oldCaptureWorkingB16 = this ->_captureWorkingB16 ;
34313411 Color4u8 *oldCaptureWorkingA32 = this ->_captureWorkingA32 ;
34323412 Color4u8 *oldCaptureWorkingB32 = this ->_captureWorkingB32 ;
34333413
3434- this ->_3DFramebufferMain = (Color4u8 *)malloc_alignedPage (w * h * sizeof (Color4u8));
3435- this ->_3DFramebuffer16 = (u16 *)malloc_alignedPage (w * h * sizeof (u16 ));
34363414 this ->_captureWorkingDisplay16 = (u16 *)malloc_alignedPage (w * _gpuLargestDstLineCount * sizeof (u16 ));
34373415 this ->_captureWorkingA16 = (u16 *)malloc_alignedPage (w * _gpuLargestDstLineCount * sizeof (u16 ));
34383416 this ->_captureWorkingB16 = (u16 *)malloc_alignedPage (w * _gpuLargestDstLineCount * sizeof (u16 ));
@@ -3456,8 +3434,6 @@ void GPUEngineA::AllocateWorkingBuffers(NDSColorFormat requestedColorFormat, siz
34563434 this ->_VRAMCustomBlockPtr [3 ] = (u16 *)this ->_VRAMCustomBlockPtr [0 ] + (3 * lineInfo.indexCustom * w);
34573435 }
34583436
3459- free_aligned (old3DFramebufferMain);
3460- free_aligned (old3DFramebuffer16);
34613437 free_aligned (oldCaptureWorkingDisplay16);
34623438 free_aligned (oldCaptureWorkingA16);
34633439 free_aligned (oldCaptureWorkingB16);
@@ -5274,7 +5250,6 @@ void GPUSubsystem::_AllocateFramebuffers(NDSColorFormat outputFormat, size_t w,
52745250 this ->_engineMain ->AllocateWorkingBuffers (outputFormat, w, h);
52755251 this ->_engineSub ->AllocateWorkingBuffers (outputFormat, w, h);
52765252
5277- BaseRenderer->SetFramebufferSize (w, h); // Since BaseRenderer is persistent, we need to update this manually.
52785253 if (CurrentRenderer != BaseRenderer)
52795254 {
52805255 CurrentRenderer->RequestColorFormat (outputFormat);
0 commit comments