discoverer: rename boolean getters for consistency
authorStefan Kost <ensonic@users.sf.net>
Thu, 28 Oct 2010 15:51:08 +0000 (18:51 +0300)
committerTim-Philipp Müller <tim.muller@collabora.co.uk>
Sat, 30 Oct 2010 13:50:21 +0000 (14:50 +0100)
Rename _get_is_image() to _is_image() and _get_interlaced() to _is_interlaced().

https://bugzilla.gnome.org/show_bug.cgi?id=633311

gst-libs/gst/pbutils/gstdiscoverer-types.c
gst-libs/gst/pbutils/gstdiscoverer.h
tools/gst-discoverer.c
win32/common/libgstpbutils.def

index 9726b62..9c024d2 100644 (file)
@@ -471,7 +471,7 @@ gst_discoverer_stream_info_get_stream_type_nick (GstDiscovererStreamInfo * info)
   if (GST_IS_DISCOVERER_AUDIO_INFO (info))
     return "audio";
   if (GST_IS_DISCOVERER_VIDEO_INFO (info)) {
-    if (gst_discoverer_video_info_get_is_image ((GstDiscovererVideoInfo *)
+    if (gst_discoverer_video_info_is_image ((GstDiscovererVideoInfo *)
             info))
       return "video(image)";
     else
@@ -758,15 +758,20 @@ VIDEO_INFO_ACCESSOR_CODE (par_num, guint, 0);
 VIDEO_INFO_ACCESSOR_CODE (par_denom, guint, 0);
 
 /**
- * gst_discoverer_video_info_get_interlaced:
+ * gst_discoverer_video_info_is_interlaced:
  * @info: a #GstDiscovererVideoInfo
  *
  * Returns: %TRUE if the stream is interlaced, else %FALSE.
  *
  * Since 0.10.31
  */
+gboolean
+gst_discoverer_video_info_is_interlaced (const GstDiscovererVideoInfo * info)
+{
+  g_return_val_if_fail (GST_IS_DISCOVERER_VIDEO_INFO (info), FALSE);
 
-VIDEO_INFO_ACCESSOR_CODE (interlaced, gboolean, FALSE);
+  return info->interlaced;
+}
 
 /**
  * gst_discoverer_video_info_get_bitrate:
@@ -791,7 +796,7 @@ VIDEO_INFO_ACCESSOR_CODE (bitrate, guint, 0);
 VIDEO_INFO_ACCESSOR_CODE (max_bitrate, guint, 0);
 
 /**
- * gst_discoverer_video_info_get_is_image:
+ * gst_discoverer_video_info_is_image:
  * @info: a #GstDiscovererVideoInfo
  *
  * Returns: #TRUE if the video stream corresponds to an image (i.e. only contains
@@ -799,8 +804,13 @@ VIDEO_INFO_ACCESSOR_CODE (max_bitrate, guint, 0);
  *
  * Since 0.10.31
  */
+gboolean
+gst_discoverer_video_info_is_image (const GstDiscovererVideoInfo * info)
+{
+  g_return_val_if_fail (GST_IS_DISCOVERER_VIDEO_INFO (info), FALSE);
 
-VIDEO_INFO_ACCESSOR_CODE (is_image, gboolean, FALSE);
+  return info->is_image;
+}
 
 /* GstDiscovererInfo */
 
index 24cc0e4..6ea97f4 100644 (file)
@@ -123,10 +123,10 @@ guint           gst_discoverer_video_info_get_framerate_num(const GstDiscovererV
 guint           gst_discoverer_video_info_get_framerate_denom(const GstDiscovererVideoInfo* info);
 guint           gst_discoverer_video_info_get_par_num(const GstDiscovererVideoInfo* info);
 guint           gst_discoverer_video_info_get_par_denom(const GstDiscovererVideoInfo* info);
-gboolean        gst_discoverer_video_info_get_interlaced(const GstDiscovererVideoInfo* info);
+gboolean        gst_discoverer_video_info_is_interlaced(const GstDiscovererVideoInfo* info);
 guint           gst_discoverer_video_info_get_bitrate(const GstDiscovererVideoInfo* info);
 guint           gst_discoverer_video_info_get_max_bitrate(const GstDiscovererVideoInfo* info);
-gboolean        gst_discoverer_video_info_get_is_image(const GstDiscovererVideoInfo* info);
+gboolean        gst_discoverer_video_info_is_image(const GstDiscovererVideoInfo* info);
 
 /**
  * GstDiscovererResult:
index 3723081..b0c242c 100644 (file)
@@ -149,7 +149,7 @@ gst_stream_video_information_to_string (GstDiscovererStreamInfo * info,
       gst_discoverer_video_info_get_par_denom (video_info));
 
   my_g_string_append_printf (s, "Interlaced: %s\n",
-      gst_discoverer_video_info_get_interlaced (video_info) ? "true" : "false");
+      gst_discoverer_video_info_is_interlaced (video_info) ? "true" : "false");
 
   my_g_string_append_printf (s, "Bitrate: %u\n",
       gst_discoverer_video_info_get_bitrate (video_info));
index 4a07b1d..5f96c96 100644 (file)
@@ -50,13 +50,13 @@ EXPORTS
        gst_discoverer_video_info_get_framerate_denom
        gst_discoverer_video_info_get_framerate_num
        gst_discoverer_video_info_get_height
-       gst_discoverer_video_info_get_interlaced
-       gst_discoverer_video_info_get_is_image
        gst_discoverer_video_info_get_max_bitrate
        gst_discoverer_video_info_get_par_denom
        gst_discoverer_video_info_get_par_num
        gst_discoverer_video_info_get_type
        gst_discoverer_video_info_get_width
+       gst_discoverer_video_info_is_image
+       gst_discoverer_video_info_is_interlaced
        gst_install_plugins_async
        gst_install_plugins_context_free
        gst_install_plugins_context_get_type