diff --git a/plugins/zerospu2/zerospu2.h b/plugins/zerospu2/zerospu2.h index c34e4a94a8..b70fe29f66 100644 --- a/plugins/zerospu2/zerospu2.h +++ b/plugins/zerospu2/zerospu2.h @@ -178,7 +178,7 @@ static __forceinline u16 c_offset(u32 ch) return channel_test(ch) ? 0x0 : 0x400; } -static __forceinline tSPU_ATTR spu2attr(u32 channel) +static __forceinline tSPU_ATTR &spu2attr(u32 channel) { return channel_test(channel) ? spu2attr0 : spu2attr1; } diff --git a/plugins/zzogl-pg/opengl/ZZoglDrawing.cpp b/plugins/zzogl-pg/opengl/ZZoglDrawing.cpp index 8123d8a357..dacabc149b 100644 --- a/plugins/zzogl-pg/opengl/ZZoglDrawing.cpp +++ b/plugins/zzogl-pg/opengl/ZZoglDrawing.cpp @@ -41,13 +41,14 @@ void Prim() curvb.SetCurrentPrim(); } +// Replaced by a macro -> see ZZoglDrawing.h // return true if triangle SHOULD be painted. // Hackish and should be replaced. -bool __forceinline NoHighlights(int i) -{ - //Old code - return (!(conf.settings().xenosaga_spec) || !vb[i].zbuf.zmsk || prim->iip) ; -} +// bool __forceinline NoHighlights(int i) +// { +// //Old code +// return (!(conf.settings().xenosaga_spec) || !vb[i].zbuf.zmsk || prim->iip) ; +// } // Not inlining for the moment to avoid getting 'unresolved external symbol' errors in Windows. // This could also be resolved by moving the function into the header... diff --git a/plugins/zzogl-pg/opengl/ZZoglDrawing.h b/plugins/zzogl-pg/opengl/ZZoglDrawing.h index 96e263925d..c9387b791a 100644 --- a/plugins/zzogl-pg/opengl/ZZoglDrawing.h +++ b/plugins/zzogl-pg/opengl/ZZoglDrawing.h @@ -23,7 +23,14 @@ #include "Util.h" #include "GS.h" -extern bool __forceinline NoHighlights(int i); +// extern bool __forceinline NoHighlights(int i); + +// return true if triangle SHOULD be painted. +// Hackish and should be replaced. +// Previous version was an inlined function but gcc-4.6 does not want to inline it. +// Because the code is in the middle of vertex which are very often call, +// a basic macro is more effective -- Gregory +#define NoHighlights(I) (!(conf.settings().xenosaga_spec) || !vb[(I)].zbuf.zmsk || prim->iip) enum PRIM_TYPE { PRIM_POINT = 0,