support range caps
This commit is contained in:
parent
bcb4036f48
commit
e71dbf3bc9
1 changed files with 2 additions and 0 deletions
|
@ -54,6 +54,8 @@ class Audio(gst.Pipeline):
|
|||
caps = pad.get_caps()
|
||||
if 'audio' in str(caps):
|
||||
self.samplerate = caps[0]['rate']
|
||||
if not isinstance(self.samplerate, int):
|
||||
self.samplerate = self.samplerate.high
|
||||
pad.link(self.queue.get_pad("sink"))
|
||||
self.queue.link(self.conv)
|
||||
self.conv.link(self.rate,
|
||||
|
|
Loading…
Reference in a new issue