summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sounddevice.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/sounddevice.py b/sounddevice.py
index 1f515f7..4152aa8 100644
--- a/sounddevice.py
+++ b/sounddevice.py
@@ -1181,6 +1181,11 @@ class _StreamBase(object):
return _check(_lib.Pa_IsStreamStopped(self._ptr)) == 1
@property
+ def closed(self):
+ """``True`` after a call to `close()`, ``False`` otherwise."""
+ return self._ptr == _ffi.NULL
+
+ @property
def time(self):
"""The current stream time in seconds.