I’m trying to build an AMLST code that serve both mpeg-dash and HLS with multi-audio tracks on audio only files and ABR with video only files, and I have two problems:
-
The HLS output can detect the multiple audio files and videos, but it creates a muted default track, and starts playing muted.
-
The mpeg-dash output have the two video formats, but no audio.
The code I’m using:
MediaList mediaList = new MediaList();
MediaListSegment segment = new MediaListSegment();
mediaList.addSegment(segment);
MediaListRendition rendition1 = new MediaListRendition();
segment.addRendition(rendition1);
rendition1.setName("mp4:extracted_audio.mp4");
rendition1.setType(IVHost.CONTENTTYPE_AUDIO);
rendition1.setWowzaAudioOnly(true);
rendition1.setBitrateAudio(119000);
rendition1.setTitle("AMLST Espanhol");
rendition1.setLanguage("spa");
rendition1.setAudioCodecId("mp4a.40.2");
WMSProperties properties1 = rendition1.getProperties(true);
properties1.setProperty("cupertinoTag", "EXT-X-MEDIA");
properties1.setProperty("cupertinoTag.GROUP-ID", "aac");
properties1.setProperty("cupertinoTag.DEFAULT", "YES");
MediaListRendition rendition2 = new MediaListRendition();
segment.addRendition(rendition2);
rendition2.setName("mp4:audio_commentary.mp4");
rendition2.setType(IVHost.CONTENTTYPE_AUDIO);
rendition2.setWowzaAudioOnly(true);
rendition2.setBitrateAudio(119000);
rendition2.setTitle("AMLST Commentary");
rendition2.setLanguage("eng");
rendition1.setAudioCodecId("mp4a.40.2");
WMSProperties properties2 = rendition2.getProperties(true);
properties2.setProperty("cupertinoTag", "EXT-X-MEDIA");
properties2.setProperty("cupertinoTag.GROUP-ID", "aac");
properties2.setProperty("cupertinoTag.DEFAULT", "NO");
MediaListRendition rendition3 = new MediaListRendition();
segment.addRendition(rendition3);
rendition3.setType(IVHost.CONTENTTYPE_VIDEO);
rendition3.setWowzaVideoOnly(true);
rendition3.setName("mp4:extracted_video_160p.mp4");
rendition3.setBitrateAudio(119000);
rendition3.setBitrateVideo(150000);
rendition3.setWidth(284);
rendition3.setHeight(160);
rendition3.setAudioCodecId("mp4a.40.2");
rendition3.setVideoCodecId("avc1.100.30");
WMSProperties properties3 = rendition3.getProperties(true);
properties3.setProperty("cupertinoTag.AUDIO", "aac");
MediaListRendition rendition4 = new MediaListRendition();
segment.addRendition(rendition4);
rendition4.setType(IVHost.CONTENTTYPE_VIDEO);
rendition4.setWowzaVideoOnly(true);
rendition4.setName("mp4:extracted_video_252p.mp4");
rendition4.setBitrateAudio(119000);
rendition4.setBitrateVideo(306863);
rendition4.setWidth(448);
rendition4.setHeight(252);
rendition4.setAudioCodecId("mp4a.40.2");
rendition4.setVideoCodecId("avc1.100.30");
WMSProperties properties4 = rendition4.getProperties(true);
properties4.setProperty("cupertinoTag.AUDIO", "aac");
The first two renditions are just audio tracks, and the least two videos without audio.