Giter Site home page Giter Site logo

Comments (12)

erankor avatar erankor commented on June 8, 2024

Yes, it's possible, you need to use mapped mode with a JSON like -

{
	"playlistType": "live",
	"discontinuity": true,
	"firstClipTime": 1451918170000,
	"durations": [1800000],
	"sequences": [
		{
			"clips": [
				{
					"type": "source",
					"path": "/path/to/video1.mp4"
				}
			]
		}
	]
}

You need to set firstClipTime to the broadcast start time, in unix-time millis. If the stream is loaded outside the broadcast time, it will return an error. So it may be a good idea to stitch some slate before + after the main video, either by including them in the JSON, or by concatenating them to the source MP4.
Regarding the ability to rewind, you can use vod_live_window_duration to the control the number of seconds of video returned in the manifest. Note that it is not recommended to set this value below 3 segments.

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

Okay thank you, and what about discontinuty why should I enable it?

from nginx-vod-module.

erankor avatar erankor commented on June 8, 2024

With one video, it's irrelevant, doesn't matter what you put there...
If you embed a slate before/after the video, you will most likely need to set it to true, unless you take extra care to ensure the videos have identical SPS/PPS.

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

And what about presentationEndTime or expiredTime? Should I used them? I tried presentationEndTime and the video continued after specified time

from nginx-vod-module.

erankor avatar erankor commented on June 8, 2024

These params provide more fine grained control, intended mostly for "real" live streams. presentationEndTime controls whether the module returns EXT-X-ENDLIST, expirationTime can be used to make the module return 404 after a certain time.
I don't think you need them here, as far as I remember, the module will return an error, when the clock moves out of the window defined in the JSON.

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

Super thank you so much, also I am able to use multibitrate stream right?

from nginx-vod-module.

erankor avatar erankor commented on June 8, 2024

Yup, you just need to add more elements to the sequences array

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

I tried and getting error: ngx_http_vod_validate_streams: invalid sequence count 3 while sending to client

from nginx-vod-module.

erankor avatar erankor commented on June 8, 2024

Are you requesting index.m3u8?
You can't request index.m3u8 when there are multiple sequences, you need to use master.m3u8

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

Yes i am requesting master.m3u8

from nginx-vod-module.

kisso avatar kisso commented on June 8, 2024

I have another problem, when I use only one sequence and requesting master.m3u8 I am getting whole video which I can rewind, when I request on index.m3u8 I am getting livestream is this correct behavior? Anybody can change url from index to master and see whole video, I don't want this

from nginx-vod-module.

erankor avatar erankor commented on June 8, 2024

this doesn't make sense... the master.m3u8 references the index.m3u8 internally, there should be no difference between the two. maybe you have some caching issue.

from nginx-vod-module.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.