mirror of
https://github.com/ekeeke/Genesis-Plus-GX.git
synced 2024-11-10 21:05:12 +01:00
[Gamecube/Wii] fixed random PNG snapshots corruption
This commit is contained in:
parent
83ab969f29
commit
a8d61b0391
@ -196,6 +196,7 @@ Genesis Plus GX 1.7.5 (xx/xx/xxxx) (Eke-Eke)
|
|||||||
* fixed bug with PICO pointer
|
* fixed bug with PICO pointer
|
||||||
* fixed lightgun crosshair & CD leds positionning when using NTSC filter
|
* fixed lightgun crosshair & CD leds positionning when using NTSC filter
|
||||||
* fixed low-pass filter menu setting
|
* fixed low-pass filter menu setting
|
||||||
|
* fixed random PNG snapshots corruption
|
||||||
* various code cleanup & optimizations
|
* various code cleanup & optimizations
|
||||||
* built with devkitPPC r38, libogc 2.2.1 and libfat 1.1.5 with UStealth Mod
|
* built with devkitPPC r38, libogc 2.2.1 and libfat 1.1.5 with UStealth Mod
|
||||||
|
|
||||||
|
@ -1019,22 +1019,19 @@ void gxCopyScreenshot(gx_texture *texture)
|
|||||||
GX_Color4u8(0xff,0xff,0xff,0xff);
|
GX_Color4u8(0xff,0xff,0xff,0xff);
|
||||||
GX_TexCoord2f32(0.0, 0.0);
|
GX_TexCoord2f32(0.0, 0.0);
|
||||||
GX_End();
|
GX_End();
|
||||||
|
GX_DrawDone();
|
||||||
|
|
||||||
/* copy EFB to texture */
|
/* copy EFB to texture */
|
||||||
GX_SetTexCopySrc(0, 0, texture->width * 2, texture->height * 2);
|
GX_SetTexCopySrc(0, 0, texture->width * 2, texture->height * 2);
|
||||||
GX_SetTexCopyDst(texture->width, texture->height, texture->format, GX_TRUE);
|
GX_SetTexCopyDst(texture->width, texture->height, texture->format, GX_TRUE);
|
||||||
GX_DrawDone();
|
|
||||||
GX_CopyTex(texture->data, GX_TRUE);
|
GX_CopyTex(texture->data, GX_TRUE);
|
||||||
GX_Flush();
|
GX_Flush();
|
||||||
|
|
||||||
/* wait for copy operation to finish */
|
/* wait for copy operation to finish */
|
||||||
/* GX_PixModeSync is only useful if GX_ command follows */
|
|
||||||
/* we use dummy GX commands to stall CPU execution */
|
|
||||||
GX_PixModeSync();
|
GX_PixModeSync();
|
||||||
GX_LoadTexObj(&screenTexObj, GX_TEXMAP0);
|
|
||||||
GX_InvalidateTexAll();
|
/* invalidate data cache area corresponding to texture RAM address */
|
||||||
GX_Flush();
|
DCInvalidateRange(texture->data, texture->width * texture->height * 4);
|
||||||
DCStoreRange(texture->data, texture->width * texture->height * 4);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Take Screenshot */
|
/* Take Screenshot */
|
||||||
|
Loading…
Reference in New Issue
Block a user