We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d58fb8b commit a4efc88Copy full SHA for a4efc88
livekit-rtc/livekit/rtc/audio_frame.py
@@ -49,6 +49,9 @@ def __init__(
49
Raises:
50
ValueError: If the length of `data` is smaller than the required size.
51
"""
52
+ if isinstance(data, memoryview):
53
+ data = data.cast("B")
54
+
55
data = _ensure_compatible_buffer(data)
56
57
min_size = num_channels * samples_per_channel * ctypes.sizeof(ctypes.c_int16)
0 commit comments