Wowza Community

streaming a video file while recording

Hi Richard,

Thanks for the response, but these examples seem to be about streaming a portion of a VOD file like an mp4 file.

However the problem is that I don’t have a VOD file. What I have is the files created by the nDVR module: namely a number of .ismm and .ismv files.

And for example they are for the period of past 5 days and I want to create an mp4 file that covers only the day before. This is what I need to do.

If I already had an mp4 file I could have used a tool similar to ffmpeg and cut the video according to my needs.

But this is not the case as the nDVR module is creating files with a different format.

Thanks.

Live + live stream record: clients can watch video while it is being recorded but only at the live point. No seeking back and forward in time. Have a VOD recording when finished.

Live + nDVR: clients can watch video while recorded and can seek.

Live + nDVR + live stream record. Same as above except once the stream is finished, live stream record creates a single VOD file that can be played back. nDVR creates a recording too that can be played back but its not a single file recording.

Hopefully this is my last question about this topic.

You mentioned that LiveStreamRecord module will create a single VOD file “”“when the stream is finished”"".

Can we control this LiveStreamRecord module so that it creates a VOD file whenever we want while nDVR continues to do streaming+recording?

For example if I don’t want to stop the stream but just want to get the recorded video until now…

Somewhat like start-recording and stop-recording functionality of LiveStreamRecord module.

I checked it’s source code and it looks like it is supported but I would like have this confirmed.

Also when LiveStreamRecord is added as a module on top of the dvr application to achieve the above goal; is LiveStreamRecord module going to connect to the stream source (i.e. the camera) to do the recording or is it going to simply use the stream served by the nDVR application? This is to make sure that the upload bandwidth of the camera is not utilized twice.

Thanks.

One more bit of info.

There is a full Java API underneath the HTTP Provider that can be utilized if need be.

So for example, I think the provided HTTP Provider would not allow your recordings to overlap. However, if you use the underlying API (same one that HTTPProvider uses), you could have recordings that overlap.

Scott

Hi Scott,

Thank you for all the information.

However, I need a little more detail about this last bit of information.

Actually, rather conveniently, you touched a point which I was already going to ask about.

First of all, I am planning to write up a Wowza Module of my own which calls the methods provided by the LiveStreamRecord module (e.g. startRecording, stopRecording).

So I am not planning to use the HTTP Provider if I can implement the above module. Please let me know if you see any problems with this approach.

As for overlapping recordings of “”“the same stream”""; this was the question in my mind because it is quite an important aspect as per my requirements.

And I understand that it is possible to create overlapping recordings of the same stream via the LiveStreamRecord module by using the Java API, which is the approach I am planning to take.

Could you please confirm this?

On the other hand, my code review suggests otherwise: I checked the Java source code (ModuleLiveStreamRecord.java and HTTPLiveStreamRecord.java) and it looks like the previous recording of the “”“same stream”"" will be stopped if another one is starting. Below piece of code is taken from ModuleLiveStreamRecord.java:

// add it to the recorders list
synchronized (recorders)
{
	ILiveStreamRecord prevRecorder = recorders.get(streamName);
	if (prevRecorder != null)
		prevRecorder.stopRecording();
	recorders.put(streamName, recorder);
}

Could you please clarify the above for me?

If I am wrong at any point, I would like to know how I can go about having overlapping recordings (VOD files) of the same stream.

Currently I am planning to use nDVR for continuous recording of a stream.

Then there will also be the LiveStreamRecord module in charge to create VOD files of the same stream at pre-determined time periods, “”“which can overlap”"".

Thanks.

OK, got it. I thought you were referring to the Java code of the module itself.

Thanks a lot for the information.

Hey Scott,

Do you have any example of how to do overlapping recordings with the HTTPProvider?

–Joe.