Gstreamer 如何从gst_parse_启动返回的GstElement获取指向GstPipeline的指针?
我正在将一个python GStreamer 1.0示例(play-master.py-noraisin.net)从python移植到C,但不知道如何获取指向管道的指针。在python绑定中,它似乎是抽象的,因此元素和管道可以互换使用Gstreamer 如何从gst_parse_启动返回的GstElement获取指向GstPipeline的指针?,gstreamer,Gstreamer,我正在将一个python GStreamer 1.0示例(play-master.py-noraisin.net)从python移植到C,但不知道如何获取指向管道的指针。在python绑定中,它似乎是抽象的,因此元素和管道可以互换使用 ... GstElement* element = gst_parse_launch("playbin", &error); gst_element_set_start_time(element, GST_CLOCK_TIME_NONE); GstC
...
GstElement* element = gst_parse_launch("playbin", &error);
gst_element_set_start_time(element, GST_CLOCK_TIME_NONE);
GstClock* clock = gst_element_get_clock(element);
gst_pipeline_use_clock( ???, clock);
...
因此,gst\u pipeline\u use\u clock
需要一个指向GstPipeline
结构的指针,但是gst\u parse\u launch
返回一个指向GstElement
的指针,如果我理解正确,它有一个指向管道的指针。如何访问它
以下是python中的相同代码:
Gst.init()
pipeline = Gst.parse_launch('playbin')
pipeline.set_start_time(Gst.CLOCK_TIME_NONE)
clock = pipeline.get_clock()
pipeline.use_clock(clock)
使用
GST\u管道
宏包装GstElement*
,例如:
GstPipeline *pipeline = GST_PIPELINE(gst_parse_launch("playbin", &error));
存在类似的宏以转换为其他元素类型。可以使用
GST\u管道
宏包装GstElement*
,例如:
GstPipeline *pipeline = GST_PIPELINE(gst_parse_launch("playbin", &error));
存在类似的宏以转换为其他元素类型。可以使用
GST\u管道
宏包装GstElement*
,例如:
GstPipeline *pipeline = GST_PIPELINE(gst_parse_launch("playbin", &error));
存在类似的宏以转换为其他元素类型。可以使用
GST\u管道
宏包装GstElement*
,例如:
GstPipeline *pipeline = GST_PIPELINE(gst_parse_launch("playbin", &error));
存在类似的宏以转换为其他图元类型