mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 03:31:05 +00:00
python: Fix variable name for gst_element_factory_make
In order to use keyword argument, the names shoudl match the documentation. Both arguments name was changed in the override. Fixes: #2779 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4982>
This commit is contained in:
parent
31c1cf0150
commit
60afc6cc95
1 changed files with 5 additions and 5 deletions
|
@ -83,14 +83,14 @@ class Bin(Gst.Bin):
|
|||
if not Gst.Bin.add(self, arg):
|
||||
raise AddError(arg)
|
||||
|
||||
def make_and_add(self, factory_name, instance_name=None):
|
||||
def make_and_add(self, factoryname, name=None):
|
||||
'''
|
||||
@raises: Gst.AddError
|
||||
'''
|
||||
elem = Gst.ElementFactory.make(factory_name, instance_name)
|
||||
elem = Gst.ElementFactory.make(factoryname, name)
|
||||
if not elem:
|
||||
raise AddError(
|
||||
'No such element: {}'.format(factory_name))
|
||||
'No such element: {}'.format(factoryname))
|
||||
self.add(elem)
|
||||
return elem
|
||||
|
||||
|
@ -288,8 +288,8 @@ class ElementFactory(Gst.ElementFactory):
|
|||
return self.get_metadata("klass")
|
||||
|
||||
@classmethod
|
||||
def make(cls, factory_name, instance_name=None):
|
||||
return Gst.ElementFactory.make(factory_name, instance_name)
|
||||
def make(cls, factoryname, name=None):
|
||||
return Gst.ElementFactory.make(factoryname, name)
|
||||
|
||||
|
||||
class Pipeline(Gst.Pipeline):
|
||||
|
|
Loading…
Reference in a new issue