summaryrefslogtreecommitdiff
path: root/Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp')
-rw-r--r--Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp b/Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp
index 6722ec7935..77d87988c8 100644
--- a/Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp
+++ b/Source/Plugins/Plugin_VideoSoftware/Src/EfbInterface.cpp
@@ -28,6 +28,7 @@ u8 efb[EFB_WIDTH*EFB_HEIGHT*6];
namespace EfbInterface
{
+
u8 efbColorTexture[EFB_WIDTH*EFB_HEIGHT*4];
inline u32 GetColorOffset(u16 x, u16 y)
@@ -40,6 +41,12 @@ namespace EfbInterface
return (x + y * EFB_WIDTH) * 3 + DEPTH_BUFFER_START;
}
+ void DoState(PointerWrap &p)
+ {
+ p.DoArray(efb, EFB_WIDTH*EFB_HEIGHT*6);
+ p.DoArray(efbColorTexture, EFB_WIDTH*EFB_HEIGHT*4);
+ }
+
void SetPixelAlphaOnly(u32 offset, u8 a)
{
switch (bpmem.zcontrol.pixel_format)
@@ -454,10 +461,11 @@ namespace EfbInterface
SetPixelAlphaOnly(offset, color[ALP_C]);
}
- void SetDepth(u16 x, u16 y, u32 depth)
- {
- SetPixelDepth(GetDepthOffset(x, y), depth);
- }
+ void SetDepth(u16 x, u16 y, u32 depth)
+ {
+ if (bpmem.zmode.updateenable)
+ SetPixelDepth(GetDepthOffset(x, y), depth);
+ }
void GetColor(u16 x, u16 y, u8 *color)
{