[dead code] remove some unused code

also fix some parts no longer compiling after enabling it again
This commit is contained in:
akallabeth
2025-03-04 17:16:05 +01:00
parent 12f538bb92
commit 61910ad0b5
5 changed files with 25 additions and 50 deletions

View File

@@ -44,23 +44,9 @@ static BOOL test_RGBToRGB_16s8u_P3AC4R_func(prim_size_t roi, DWORD DstFormat)
if (!r || !g || !b || !out1 || !out2)
goto fail;
#if 0
{
for (UINT32 y = 0; y < roi.height; y++)
{
for (UINT32 x = 0; x < roi.width; x++)
{
r[y * roi.width + x] = 0x01;
g[y * roi.width + x] = 0x02;
b[y * roi.width + x] = 0x04;
}
}
}
#else
winpr_RAND(r, 1ULL * rgbStride * roi.height);
winpr_RAND(g, 1ULL * rgbStride * roi.height);
winpr_RAND(b, 1ULL * rgbStride * roi.height);
#endif
ptrs[0] = r;
ptrs[1] = g;
ptrs[2] = b;
@@ -96,7 +82,7 @@ static BOOL test_RGBToRGB_16s8u_P3AC4R_func(prim_size_t roi, DWORD DstFormat)
}
}
printf("Results for %" PRIu32 "x%" PRIu32 " [%s]", roi.width, roi.height,
printf("Results for %" PRIu32 "x%" PRIu32 " [%s]\n", roi.width, roi.height,
FreeRDPGetColorFormatName(DstFormat));
PROFILER_PRINT_HEADER
PROFILER_PRINT(genericProf)
@@ -276,8 +262,6 @@ int TestPrimitivesColors(int argc, char* argv[])
if (!test_RGBToRGB_16s8u_P3AC4R_func(roi, formats[x]))
return 1;
#if 0
if (g_TestPrimitivesPerformance)
{
if (!test_RGBToRGB_16s8u_P3AC4R_speed())
@@ -292,8 +276,6 @@ int TestPrimitivesColors(int argc, char* argv[])
if (!test_yCbCrToRGB_16s16s_P3P3_speed())
return 1;
}
#endif
}
return 0;

View File

@@ -245,21 +245,25 @@ int TestPrimitivesCopy(int argc, char* argv[])
FREERDP_KEEP_DST_ALPHA,
FREERDP_FLIP_HORIZONTAL,
FREERDP_KEEP_DST_ALPHA | FREERDP_FLIP_HORIZONTAL,
#if 0
FREERDP_FLIP_VERTICAL,
FREERDP_FLIP_VERTICAL | FREERDP_FLIP_HORIZONTAL,
FREERDP_KEEP_DST_ALPHA | FREERDP_FLIP_VERTICAL,
FREERDP_KEEP_DST_ALPHA | FREERDP_FLIP_VERTICAL | FREERDP_FLIP_HORIZONTAL
#if defined(TEST_ALL_FLAGS)
FREERDP_FLIP_VERTICAL,
FREERDP_FLIP_VERTICAL | FREERDP_FLIP_HORIZONTAL,
FREERDP_KEEP_DST_ALPHA | FREERDP_FLIP_VERTICAL,
FREERDP_KEEP_DST_ALPHA | FREERDP_FLIP_VERTICAL | FREERDP_FLIP_HORIZONTAL
#endif
};
const UINT32 formats[] = {
PIXEL_FORMAT_BGRA32,
PIXEL_FORMAT_BGRX32,
PIXEL_FORMAT_BGR24
#if 0 /* Only the previous 3 have SIMD optimizations, so skip the rest */
, PIXEL_FORMAT_RGB24,
PIXEL_FORMAT_ABGR32, PIXEL_FORMAT_ARGB32, PIXEL_FORMAT_XBGR32,
PIXEL_FORMAT_XRGB32, PIXEL_FORMAT_RGBA32, PIXEL_FORMAT_RGBX32
const UINT32 formats[] = { PIXEL_FORMAT_BGRA32,
PIXEL_FORMAT_BGRX32,
PIXEL_FORMAT_BGR24
#if defined(TEST_ALL_FLAGS) /* Only the previous 3 have SIMD optimizations, so skip the rest */
,
PIXEL_FORMAT_RGB24,
PIXEL_FORMAT_ABGR32,
PIXEL_FORMAT_ARGB32,
PIXEL_FORMAT_XBGR32,
PIXEL_FORMAT_XRGB32,
PIXEL_FORMAT_RGBA32,
PIXEL_FORMAT_RGBX32
#endif
};