This commit is contained in:
yumoqing 2024-09-11 11:09:36 +08:00
parent 141fe2fd7b
commit 7199fcb0af

View File

@ -20,7 +20,7 @@ class MyAudioStreamTrack(AudioStreamTrack):
return None
f = await self.source.audio.recv()
while f is None:
self.set_source(MediaPlayer(self.source._file_path)
self.set_source(MyMediaPlayer(self.source._file_path))
f = await self.source.audio.recv()
return f
@ -38,6 +38,6 @@ class MyVideoStreamTrack(VideoStreamTrack):
return None
f = await self.source.video.recv()
while f is None:
self.set_source(MediaPlayer(self.source._file_path)
self.set_source(MyMediaPlayer(self.source._file_path))
f = await self.source.video.recv()
return f