Skip to content

Commit 6b0e120

Browse files
committedJul 23, 2015
wavesynth/Synthesizer: allow empty data
·
8.00.1
1 parent 5b1165f commit 6b0e120

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed
 

‎artiq/wavesynth/compute_samples.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ def __init__(self):
99
self.c = [0.0]
1010

1111
def set_coefficients(self, c):
12+
if not c:
13+
c = [0.]
1214
self.c = copy(c)
1315
discrete_compensate(self.c)
1416

@@ -25,6 +27,8 @@ def __init__(self):
2527
self.c0 = 0.0
2628

2729
def set_coefficients(self, c):
30+
if not c:
31+
c = [0.]
2832
self.c0 = c[0]
2933
c1p = c[1:]
3034
discrete_compensate(c1p)

0 commit comments

Comments
 (0)
Please sign in to comment.