From 488d29eb41b1f9d5eb7adeee558ca5341dcbd74b Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Fri, 7 May 2021 18:19:55 +0200 Subject: [PATCH] gtk: Rename display pixel aspect ratio related constants Part-of: --- subprojects/gst-plugins-good/ext/gtk/gstgtkbasesink.c | 13 +++++++------ subprojects/gst-plugins-good/ext/gtk/gtkgstbasewidget.c | 13 +++++++------ 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/subprojects/gst-plugins-good/ext/gtk/gstgtkbasesink.c b/subprojects/gst-plugins-good/ext/gtk/gstgtkbasesink.c index 3005024..bc9a6a4 100644 --- a/subprojects/gst-plugins-good/ext/gtk/gstgtkbasesink.c +++ b/subprojects/gst-plugins-good/ext/gtk/gstgtkbasesink.c @@ -35,8 +35,8 @@ GST_DEBUG_CATEGORY (gst_debug_gtk_base_sink); #define GST_CAT_DEFAULT gst_debug_gtk_base_sink #define DEFAULT_FORCE_ASPECT_RATIO TRUE -#define DEFAULT_PAR_N 0 -#define DEFAULT_PAR_D 1 +#define DEFAULT_DISPLAY_PAR_N 0 +#define DEFAULT_DISPLAY_PAR_D 1 #define DEFAULT_IGNORE_ALPHA TRUE static void gst_gtk_base_sink_finalize (GObject * object); @@ -113,8 +113,9 @@ gst_gtk_base_sink_class_init (GstGtkBaseSinkClass * klass) g_object_class_install_property (gobject_class, PROP_PIXEL_ASPECT_RATIO, gst_param_spec_fraction ("pixel-aspect-ratio", "Pixel Aspect Ratio", - "The pixel aspect ratio of the device", DEFAULT_PAR_N, DEFAULT_PAR_D, - G_MAXINT, 1, 1, 1, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + "The pixel aspect ratio of the device", DEFAULT_DISPLAY_PAR_N, + DEFAULT_DISPLAY_PAR_D, G_MAXINT, 1, 1, 1, + G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); g_object_class_install_property (gobject_class, PROP_IGNORE_ALPHA, g_param_spec_boolean ("ignore-alpha", "Ignore Alpha", @@ -138,8 +139,8 @@ static void gst_gtk_base_sink_init (GstGtkBaseSink * gtk_sink) { gtk_sink->force_aspect_ratio = DEFAULT_FORCE_ASPECT_RATIO; - gtk_sink->par_n = DEFAULT_PAR_N; - gtk_sink->par_d = DEFAULT_PAR_D; + gtk_sink->par_n = DEFAULT_DISPLAY_PAR_N; + gtk_sink->par_d = DEFAULT_DISPLAY_PAR_D; gtk_sink->ignore_alpha = DEFAULT_IGNORE_ALPHA; } diff --git a/subprojects/gst-plugins-good/ext/gtk/gtkgstbasewidget.c b/subprojects/gst-plugins-good/ext/gtk/gtkgstbasewidget.c index 8a912ea..de85c3f 100644 --- a/subprojects/gst-plugins-good/ext/gtk/gtkgstbasewidget.c +++ b/subprojects/gst-plugins-good/ext/gtk/gtkgstbasewidget.c @@ -30,8 +30,8 @@ GST_DEBUG_CATEGORY (gst_debug_gtk_base_widget); #define GST_CAT_DEFAULT gst_debug_gtk_base_widget #define DEFAULT_FORCE_ASPECT_RATIO TRUE -#define DEFAULT_PAR_N 0 -#define DEFAULT_PAR_D 1 +#define DEFAULT_DISPLAY_PAR_N 0 +#define DEFAULT_DISPLAY_PAR_D 1 #define DEFAULT_IGNORE_ALPHA TRUE enum @@ -454,8 +454,9 @@ gtk_gst_base_widget_class_init (GtkGstBaseWidgetClass * klass) g_object_class_install_property (gobject_klass, PROP_PIXEL_ASPECT_RATIO, gst_param_spec_fraction ("pixel-aspect-ratio", "Pixel Aspect Ratio", - "The pixel aspect ratio of the device", DEFAULT_PAR_N, DEFAULT_PAR_D, - G_MAXINT, 1, 1, 1, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + "The pixel aspect ratio of the device", DEFAULT_DISPLAY_PAR_N, + DEFAULT_DISPLAY_PAR_D, G_MAXINT, 1, 1, 1, + G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); g_object_class_install_property (gobject_klass, PROP_IGNORE_ALPHA, g_param_spec_boolean ("ignore-alpha", "Ignore Alpha", @@ -481,8 +482,8 @@ gtk_gst_base_widget_init (GtkGstBaseWidget * widget) int event_mask; widget->force_aspect_ratio = DEFAULT_FORCE_ASPECT_RATIO; - widget->par_n = DEFAULT_PAR_N; - widget->par_d = DEFAULT_PAR_D; + widget->par_n = DEFAULT_DISPLAY_PAR_N; + widget->par_d = DEFAULT_DISPLAY_PAR_D; widget->ignore_alpha = DEFAULT_IGNORE_ALPHA; gst_video_info_init (&widget->v_info); -- 2.7.4