diff options
| author | Xavier Del Campo Romero <xavi92@disroot.org> | 2025-11-16 00:36:51 +0100 |
|---|---|---|
| committer | Xavier Del Campo Romero <xavi92@disroot.org> | 2025-11-16 00:36:51 +0100 |
| commit | 788fb20656c8450a3f2da8b3f8b1905242103193 (patch) | |
| tree | ae6e1a2c9e7da0fe72b070d2db580adf26e410af /plugins/dfxvideo/draw.c | |
| parent | 8349bf45e9b19d83506e1bb52f2053a7976922e5 (diff) | |
| download | pcsxr-sio.tar.gz | |
WIP TCP/SIOsio
Diffstat (limited to 'plugins/dfxvideo/draw.c')
| -rw-r--r-- | plugins/dfxvideo/draw.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/plugins/dfxvideo/draw.c b/plugins/dfxvideo/draw.c index 3cc5e1c2..76007919 100644 --- a/plugins/dfxvideo/draw.c +++ b/plugins/dfxvideo/draw.c @@ -82,7 +82,7 @@ void * pSaIBigBuff=NULL; #define GET_RESULT(A, B, C, D) ((A != C || A != D) - (B != C || B != D)) -static __inline int GetResult1(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) +static int GetResult1(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) { int x = 0; int y = 0; @@ -94,7 +94,7 @@ static __inline int GetResult1(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) return r; } -static __inline int GetResult2(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) +static int GetResult2(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) { int x = 0; int y = 0; @@ -107,7 +107,7 @@ static __inline int GetResult2(DWORD A, DWORD B, DWORD C, DWORD D, DWORD E) } /* Convert RGB to YUV */ -__inline uint32_t rgb_to_yuv(uint8_t R, uint8_t G, uint8_t B) { +static uint32_t rgb_to_yuv(uint8_t R, uint8_t G, uint8_t B) { uint8_t Y = min(abs(R * 2104 + G * 4130 + B * 802 + 4096 + 131072) >> 13, 235); uint8_t U = min(abs(R * -1214 + G * -2384 + B * 3598 + 4096 + 1048576) >> 13, 240); uint8_t V = min(abs(R * 3598 + G * -3013 + B * -585 + 4096 + 1048576) >> 13, 240); @@ -653,7 +653,7 @@ void SuperEagle_ex8(unsigned char *srcPtr, DWORD srcPitch, //#include <assert.h> -static __inline void scale2x_32_def_whole(uint32_t* dst0, uint32_t* dst1, const uint32_t* src0, const uint32_t* src1, const uint32_t* src2, unsigned count) +static void scale2x_32_def_whole(uint32_t* dst0, uint32_t* dst1, const uint32_t* src0, const uint32_t* src1, const uint32_t* src2, unsigned count) { //assert(count >= 2); @@ -750,7 +750,7 @@ void Scale2x_ex8(unsigned char *srcPtr, DWORD srcPitch, //////////////////////////////////////////////////////////////////////// -static __inline void scale3x_32_def_whole(uint32_t* dst0, uint32_t* dst1, uint32_t* dst2, const uint32_t* src0, const uint32_t* src1, const uint32_t* src2, unsigned count) +static void scale3x_32_def_whole(uint32_t* dst0, uint32_t* dst1, uint32_t* dst2, const uint32_t* src0, const uint32_t* src1, const uint32_t* src2, unsigned count) { //assert(count >= 2); @@ -1053,7 +1053,8 @@ void CreateDisplay(void) #ifdef __BIG_ENDIAN__ if ( fo[j].type == XvYUV && fo[j].bits_per_pixel == 16 && fo[j].format == XvPacked && strncmp("YUYV", fo[j].component_order, 5) == 0 ) #else - if ( fo[j].type == XvYUV && fo[j].bits_per_pixel == 16 && fo[j].format == XvPacked && strncmp("UYVY", fo[j].component_order, 5) == 0 ) + /*if ( fo[j].type == XvYUV && fo[j].bits_per_pixel == 16 && fo[j].format == XvPacked && strncmp("UYVY", fo[j].component_order, 5) == 0 )*/ + if ( fo[j].type == XvYUV && fo[j].bits_per_pixel == 12 && fo[j].format == XvPlanar && strcmp("YVU", fo[j].component_order) == 0 ) #endif { yuv_port = p; @@ -1065,7 +1066,7 @@ void CreateDisplay(void) rgb_id = fo[j].id; xv_depth = fo[j].depth; printf("RGB mode found. id: %x, depth: %d\n", xv_id, xv_depth); - + if (xv_depth != depth) { printf("Warning: Depth does not match screen depth (%d)\n", depth); } @@ -1078,7 +1079,6 @@ void CreateDisplay(void) } // Are we searching for a specific mode? - /* if ( fo[j].id == uOverrideMode) { if (fo[j].type == XvYUV) { xv_id = yuv_id = fo[j].id; @@ -1095,7 +1095,7 @@ void CreateDisplay(void) p = p_num_ports; i = p_num_adaptors; //break; - }*/ + } } if (fo) XFree(fo); @@ -1594,7 +1594,7 @@ extern time_t tStart; * The aspect of the psx output mode is preserved. * Note: dest dx,dy,dw,dh are both input and output variables */ -__inline void MaintainAspect(uint32_t * dx, uint32_t * dy, uint32_t * dw, uint32_t * dh) +void MaintainAspect(uint32_t * dx, uint32_t * dy, uint32_t * dw, uint32_t * dh) { double ratio_x = ((double)*dw) / ((double)PSXDisplay.DisplayMode.x) ; |
