Fix handling of streams with no audio tracks
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This commit is contained in:
parent
8f95da4b07
commit
2234962acc
2 changed files with 2 additions and 2 deletions
|
@ -72,7 +72,7 @@ export function VideoTileContainer({
|
||||||
audioOutputDevice,
|
audioOutputDevice,
|
||||||
audioContext,
|
audioContext,
|
||||||
audioDestination,
|
audioDestination,
|
||||||
isLocal,
|
isLocal || audioMuted,
|
||||||
localVolume
|
localVolume
|
||||||
);
|
);
|
||||||
const {
|
const {
|
||||||
|
|
|
@ -213,7 +213,7 @@ export const useSpatialMediaStream = (
|
||||||
const sourceRef = useRef<MediaStreamAudioSourceNode>();
|
const sourceRef = useRef<MediaStreamAudioSourceNode>();
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (spatialAudio && tileRef.current && !mute) {
|
if (spatialAudio && audioContext && tileRef.current && !mute) {
|
||||||
if (!pannerNodeRef.current) {
|
if (!pannerNodeRef.current) {
|
||||||
pannerNodeRef.current = new PannerNode(audioContext, {
|
pannerNodeRef.current = new PannerNode(audioContext, {
|
||||||
panningModel: "HRTF",
|
panningModel: "HRTF",
|
||||||
|
|
Loading…
Reference in a new issue