-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'data' and 'done' callbacks don't get invoked #194
Comments
It looks like the 3rd segment does not contain any audio data, but the PMT says there is an audio track. Because of this code here https://github.com/videojs/mux.js/blob/master/lib/mp4/transmuxer.js#L1110 the transmuxer is waiting for audio data that is never coming. You should be able to fix this by setting the
Note that this will result in separate |
Thanks a lot for replying, @mjneil! Could you give me more context on a couple of things:
Thanks! |
PMT stands for Program Map Table. It is part of MPEG-TS and essentially says which elementary streams are available. In the source you provided, the PMT packet says there are two elementary streams available, type 15 ADTS AAC audio and type 27 H.264 video.
Essentially yes. The transmuxer separates audio and video when processing the MPEG-TS packets. When When |
I tried setting I will try some other workarounds in Shaka Player, but I would appreciate any suggestions you might have. |
If I ignore the lack of callbacks and just move on to the next segment, I wind up with a MediaSource error from Chrome that says "CHUNK_DEMUXER_ERROR_APPEND_FAILED: Video track with track_id=258 already present." I think I'm out of ideas. |
With |
Ah, I see. We would have one input stream, and two SourceBuffers for output. That would be a completely different architecture, though, from what we have today. If that's what it takes to fix it, I think we would have to defer that for quite some time. @mjneil, is there any way that this could be fixed in mux.js? |
@TheModMaker has the right idea. With |
Its probably possible to fix within mux. Would need to add logic probably here https://github.com/videojs/mux.js/blob/master/lib/mp4/transmuxer.js#L1108 to determine if it should return or not. Easiest solution (though probably a messy one) would probably be if the flush source is |
an alternative could be to re-create the init segment outside of mux within shaka after you've gotten your done event. You would need to create a video and audio track object that contain the properties touched by the generator https://github.com/videojs/mux.js/blob/master/lib/mp4/mp4-generator.js#L762 most of the properties get attached to |
@mjneil any updated on this issue? |
@mjneil i'm facing media decode error in videojs 7 and shaka. Is there any way to find errors in the audio / video tracks using mux.js. Please guide me with debugging the audio / video tracks with mux.js. |
@ismena @joeyparrish @TheModMaker @sridhard I just created #224 which should address this issue. Please if you have a chance, test it out with your use case and let me know if it solves the issue or if you encounter any issues. |
I'm going to be out of the office for a while, so I will not be able to test the PR until November. If someone else can test before then, please do! |
Any update on this |
Repro:
Navigate to https://v2-4-0-dot-shaka-player-demo.appspot.com/demo/#asset=https://s3-ap-southeast-1.amazonaws.com/learnyst/testfolder/sample/expresshls/hls.m3u8;play and start playback.
For the first 2 segments (https://s3-ap-southeast-1.amazonaws.com/learnyst/testfolder/sample/expresshls/zh3il5009f-yxhbaADHqLeCAo3k.ts and https://s3-ap-southeast-1.amazonaws.com/learnyst/testfolder/sample/expresshls/ZtV37gCCgR5cnwUrQliZEPG9zIU.ts) the callbacks get invoked, but not for the third one (https://s3-ap-southeast-1.amazonaws.com/learnyst/testfolder/sample/expresshls/X3cf3WEJqIG6EfX0Yjq8dvGthAc.ts) although they are present in the transmuxer's internal listeners collection.
The code that registers the callbacks:
The text was updated successfully, but these errors were encountered: