From 8ac9f8a806d579c2c884a5c93bcf1fad96af4e70 Mon Sep 17 00:00:00 2001 From: sin365 <353374337@qq.com> Date: Mon, 31 Mar 2025 11:56:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DGameGear=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Essgee.Unity/Emulation/Video/SegaGGVDP.cs | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/AxibugEmuOnline.Client/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs b/AxibugEmuOnline.Client/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs index 3986fabb..d3b08b0c 100644 --- a/AxibugEmuOnline.Client/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs +++ b/AxibugEmuOnline.Client/Assets/Plugins/Essgee.Unity/Emulation/Video/SegaGGVDP.cs @@ -51,19 +51,11 @@ namespace Essgee.Emulation.Video //GCHandle? lasyRenderHandle; protected override void PrepareRenderScreen() { - //// 固定数组,防止垃圾回收器移动它 - //var bitmapcolorRect_handle = GCHandle.Alloc(outputFramebuffer.Clone() as byte[], GCHandleType.Pinned); - //// 获取数组的指针 - //IntPtr mFrameDataPtr = bitmapcolorRect_handle.AddrOfPinnedObject(); - - var eventArgs = RenderScreenEventArgs.Create(numVisiblePixels, numVisibleScanlines, outputFramebuffer_Ptr); + //var eventArgs = RenderScreenEventArgs.Create(numVisiblePixels, numVisibleScanlines, outputFramebuffer_Ptr); + //这里要改成viewport的中间区域的分辨率 + var eventArgs = RenderScreenEventArgs.Create(Viewport.Width, Viewport.Height, outputFramebuffer_Ptr); OnRenderScreen(eventArgs); eventArgs.Release(); - //if (lasyRenderHandle != null) - // lasyRenderHandle.Value.Free(); - //lasyRenderHandle = bitmapcolorRect_handle; - - //OnRenderScreen(new RenderScreenEventArgs(Viewport.Width, Viewport.Height, outputFramebuffer.Clone() as byte[])); } private bool ModifyAndVerifyCoordinates(ref int x, ref int y)