[rygel-gst-0-10-media-engine] Added explanatory comments. Also in the vala code.



commit 09358ac14e9da3dd94169b7e51d19c2d179e45c9
Author: Murray Cumming <murrayc murrayc com>
Date:   Mon Jan 7 12:05:10 2013 +0100

    Added explanatory comments. Also in the vala code.

 src/rygel-gst-media-engine.c |   18 +++++++++++++++++-
 1 files changed, 17 insertions(+), 1 deletions(-)
---
diff --git a/src/rygel-gst-media-engine.c b/src/rygel-gst-media-engine.c
index 0fb2c8c..2e173b4 100644
--- a/src/rygel-gst-media-engine.c
+++ b/src/rygel-gst-media-engine.c
@@ -52,6 +52,13 @@ rygel_gst_media_engine_construct (GType object_type) {
   gst_init (NULL, NULL);
   gst_preset_set_app_dir (PRESET_DIR);
 
+  /* Get the possible DLNA profiles
+   * to add to the list of DLNA profiles supported by
+   * this media engine, for get_dlna_profiles().
+   * Note that these are DLNA profiles supported as sources,
+   * not supported as transcoding profiles - the transcoders
+   * report their own target DLNA profiles.
+   */
   discoverer = gupnp_dlna_discoverer_new ((GstClockTime) GST_SECOND, TRUE, FALSE);
   profile_collection = gupnp_dlna_discoverer_list_profiles (discoverer);
 
@@ -61,19 +68,28 @@ rygel_gst_media_engine_construct (GType object_type) {
     const gchar *name = gupnp_dlna_profile_get_name (profile);
     const gchar *mime = gupnp_dlna_profile_get_mime (profile);
 
+    /* TODO: Check that we (via GStreamer) really support this profile
+     * instead of just claiming to support everything.
+     */
     RygelDLNAProfile *rygel_profile = rygel_dlna_profile_new (name, mime);
     self->priv->dlna_profiles = g_list_prepend (self->priv->dlna_profiles, rygel_profile);
   }
 
   self->priv->dlna_profiles = g_list_reverse (self->priv->dlna_profiles);
 
+  /* All some transcoders to be disabled by the Rygel Server configuration.
+   * For instance, some DLNA Renderers might incorrectly prefer inferior transcoded formats,
+   * sometimes even preferring transcoded formats over the original data,
+   * so this forces them to use other formats.
+   */
   config = rygel_meta_config_get_default ();
   
   transcoding = rygel_configuration_get_transcoding (config, &error);
   if (error) {
     g_clear_error (&error);
   } else {
-    transcoder_list = rygel_configuration_get_string_list (config, "MediaEngine", "transcoders", &error);
+    /* Note that the default GStreamer media engine uses the same config group name. */
+    transcoder_list = rygel_configuration_get_string_list (config, "GstMediaEngine", "transcoders", &error);
     if (error) {
       g_clear_error (&error);
       transcoder_list = NULL;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]