gst1: Replace 'struct[x] = y' with 'struct.set_value(x, y)'
This commit is contained in:
parent
01bf8b773f
commit
6c59205efe
@ -91,8 +91,8 @@ def _setup_pipeline(uri, proxy_config=None):
|
||||
|
||||
def _have_type(element, probability, caps, decodebin):
|
||||
decodebin.set_property('sink-caps', caps)
|
||||
struct = Gst.Structure('have-type')
|
||||
struct['caps'] = caps.get_structure(0)
|
||||
struct = Gst.Structure.new_empty('have-type')
|
||||
struct.set_value('caps', caps.get_structure(0))
|
||||
element.get_bus().post(Gst.message_new_application(element, struct))
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user