summaryrefslogtreecommitdiff
path: root/plugins/peopsxgl/soft.c
diff options
context:
space:
mode:
authorSND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-08-18 01:34:01 +0000
committerSND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-08-18 01:34:01 +0000
commitc4f5208806fe4136b19cce9f63f03820fc49d0cf (patch)
treec1f42770d9fc0f88538993f0fb4cc78c364c056e /plugins/peopsxgl/soft.c
parentc4a77870fcb7793bd5a7611b9994a5b15a335a3c (diff)
downloadpcsxr-c4f5208806fe4136b19cce9f63f03820fc49d0cf.tar.gz
peopsxgl: Readded windows support.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@56180 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'plugins/peopsxgl/soft.c')
-rw-r--r--plugins/peopsxgl/soft.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/plugins/peopsxgl/soft.c b/plugins/peopsxgl/soft.c
index bae51708..9f10a2a0 100644
--- a/plugins/peopsxgl/soft.c
+++ b/plugins/peopsxgl/soft.c
@@ -1188,6 +1188,26 @@ static int left_R, delta_left_R, right_R, delta_right_R;
static int left_G, delta_left_G, right_G, delta_right_G;
static int left_B, delta_left_B, right_B, delta_right_B;
+#ifdef _MSC_VER
+
+#pragma warning (disable : 4035)
+
+__inline int shl10idiv(int x, int y)
+{
+ __asm
+ {
+ mov eax,x
+ mov ebx,y
+ mov edx, eax
+ shl eax, 10
+ sar edx, 22
+ idiv ebx
+ // return result in eax
+ }
+}
+
+#else
+
__inline int shl10idiv(int x, int y)
{
long long int bi=x;
@@ -1195,6 +1215,8 @@ __inline int shl10idiv(int x, int y)
return bi/y;
}
+#endif
+
__inline int RightSection_F(void)
{
soft_vertex * v1 = right_array[ right_section ];