0
I'm having an issue with AVC/H.264 playback in Chrome, but cannot seem to get any information on what is wrong with my video.
First, a quick overview of my setup: I have a service that will use the FFMpeg API to transcode video into an H.264 stream, then package it up into a Fragmented Mp4 container to be used in a MPEG-DASH stream. This stream is consumed by the browser using Media Source Extensions to append first the Mp4 headers, and then each subsequent segment file as it's downloaded.
This works reliably in Firefox, but that's not always the case in Chrome. In Chrome, I am seeing that sometimes the player is getting stuck in the ReadyState HAVE_METADATA. No matter how much segment data is appended, the player never changes it's ready state to HAVE_CURRENT_DATA or fires the 'loadeddata' event. What's very strange about this is that if I manually call video.play() anyway, the 'loadeddata' event is fired, the player readyState advances to HAVE_ENOUGH_DATA, and the video begins to play like normal even though browser thought it did not have any playable video.
While I would love an answer as to why the video is not able to play properly, this question is more about how I can find that out myself. I have searched around looking for validation tools to validate that I followed the H.264 and MP4 specifications properly, but haven't had much luck with the open source options.
I would also love to know how can I get chrome to spit out some kind of error message. I've looked into building Chromium from source to see if I could debug the browser/decoder, but quickly found that Chromium does not include the H.264 codec. I have also looked into enabling logging for Chrome but did not have too much success there as I could not find any information on enabling the right logging module. I even killed a few hours reading a chrome logfile with all modules set to verbose and found nothing useful.