Thanks for reporting your issue. Please make sure these boxes are checked before submitting your issue - thank you!

- [X] I looked for a similar issue and couldn't find any.
- [X] I tried with the latest version of GPAC. Installers available at http://gpac.io/downloads/gpac-nightly-builds/
- [X] I give enough information for contributors to reproduce my issue (meaningful title, github labels, platform and compiler, command-line ...). I can share files anonymously with this dropbox: https://www.mediafire.com/filedrop/filedrop_hosted.php?drop=eec9e058a9486fe4e99c33021481d9e1826ca9dbc242a6cfaab0fe95da5e5d95

Detailed guidelines: http://gpac.io/2013/07/16/how-to-file-a-bug-properly/

Hi,

I tried the following command in order to use HLS protocol for making onDemand streaming:

`gpac -r -graph -stats -i video.mp4 -o http://localhost:8000/live.m3u8:gpac:hmode=push:profile=onDemand -no-h2`

I implemented a node.js server for storing all segments in a particular folder, but VLC Player and several web player using hls.js are not able to play the video. It looks like that the fragments are not created correctly. 
You can see the error showed in [hls.js Demo]( https://hlsjs.video-dev.org/demo/) in the attached images.

![HlsDemoErrors](https://user-images.githubusercontent.com/40350337/234860778-fe9d43f0-2c44-41b3-98b8-171594febff4.png)

In addition, I observed that m3u8 file was wrong since it shows that there are Indpendent Segments although the command require onDemand profile. 
According to [Apple HLS Specification](https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/video_on_demand_playlist_construction), the content of the m3u8 file should be:

`#EXTM3U

#EXT-X-PLAYLIST-TYPE:VOD

#EXT-X-TARGETDURATION:10

#EXT-X-VERSION:4

#EXT-X-MEDIA-SEQUENCE:0

#EXTINF:10.0,

http://example.com/movie1/fileSequenceA.ts
#EXTINF:10.0,

http://example.com/movie1/fileSequenceB.ts

#EXTINF:10.0,

http://example.com/movie1/fileSequenceC.ts

#EXTINF:9.0,

http://example.com/movie1/fileSequenceD.ts

#EXT-X-ENDLIST`

Instead the output generated by the command below is that one

`#EXTM3U
#EXT-X-VERSION:6
#EXT-X-INDEPENDENT-SEGMENTS

#EXT-X-STREAM-INF:BANDWIDTH=534662,CODECS="avc1.4D401F,mp4a.40.2",RESOLUTION=1280x720,FRAME-RATE=25,AUDIO="audio2"
live_1.m3u8

#EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="audio2",NAME="2",LANGUAGE="eng",AUTOSELECT=YES,URI="live_2.m3u8",CHANNELS="2"`

Is there something wrong in the command?

Software and Used System:

- Ubuntu 20.04
- Gpac 2.2
- Firefox 112.0.1



Dasher HLS doesn't play on client side
This is a GitHub Issue
repo:gpac
owner:gpac
Title : Dasher HLS doesn't play on client side
Issue date:

--- start body ---
Thanks for reporting your issue. Please make sure these boxes are checked before submitting your issue - thank you!

- [X] I looked for a similar issue and couldn't find any.
- [X] I tried with the latest version of GPAC. Installers available at http://gpac.io/downloads/gpac-nightly-builds/
- [X] I give enough information for contributors to reproduce my issue (meaningful title, github labels, platform and compiler, command-line ...). I can share files anonymously with this dropbox: https://www.mediafire.com/filedrop/filedrop_hosted.php?drop=eec9e058a9486fe4e99c33021481d9e1826ca9dbc242a6cfaab0fe95da5e5d95

Detailed guidelines: http://gpac.io/2013/07/16/how-to-file-a-bug-properly/

Hi,

I tried the following command in order to use HLS protocol for making onDemand streaming:

`gpac -r -graph -stats -i video.mp4 -o http://localhost:8000/live.m3u8:gpac:hmode=push:profile=onDemand -no-h2`

I implemented a node.js server for storing all segments in a particular folder, but VLC Player and several web player using hls.js are not able to play the video. It looks like that the fragments are not created correctly. 
You can see the error showed in [hls.js Demo]( https://hlsjs.video-dev.org/demo/) in the attached images.

![HlsDemoErrors](https://user-images.githubusercontent.com/40350337/234860778-fe9d43f0-2c44-41b3-98b8-171594febff4.png)

In addition, I observed that m3u8 file was wrong since it shows that there are Indpendent Segments although the command require onDemand profile. 
According to [Apple HLS Specification](https://developer.apple.com/documentation/http_live_streaming/example_playlists_for_http_live_streaming/video_on_demand_playlist_construction), the content of the m3u8 file should be:

`#EXTM3U

#EXT-X-PLAYLIST-TYPE:VOD

#EXT-X-TARGETDURATION:10

#EXT-X-VERSION:4

#EXT-X-MEDIA-SEQUENCE:0

#EXTINF:10.0,

http://example.com/movie1/fileSequenceA.ts
#EXTINF:10.0,

http://example.com/movie1/fileSequenceB.ts

#EXTINF:10.0,

http://example.com/movie1/fileSequenceC.ts

#EXTINF:9.0,

http://example.com/movie1/fileSequenceD.ts

#EXT-X-ENDLIST`

Instead the output generated by the command below is that one

`#EXTM3U
#EXT-X-VERSION:6
#EXT-X-INDEPENDENT-SEGMENTS

#EXT-X-STREAM-INF:BANDWIDTH=534662,CODECS="avc1.4D401F,mp4a.40.2",RESOLUTION=1280x720,FRAME-RATE=25,AUDIO="audio2"
live_1.m3u8

#EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="audio2",NAME="2",LANGUAGE="eng",AUTOSELECT=YES,URI="live_2.m3u8",CHANNELS="2"`

Is there something wrong in the command?

Software and Used System:

- Ubuntu 20.04
- Gpac 2.2
- Firefox 112.0.1



--- end body ---
