Page 1 of 1
Ogg Theora streaming
Posted: Fri Dec 02, 2005 4:59 pm
by SyRenity
Hi Phil.
In this thread, you mentioned that it's possible to stream the video in the Ogg Theora codec, rather then in MPEG4:
http://www.zoneminder.com/forums/viewto ... ght=theora
This came as a possible resolution to the delay present in the Windows Media Player. I checked around, and there is a good variety of Java/Activex Theora browser player plugins available.
It can be a good replace for the WMP, similar to the MediaFrame, but using another codec, which should give a better bandwidth/quality ratio, and resolve the lag issue.
Could you please list the instructions needed to set ZM to work with Theora?
Thanks.
Posted: Fri Dec 02, 2005 5:40 pm
by jameswilson
I have been looking ito ffmpeg a bit lately and im not sure they have finished this streaming type so it might need a bit of coaxing. I would assume that you change the asf extension in setting to whatever the ogg one is.
Posted: Mon Dec 05, 2005 7:22 pm
by zoneminder
I've not actually got live streaming working, as I don't have a player that seems to be easy to use. I did get some videos produced in ogg format though. You have to compile ffmpeg with additional options though as I recall.
Phil
Posted: Mon Dec 05, 2005 9:40 pm
by cordel
You do have to compile ffmpeg with extra options to support ogg. FYI the packages I have for both distros have it compiled in. I also reduced the dependancies for the x86_64 package by not compiling in some of the decoders since the conversion for now is only from jpeg. I also made sure that any packages that are normaly in a FC install (ogg, vorbis, etc.) were compiled in.
Posted: Mon Dec 05, 2005 9:45 pm
by zoneminder
Judging from the excitement on the swf thread it seems that perhaps the easiest solution to live streaming is via flash anyway now. It look easier to set up than ogg anyway.
Phil
Posted: Mon Dec 05, 2005 9:57 pm
by cordel
Oh, I agree and will be watching that thread closely till I have an opertunity to get in and play. But is it not useing ffmpeg to encode mpeg4?
I have just one issue stopping the x86_64 distro right now were Grub is not loading correctly once I get beyond that and finnish up the new code for zminit the release will follow and I can move on and play a bit.
Posted: Tue Dec 06, 2005 8:44 am
by SyRenity
Hi.
The Flash method is great, and allows new possibilities for the ZM, but it's still has it's problems, the main one is the large memory footprint. Also, the quality due to Flash Spark (H.263) compression is somewhat lower and quite blocky (which is especially visible on movements). This may change when the FFMPEG team implements Flash8 On2 VP6 codec, but until then...
.
Therefore, I still like to review other options, thus the Theora codec looks as a very promising alternative to WMP.
I will try Cordel's RMP's, and my main question is which format that should be set in the ZM options? OGG?
Posted: Tue Dec 06, 2005 9:47 am
by zoneminder
I would guess so, I can't actually remember. If ogg works on the command line with ffmpeg then that is what you will need to pass into ZM. In fact it's probably easier to do you experimenting directly with ffmpeg first and then just transfer the parameters.
Phil
Posted: Sun Jan 08, 2006 2:37 pm
by SyRenity
Hi.
I tried to compile the Theora support in the current version of ZM (1.21.4). FFMPEG compilation stage went fine, but unfortunately, I can't compile ZM, as it can't find the libtheora-devel library. (All the functions, like theora_init() can not be located).
The question is, if there any way to compile current ZM with Theora? Or only the latest 1.22 supports it via "extra libs"?
Posted: Sun Jan 08, 2006 9:01 pm
by SyRenity
Hi.
Phil, this one goes to you for sure
.
I managed to compile the zms via external IDE. Unfotunately, when setting OGG as the output format, it segfaults. When stepping with a debugger, I noticed that guess_format() (located in zm_mpeg.cpp), fills the "of" structure with Vorbis audio settings only. Meaning, the of->mime_type has "audio/x-vorbis" set, and the of->video_codec equals to CODEC_ID_NONE.
Apparently, FFMPEG can't correctly guess that Theora video codec is used from the "ogg" extension? Or perhaps a diffrent extension should specify after all.
BTW, the command line FFMPEG is not working with Theora as well. It returns me the following message: "No audio or video streams available".
The only software that allowed me to encode into ogg, was ffmpeg2theora (
www.v2v.cc/~j/ffmpeg2theora/). I checked the source code, and it seems it doesn't use the guess_format() function at all.
Perhaps the Theora support in CVS version of FFMPEG is broken?
Posted: Mon Jan 09, 2006 5:48 pm
by zoneminder
I think you have to build ffmpeg with additional options to use Theora. In 1.22.0 you will need to supply any additional libraries to configure when you build ZM, in earlier versions unfortauntely you will need to add them to the Makefile manually. I've not done a lot with ogg files other than seeing if I could generate them, which I could. However I couldn't find a player to view them on at the time
1.22.0 allso makes it a lot easier to manage mime types by the way.
Posted: Tue Jan 10, 2006 9:59 am
by SyRenity
Hi.
Do you remember, perhaps, which options to include with Theora? The FFMPEG building requires the OGG format (--with-libogg) to be specified if Theora is used, but other then that, there is nothing more required.
Posted: Wed Jan 11, 2006 2:30 pm
by zoneminder
Unfortunately not. Also my dev box went up in smoke at the weekend so I can't even check what I had installed on it. Sorry
Posted: Wed Jan 11, 2006 7:28 pm
by SyRenity
Hi.
Thanks anyway - I will try to find the right setup, and will post my results here.