Skip to content

Commit 463b5b0

Browse files
committed
Automatically run the mixer thread.
Making this not automatic caused usability issues. I'm defaulting it to run again.
1 parent 9ccf777 commit 463b5b0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tcod/sdl/audio.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,6 +267,7 @@ def __init__(self, device: AudioDevice):
267267
super().__init__(daemon=True)
268268
self.device = device
269269
self._lock = threading.RLock()
270+
self.start()
270271

271272
def run(self) -> None:
272273
buffer = np.full(
@@ -286,8 +287,8 @@ def on_stream(self, stream: NDArray[Any]) -> None:
286287

287288
class BasicMixer(Mixer):
288289
def __init__(self, device: AudioDevice):
289-
super().__init__(device)
290290
self.channels: Dict[Hashable, Channel] = {}
291+
super().__init__(device)
291292

292293
def get_channel(self, key: Hashable) -> Channel:
293294
with self._lock:

0 commit comments

Comments
 (0)