Cocoa Port: Fix a bug where Metal display view backing textures weren't updating their custom framebuffer sizes. (Regression from commit 4c01e66.)
This commit is contained in:
parent
4c01e66a8a
commit
f2f3680a7c
|
@ -391,8 +391,10 @@
|
||||||
|
|
||||||
_texDisplayPostprocessNative[NDSDisplayID_Main][i] = [device newTextureWithDescriptor:newTexPostprocessNativeDesc];
|
_texDisplayPostprocessNative[NDSDisplayID_Main][i] = [device newTextureWithDescriptor:newTexPostprocessNativeDesc];
|
||||||
_texDisplayPostprocessNative[NDSDisplayID_Touch][i] = [device newTextureWithDescriptor:newTexPostprocessNativeDesc];
|
_texDisplayPostprocessNative[NDSDisplayID_Touch][i] = [device newTextureWithDescriptor:newTexPostprocessNativeDesc];
|
||||||
|
}
|
||||||
|
|
||||||
if ( ([_texDisplayFetchCustom[NDSDisplayID_Main][i] width] != w) ||
|
if ( (_fetchPixelBytes != dispInfo.pixelBytes) ||
|
||||||
|
([_texDisplayFetchCustom[NDSDisplayID_Main][i] width] != w) ||
|
||||||
([_texDisplayFetchCustom[NDSDisplayID_Main][i] height] != h) )
|
([_texDisplayFetchCustom[NDSDisplayID_Main][i] height] != h) )
|
||||||
{
|
{
|
||||||
[_texDisplayFetchCustom[NDSDisplayID_Main][i] release];
|
[_texDisplayFetchCustom[NDSDisplayID_Main][i] release];
|
||||||
|
@ -417,7 +419,6 @@
|
||||||
_texDisplayPostprocessCustom[NDSDisplayID_Touch][i] = [device newTextureWithDescriptor:newTexPostprocessCustomDesc];
|
_texDisplayPostprocessCustom[NDSDisplayID_Touch][i] = [device newTextureWithDescriptor:newTexPostprocessCustomDesc];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
_fetchPixelBytes = dispInfo.pixelBytes;
|
_fetchPixelBytes = dispInfo.pixelBytes;
|
||||||
|
|
||||||
|
@ -675,6 +676,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
id<MTLTexture> targetDestination = _texDisplayFetchNative[displayID][bufferIndex];
|
id<MTLTexture> targetDestination = _texDisplayFetchNative[displayID][bufferIndex];
|
||||||
|
|
||||||
const NDSDisplayInfo ¤tDisplayInfo = GPUFetchObject->GetFetchDisplayInfoForBufferIndex(bufferIndex);
|
const NDSDisplayInfo ¤tDisplayInfo = GPUFetchObject->GetFetchDisplayInfoForBufferIndex(bufferIndex);
|
||||||
|
|
||||||
[targetDestination replaceRegion:MTLRegionMake2D(0, 0, GPU_FRAMEBUFFER_NATIVE_WIDTH, GPU_FRAMEBUFFER_NATIVE_HEIGHT)
|
[targetDestination replaceRegion:MTLRegionMake2D(0, 0, GPU_FRAMEBUFFER_NATIVE_WIDTH, GPU_FRAMEBUFFER_NATIVE_HEIGHT)
|
||||||
|
|
Loading…
Reference in New Issue