# I am trying to play selected parts of a vod file with adobe HDS ;

**URL:** <https://community.wowza.com/t/i-am-trying-to-play-selected-parts-of-a-vod-file-with-adobe-hds/48326>\
**Category:** Wowza Developer Dojo\
**Created:** [March 17, 2017, 9:37pm UTC](https://community.wowza.com/t/i-am-trying-to-play-selected-parts-of-a-vod-file-with-adobe-hds/48326 "2017-03-17T21:37:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gata\_selvagem](https://avatars.discourse-cdn.com/v4/letter/g/db5fbb/32.png) [@gata\_selvagem](https://community.wowza.com/u/gata_selvagem)\
**Post date:** [March 17, 2017, 9:37pm UTC](https://community.wowza.com/t/i-am-trying-to-play-selected-parts-of-a-vod-file-with-adobe-hds/48326/1 "2017-03-17T21:37:20Z")

</div>

```auto
however, the player only plays the second rendition of the medialist segment; I need help. For example: I would like to play the sample.mp4 file for 15 seconds starting from second 20 and second 200. connectUrl: http://[ip address]:1935/vod/amlst:sample.mp4/manifest.f4m

```

public class ModuleTest implements IMediaListProvider {

public MediaList resolveMediaList(IMediaListReader mediaListReader, IMediaStream stream, String streamName) { double duration = StreamUtils.getStreamLength(stream.getClient().getAppInstance(), streamName); duration = duration\*1000;

MediaList mediaList = new MediaList();

if( duration \>=300000) { MediaListSegment segment = new MediaListSegment(); mediaList.addSegment(segment);

MediaListRendition rendition1 = new MediaListRendition(); segment.addRendition(rendition1); rendition1.setName(streamName); rendition1.setBitrateAudio(128000); rendition1.setBitrateVideo(400000); rendition1.setWidth(320); rendition1.setHeight(240); rendition1.setPlayStart(20000); rendition1.setPlayDuration(15000); rendition1.setAudioCodecId(“mp4a.40.2”); rendition1.setVideoCodecId(“avc1.66.12”); // second rendition MediaListRendition rendition2 = new MediaListRendition(); segment.addRendition(rendition2);

rendition2.setName(streamName); rendition2.setBitrateAudio(128000); rendition2.setBitrateVideo(400000); rendition2.setWidth(320); rendition2.setHeight(240); rendition2.setPlayStart(200000); rendition2.setPlayDuration(15000); rendition2.setAudioCodecId(“mp4a.40.2”); rendition2.setVideoCodecId(“avc1.66.12”); }

return mediaList;

} }

---

<div class="post-metadata">

**Author:** ![Roger\_Littin1](https://avatars.discourse-cdn.com/v4/letter/r/c89c15/32.png) [@Roger\_Littin1](https://community.wowza.com/u/Roger_Littin1)\
**Post date:** [March 24, 2017, 2:27am UTC](https://community.wowza.com/t/i-am-trying-to-play-selected-parts-of-a-vod-file-with-adobe-hds/48326/2 "2017-03-24T02:27:27Z")

</div>

Hi,

the MediaList API is used to create a list of alternative bitrate renditions of the same content. It isn’t designed for creating a playlist of separate pieces of content.

There currently isn’t a way to do this server side so the only option is to do it player side by calling each rendition as separate URLs and using different wowzaplaystart and wowzaplayduration parameters for each one.

---

<div class="post-metadata">

**Author:** ![gata\_selvagem](https://avatars.discourse-cdn.com/v4/letter/g/db5fbb/32.png) [@gata\_selvagem](https://community.wowza.com/u/gata_selvagem)\
**Post date:** [May 5, 2017, 6:10pm UTC](https://community.wowza.com/t/i-am-trying-to-play-selected-parts-of-a-vod-file-with-adobe-hds/48326/3 "2017-05-05T18:10:13Z")

</div>

Thank you @Roger Littin for replying. I actually ended up with a similar solution 3 days after I posted the question.
