summaryrefslogtreecommitdiff
path: root/Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp
diff options
context:
space:
mode:
authorsl1nk3.s <sl1nk3.s@gmail.com>2011-03-16 22:48:17 +0000
committersl1nk3.s <sl1nk3.s@gmail.com>2011-03-16 22:48:17 +0000
commit571013acd8a8cb93ef6c57df4189cf1469b0a270 (patch)
tree5ca55fc6040825fa5ae4c7b30ca1f8c710e4f62a /Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp
parentbca4f94b47c13f6ddc9e00f451d32b1cc9cc54fb (diff)
Fix the video software backend. (closes issue 4269)
Some warning fixes and cleanup. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7361 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp')
-rw-r--r--Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp b/Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp
index 50a69a26ea..0091e4eaca 100644
--- a/Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp
+++ b/Source/Plugins/Plugin_VideoSoftware/Src/OpcodeDecoder.cpp
@@ -17,7 +17,7 @@
#include "Common.h"
-#include "../../../Core/VideoCommon/Src/DataReader.h"
+#include "DataReader.h"
#include "OpcodeDecoder.h"
#include "BPMemLoader.h"
@@ -32,20 +32,20 @@
#include "HW/Memmap.h"
typedef void (*DecodingFunction)(u32);
-DecodingFunction currentFunction = NULL;
-
-u32 minCommandSize;
-u16 streamSize;
-u16 streamAddress;
-bool readOpcode;
-SWVertexLoader vertexLoader;
-bool inObjectStream;
-u8 lastPrimCmd;
-
namespace OpcodeDecoder
{
+static DecodingFunction currentFunction = NULL;
+static u32 minCommandSize;
+static u16 streamSize;
+static u16 streamAddress;
+static bool readOpcode;
+static SWVertexLoader vertexLoader;
+static bool inObjectStream;
+static u8 lastPrimCmd;
+
+
void DecodePrimitiveStream(u32 iBufferSize)
{
u32 vertexSize = vertexLoader.GetVertexSize();
@@ -106,7 +106,7 @@ void ExecuteDisplayList(u32 addr, u32 count)
OpcodeDecoder::Run(count);
// if data was read by the opcode decoder then the video data pointer changed
- u32 readCount = g_pVideoData - dlStart;
+ u32 readCount = (u32)(g_pVideoData - dlStart);
dlStart = g_pVideoData;
_assert_msg_(VIDEO, count >= readCount, "Display list underrun");