File tree Expand file tree Collapse file tree 2 files changed +14
-2
lines changed
Expand file tree Collapse file tree 2 files changed +14
-2
lines changed Original file line number Diff line number Diff line change 1+ from functools import singledispatch
12import numpy as np
23import warnings
34from .. import hoa
5+ from ..layout import Layout
46from .. import point_source
57
68
@@ -85,3 +87,13 @@ def design(self, type_metadata):
8587 decoder /= np .sqrt (np .mean (np .sum (np .dot (decoder , K_v ) ** 2 , axis = 0 )))
8688
8789 return decoder
90+
91+
92+ @singledispatch
93+ def build_hoa_decoder_design (layout , ** options ):
94+ return None
95+
96+
97+ @build_hoa_decoder_design .register (Layout )
98+ def _build_hoa_decoder_design_speakers (layout , ** options ):
99+ return HOADecoderDesign (layout , ** options )
Original file line number Diff line number Diff line change 11import numpy as np
22from attr import attrs , attrib
3- from .design import HOADecoderDesign
3+ from .design import build_hoa_decoder_design
44from ..renderer_common import BlockProcessingChannel , InterpretTimingMetadata , ProcessingBlock
55from ..track_processor import MultiTrackProcessor
66
@@ -65,7 +65,7 @@ class HOARenderer(object):
6565 """
6666
6767 def __init__ (self , layout , design_opts = {}):
68- self ._decoder_design = HOADecoderDesign (layout .without_lfe , ** design_opts )
68+ self ._decoder_design = build_hoa_decoder_design (layout .without_lfe , ** design_opts )
6969 self ._output_channels = ~ layout .is_lfe
7070
7171 self .block_processing_channels = []
You can’t perform that action at this time.
0 commit comments