Hello,
I'm trying to create protected multibitrate DASH stream with mp4box.
It works if I use only 1 audio and 1 video:
mp4box -dash 10000 -rap -sample-groups-traf -profile dashavc264:live -segment-name %s_ "F:\Media\Sintel\CENC\cenc-aud-Sintel-128k.mp4" "F:\Media\Sintel\CENC\cenc-vid-Sintel-360p.mp4" -out "F:\Media\Sintel\BR\1QL\sintel.mpd"
When I try to add one more video quality level, it creates the segments and mpd but result is not playable in dash.js:
mp4box -dash 10000 -rap -sample-groups-traf -profile dashavc264:live -segment-name %s_ "F:\Media\Sintel\CENC\cenc-aud-Sintel-128k.mp4" "F:\Media\Sintel\CENC\cenc-vid-Sintel-360p.mp4" "F:\Media\Sintel\CENC\cenc-vid-Sintel-480p.mp4" -out "F:\Media\Sintel\BR\2QL\sintel.mpd"
Both streams, mp4 files and crypt info can be found here:
https://www.dropbox.com/sh/6v9p7azko1ofbuc/AADUw8YGoiM6VPSqpV0QH5pha?dl=0
Please let me know if you need more details.
Hi Kalle,
GPAC contributor here. I've downloaded and seen your files, thank you. I'm very interested in content protection issues.
You're using PlayReady with CENC in dash.js. Are you using IE11 on Windows 8.1?
Are you using a plain dash.js player?
Also which tutorial did you follow to generate the streams?
Romain
Hello Romain,
Answers below:
You're using PlayReady with CENC in dash.js. Are you using IE11 on Windows 8.1?
Yes.
Are you using a plain dash.js player?
Yes.
Also which tutorial did you follow to generate the streams?
I used settings that my colleague had tested and found to be working. I did not use any specific tutorial.
The settings worked in producing all other stream types except protected stream with multiple video quality levels so I assumed it goes under bug reports.
Kalle
The people from CableLabs seem to have procedures and tools for it:
https://html5.cablelabs.com/mse-eme/doc/creation.html
Is it the tutorial you followed? Otherwise you may want to contact us. Please let us know!
There is a typo in my previous message:
contact us => contact them (ie Cable Labs)
Hi!
I can reproduce the issue both with Kalle's media and another one that I made.
Actually, the main issue is that mp4box crashes when more than one video stream is specified. In other words, when providing "1 audio + 1 video" - mp4box successfully creates the media, but when providing "1 audio + 2 video" - mp4box crashes (see attached mp4box-multi-cenc-crash.png and mp4box-multi-cenc-crash.txt).
The interesting thing here is that mp4box crashes only while using the "dashavc264:live" profile. But, when I use the "dashavc264:onDemand" profile, mp4box successfully creates the media, and playback works as expected.
This issue is not related to CableLabs tools or the crypt.xml file that is used in order to encrypt media. In fact, CableLabs tools are simply generating crypt.xml files with correct protection information. In Kalle's case, the crypt.xml file is correct. By using his "1 video + 1 audio" version, we can see that dash.js successfully retrieves the PlayReady license, and playback works as expected.
The reason why I tried to create another media is that I noticed that something may be wrong with Kalle's clean media (encoding). mp4box, when encrypting his media, reports this: "[DASH]: Files have non-proportional track layouts (638x290 vs 854x388) but sample size and aspect ratio match, assuming precision issue" (I used the -v switch in order to get these details). So, I created my own media (you can get it here: http://1drv.ms/10CMeaF), and noticed that there's no such "warning" anymore. But, this didn't solve the main issue - mp4box still crashes.
So, everything points to the fact that something is wrong with mp4box, when it uses the "dashavc264:live" profile.
P.S. I was using "GPAC.Framework.Setup-0.5.1-DEV-rev5496-x64.exe".
Last edit: Vladimir Kazakov 2014-11-08
Hi Vladimir,
Try the newer version GPAC.Framework.Setup-0.5.1-DEV-rev5501, I can create your media successfully. My command is: MP4Box -dash 1000 -rap -sample-groups-traf -profile dashavc264:live -segment-name %s_ audio-cenc.m4a 360-cenc.mp4 720-cenc.mp4 -out dash\cenc.mpd
Hi Viet-Thanh-Trung,
I've tried your command, and it works! But mp4box (GPAC.Framework.Setup-0.5.1-DEV-rev5501-x64.exe) still crashes on commands that I was using. The only difference I noticed is the order of files. In your case it's "audio-cenc.m4a 360-cenc.mp4 720-cenc.mp4 -out dash\cenc.mpd". But when I do "360-cenc.mp4 720-cenc.mp4 audio-cenc.m4a -out dash\cenc.mpd", mp4box crashes. Does it also crash for you with this order?
But, anyway, "2 video + 1 audio" is not working for me in dash.js (Video Element Error: MEDIA_ERR_SRC_NOT_SUPPORTED).
Last edit: Vladimir Kazakov 2014-11-14
Hi,
This bug should be fixed in rev 5572
Hi!
I confirm that the issue was fixed in rev 5572. No more crashes of mp4box, and I've got a working PlayReady-protected multi-quality level media in dash.js 1.2.0, in IE 11 on Windows 8.1.
The command that I was using is:
CMD> mp4box.exe -dash 6000 -frag 6000 -rap -frag-rap -sample-groups-traf -profile dashavc264:live -segment-name %s- "X:\Media\360-cenc.mp4" "X:\Media\720-cenc.mp4" "X:\Media\audio-cenc.m4a" -out "X:\Media\CENC\sintel.mpd"
Viet-Thanh-Trung, thanks for fixing it!
Last edit: Vladimir Kazakov 2014-12-20