diff options
author | Sebastian Pölsterl <marduk@k-d-w.org> | 2008-09-05 11:07:32 +0000 |
---|---|---|
committer | Zaheer Abbas Merali <zaheerabbas@merali.org> | 2008-09-05 11:07:32 +0000 |
commit | 64cd01e7e8a143e523466c911f7bb2e148508c3b (patch) | |
tree | 7c848be298b312a845fcf5bcf9749c39324994f7 | |
parent | d2a27c613140682670a6362f214fb8f61000ff94 (diff) | |
download | gst-plugins-bad-64cd01e7e8a143e523466c911f7bb2e148508c3b.tar.gz gst-plugins-bad-64cd01e7e8a143e523466c911f7bb2e148508c3b.tar.bz2 gst-plugins-bad-64cd01e7e8a143e523466c911f7bb2e148508c3b.zip |
sys/dvb/gstdvbsrc.c: Add DVB Adapter name to structure sent over bus.
Original commit message from CVS:
patch by: Sebastian Pölsterl
* sys/dvb/gstdvbsrc.c:
Add DVB Adapter name to structure sent over bus.
-rw-r--r-- | ChangeLog | 7 | ||||
m--------- | common | 0 | ||||
-rw-r--r-- | sys/dvb/gstdvbsrc.c | 9 |
3 files changed, 15 insertions, 1 deletions
@@ -1,3 +1,10 @@ +2008-09-05 Zaheer Abbas Merali <zaheerabbas at merali dot org> + + patch by: Sebastian Pölsterl + + * sys/dvb/gstdvbsrc.c: + Add DVB Adapter name to structure sent over bus. + 2008-09-02 Edward Hervey <edward.hervey@collabora.co.uk> * gst/mpegdemux/gstmpegdemux.c: (gst_flups_demux_parse_pack_start): diff --git a/common b/common -Subproject 8d494854a6018336a80ece82ceb3df0033e2da9 +Subproject a1e554f656b1f8829dbca280c0f1bdee9dec5e4 diff --git a/sys/dvb/gstdvbsrc.c b/sys/dvb/gstdvbsrc.c index ce562ea4..5b8f61a0 100644 --- a/sys/dvb/gstdvbsrc.c +++ b/sys/dvb/gstdvbsrc.c @@ -683,6 +683,7 @@ gst_dvbsrc_open_frontend (GstDvbSrc * object) char *adapter_desc = NULL; gchar *frontend_dev; GstStructure *adapter_structure; + char *adapter_name = NULL; frontend_dev = g_strdup_printf ("/dev/dvb/adapter%d/frontend%d", object->adapter_number, object->frontend_number); @@ -717,18 +718,22 @@ gst_dvbsrc_open_frontend (GstDvbSrc * object) return FALSE; } + adapter_name = g_strdup (fe_info.name); + object->adapter_type = fe_info.type; switch (object->adapter_type) { case FE_QPSK: adapter_desc = "DVB-S"; adapter_structure = gst_structure_new ("dvb-adapter", "type", G_TYPE_STRING, adapter_desc, + "name", G_TYPE_STRING, adapter_name, "auto-fec", G_TYPE_BOOLEAN, fe_info.caps & FE_CAN_FEC_AUTO, NULL); break; case FE_QAM: adapter_desc = "DVB-C"; adapter_structure = gst_structure_new ("dvb-adapter", "type", G_TYPE_STRING, adapter_desc, + "name", G_TYPE_STRING, adapter_name, "auto-inversion", G_TYPE_BOOLEAN, fe_info.caps & FE_CAN_INVERSION_AUTO, "auto-qam", G_TYPE_BOOLEAN, fe_info.caps & FE_CAN_QAM_AUTO, "auto-fec", G_TYPE_BOOLEAN, @@ -738,6 +743,7 @@ gst_dvbsrc_open_frontend (GstDvbSrc * object) adapter_desc = "DVB-T"; adapter_structure = gst_structure_new ("dvb-adapter", "type", G_TYPE_STRING, adapter_desc, + "name", G_TYPE_STRING, adapter_name, "auto-inversion", G_TYPE_BOOLEAN, fe_info.caps & FE_CAN_INVERSION_AUTO, "auto-qam", G_TYPE_BOOLEAN, fe_info.caps & FE_CAN_QAM_AUTO, "auto-transmission-mode", @@ -758,10 +764,11 @@ gst_dvbsrc_open_frontend (GstDvbSrc * object) "type", G_TYPE_STRING, "unknown", NULL); } - GST_INFO_OBJECT (object, "DVB card: %s ", fe_info.name); + GST_INFO_OBJECT (object, "DVB card: %s ", adapter_name); gst_element_post_message (GST_ELEMENT_CAST (object), gst_message_new_element (GST_OBJECT (object), adapter_structure)); g_free (frontend_dev); + g_free (adapter_name); return TRUE; } |