summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/test-display.c84
1 files changed, 0 insertions, 84 deletions
diff --git a/tests/test-display.c b/tests/test-display.c
index 9abe7546..154ca404 100644
--- a/tests/test-display.c
+++ b/tests/test-display.c
@@ -51,9 +51,6 @@
# include <va/va_glx.h>
#endif
-/* Set to 1 to check display cache works (shared VA display) */
-#define CHECK_DISPLAY_CACHE 1
-
static void
print_value (const GValue * value, const gchar * name)
{
@@ -270,9 +267,6 @@ int
main (int argc, char *argv[])
{
GstVaapiDisplay *display;
-#if USE_X11
- GstVaapiDisplay *display2;
-#endif
#if USE_X11 || USE_WAYLAND
guint width, height;
guint par_n, par_d;
@@ -349,46 +343,6 @@ main (int argc, char *argv[])
display = gst_vaapi_display_x11_new (NULL);
if (!display)
g_error ("could not create Gst/VA display");
-
- if (CHECK_DISPLAY_CACHE) {
- display2 = gst_vaapi_display_x11_new (NULL);
-
- /* Check for the same X11 display */
- g_assert (gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11
- (display)) ==
- gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11 (display2)));
-
- /* Check for the same VA display */
- g_assert (gst_vaapi_display_get_display (display) ==
- gst_vaapi_display_get_display (display2));
-
- gst_vaapi_display_unref (display2);
-
-#if USE_GLX
- display2 = gst_vaapi_display_glx_new (NULL);
-
- /* Check for the different X11 display */
- /* XXX: it is also desired to cache underlying X11 displays */
- g_assert (gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11
- (display)) !=
- gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11 (display2)));
-
- /* Check for different VA display */
- g_assert (gst_vaapi_display_get_display (display) !=
- gst_vaapi_display_get_display (display2));
-
- gst_vaapi_display_unref (display2);
-#endif
- }
-
- gst_vaapi_display_get_size (display, &width, &height);
- g_print ("Display size: %ux%u\n", width, height);
-
- gst_vaapi_display_get_pixel_aspect_ratio (display, &par_n, &par_d);
- g_print ("Pixel aspect ratio: %u/%u\n", par_n, par_d);
-
- dump_info (display);
- gst_vaapi_display_unref (display);
}
g_print ("\n");
@@ -406,16 +360,6 @@ main (int argc, char *argv[])
if (!display)
g_error ("could not create Gst/VA display");
- if (CHECK_DISPLAY_CACHE) {
- display2 = gst_vaapi_display_x11_new_with_display (x11_display);
-
- /* Check for the same VA display */
- g_assert (gst_vaapi_display_get_display (display) ==
- gst_vaapi_display_get_display (display2));
-
- gst_vaapi_display_unref (display2);
- }
-
dump_info (display);
gst_vaapi_display_unref (display);
XCloseDisplay (x11_display);
@@ -458,34 +402,6 @@ main (int argc, char *argv[])
if (!display)
g_error ("could not create Gst/VA display");
- if (CHECK_DISPLAY_CACHE) {
- display2 = gst_vaapi_display_glx_new (NULL);
-
- /* Check for the same X11 display */
- g_assert (gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11
- (display)) ==
- gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11 (display2)));
-
- /* Check for the same VA display */
- g_assert (gst_vaapi_display_get_display (display) ==
- gst_vaapi_display_get_display (display2));
-
- gst_vaapi_display_unref (display2);
-
- display2 = gst_vaapi_display_x11_new (NULL);
-
- /* Check for the same X11 display */
- g_assert (gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11
- (display)) ==
- gst_vaapi_display_x11_get_display (GST_VAAPI_DISPLAY_X11 (display2)));
-
- /* Check for the same VA display */
- g_assert (gst_vaapi_display_get_display (display) ==
- gst_vaapi_display_get_display (display2));
-
- gst_vaapi_display_unref (display2);
- }
-
gst_vaapi_display_get_size (display, &width, &height);
g_print ("Display size: %ux%u\n", width, height);