use the new execmodule where appropriate

This commit is contained in:
Jakob Ketterl 2023-08-21 23:18:58 +02:00
parent 69d9a5ae79
commit 32fcfad4d5
5 changed files with 75 additions and 75 deletions

View file

@ -1,14 +1,11 @@
from csdr.module import PopenModule
from pycsdr.modules import ExecModule
from pycsdr.types import Format
class DrmModule(PopenModule):
def getInputFormat(self) -> Format:
return Format.COMPLEX_FLOAT
def getOutputFormat(self) -> Format:
return Format.SHORT
def getCommand(self):
# dream -c 6 --sigsrate 48000 --audsrate 48000 -I - -O -
return ["dream", "-c", "6", "--sigsrate", "48000", "--audsrate", "48000", "-I", "-", "-O", "-"]
class DrmModule(ExecModule):
def __init__(self):
super().__init__(
Format.COMPLEX_SHORT,
Format.SHORT,
["dream", "-c", "6", "--sigsrate", "48000", "--audsrate", "48000", "-I", "-", "-O", "-"]
)