[gst-cvs] gst-openmax: plugin: add support for system-wide config
Felipe Contreras
felipec at kemper.freedesktop.org
Sat Mar 13 06:45:24 PST 2010
Module: gst-openmax
Branch: master
Commit: 662a32e4ff44b067391fd7ed7bbef8875a3d8e45
URL: http://cgit.freedesktop.org/gstreamer/gst-openmax/commit/?id=662a32e4ff44b067391fd7ed7bbef8875a3d8e45
Author: Felipe Contreras <felipe.contreras at nokia.com>
Date: Mon Mar 8 21:54:33 2010 +0200
plugin: add support for system-wide config
Signed-off-by: Felipe Contreras <felipe.contreras at nokia.com>
---
omx/gstomx.c | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/omx/gstomx.c b/omx/gstomx.c
index cb26eef..71bafd9 100644
--- a/omx/gstomx.c
+++ b/omx/gstomx.c
@@ -117,13 +117,21 @@ get_config_path (void)
if (path)
return path;
+ dirs = g_get_system_config_dirs ();
+ for (i = 0; dirs[i]; i++)
+ {
+ path = g_build_filename (dirs[i], "gstreamer-0.10", "gst-openmax.conf", NULL);
+ if (g_file_test (path, G_FILE_TEST_IS_REGULAR))
+ return path;
+ g_free (path);
+ }
+
return g_build_filename (g_get_user_config_dir (),
"gst-openmax.conf", NULL);
}
/**
* @todo find a way to call plugin_init() when the config file changes
- * @todo support a system-wide config file
* @todo provide a recommended system-wide config file
*/
More information about the Gstreamer-commits
mailing list