AXIS H264 to Flash

Hi all,

I’m a newbie into streaming software, and I’m trying to stream an AXIS H264 via HTTP (flash), using a mediaplayer to avoid to have too many clients connected directly to the AXIS IP.

What I first tested is this configuration of conf/rtplive/Application.xml:

sortPackets

True

Boolean

sortBufferSize

500

Integer

and, on the wowza flash player I’m using these links:

Server: rtmp://192.168.0.251/rtplive

Stream: rtsp://192.168.0.104/axis-media/media.amp

192.168.0.104 is the AXIS IP

192.168.0.251 is the WOWZA IP

I did nothing more, and everything works, both video and audio!

Now, I’m trying to insert the flash file into a webpage.

Is it possible to insert the “Server” and “Stream” parameters directly into the webpage?

Or, if it’s not possible, how can I use FLOWPLAYER?

I think wowza should convert rtsp to rtmp, and I should get rtmp from wowza: how can I make such a conversion on wowza?

Thanks!

Flowplayer will work. You use the rtmp or Wowza plugin. The Server is the rtmp plugin netConnectionURL, and the Stream is the Clip Url

See this post:

http://community.wowza.com/t/-/40

Richard

You might have to use StreamNameAlias so you can use a simple name in the player instead of the rtsp url:

http://community.wowza.com/t/-/47

But I’m not sure if it’s necessary, in JW player it is not necessary.

What about the version numbers of the player and plugin? They are different, one is 3.1.5 the other is 3.1.3. I’m not sure if that matters either, but it might.

Richard

Regarding the alias file, you must put the default rule last. The first match is always used, so rules below the default rule will never be read.

MyStream=rtsp://192.168.0.104/axis-media/media.amp

MyServer=rtmp://192.168.0.251/rtplive2

*=${Stream.Name}

But with JW player I know it’s not necessary to use an alias with rtsp stream, so it seems like it is another problem.

Be careful not to break this other ways while try to work this out, maybe we should start from the top. I would comment out the StreamNameAlias module for the moment.

I’m using axis camera. I followed this guide to setting up the application:

http://community.wowza.com/t/-/53

Have you tried with the Wowza example player, SimpleVideoStreaming?

Richard

Great, if that works then it is setup correctly. To get it working in JW player now, try this:

s1.addParam(“flashvars”,“fullscreen=true&bufferlength=2&streamer=rtmp://192.168.0.251/rtplive&file=rtsp://192.168.0.104/axis-media/media.amp&type=rtmp”);

Richard

It’s a javascript problem at this point. Either there is something wrong with the swfobject.js or the src of the script tag is wrong and it is not loading, or you have javascript turned off.

Richard

Clients that connect to a Wowza app are connecting directly to the web cam.

Richard

I forgot to put “not”. Clients that connect to Wowza are not connecting directly to a webcam. They are connecting to Wowza which sends a copy of the stream to the client.

Sorry, “not” was the keyword there.

Richard

I yet made this test, but maybe there’s something wrong on what I’m doing.

I used:

flowplayer(“player”, “flowplayer-3.1.5.swf”,

{

clip: {

url: ‘rtsp://192.168.0.104/axis-media/media.amp’,

live: true,

provider: ‘rtmp’

},

plugins: {

rtmp: {

url: ‘flowplayer.rtmp-3.1.3.swf’,

netConnectionUrl: ‘rtmp://192.168.0.251/rtplive’

}

}

But this doesn’t work… do you know why?


This is the output of wowza when I access to flowplayer:

INFO application app-start definst rtplive/definst

INFO session connect-pending 192.168.0.66 -

INFO session connect 192.168.0.66 -

INFO stream create - -

INFO server comment - MediaStreamMediaCasterPlay: startPlay

INFO server comment - RTPMediaCaster.create

INFO server comment - RTPMediaCaster.init

INFO server comment - RTPMediaCaster.Reconnector: start

INFO server comment - RTPSessionDescriptionDataProviderBasic.getStreamInfo: /usr/local/WowzaMediaServerPro/content/media.amp

WARN server comment - RTPSessionDescriptionDataProviderBasic.getStreamInfo: SDP file missing: /usr/local/WowzaMediaServerPro/content/media.amp

Yes, that’s because I found only flowplayer.rtmp-3.1.3.swf rtmp plugin, and not 3.1.5. Now I’m not where I have this testing server, tomorrow I’ll try with StreamNameAlias.

Now I checked on flowplayer site:

http://flowplayer.org/plugins/streaming/rtmp.html

They are using 3.1.5 and rtmp-3.1.3.swf, so I think/hope this is correct.

It seems not to work even with StreamNameAlias.

I’m using this flowplayer conf:

flowplayer(“player”, “flowplayer-3.1.5.swf”,

{

clip: {

url: ‘MyStream’,

live: true,

provider: ‘rtmp’

},

plugins: {

rtmp: {

url: ‘flowplayer.rtmp-3.1.3.swf’,

netConnectionUrl: ‘rtmp://192.168.0.251/rtplive2’

}

}

}

and this is my StreamNameAliasMap.txt:

*=${Stream.Name}

MyStream=rtsp://192.168.0.104/axis-media/media.amp

That’s the output of Wowza:

INFO server comment - ModuleStreamNameAlias.onAppStart: streamNameAliasFile: /usr/local/WowzaMediaServerPro/conf/StreamNameAliasMap.txt

INFO application app-start definst rtplive2/definst

INFO session connect-pending 192.168.0.66 -

INFO session connect 192.168.0.66 -

INFO stream create - -

INFO server comment - ModuleStreamNameAlias.streamNameToAlias: streamName:MyStream alias:{pattern: “*” alias:"${Stream.Name}" wildcardMatches:{[0]: “MyStream”}} result:MyStream

INFO server comment - ModuleStreamNameAlias.play: MyStream=MyStream

INFO server comment - MediaStreamMediaCasterPlay: startPlay

INFO server comment - RTPMediaCaster.create

INFO server comment - RTPMediaCaster.init

INFO server comment - RTPMediaCaster.Reconnector: start

INFO server comment - RTPSessionDescriptionDataProviderBasic.getStreamInfo: /usr/local/WowzaMediaServerPro/content/MyStream

WARN server comment - RTPSessionDescriptionDataProviderBasic.getStreamInfo: SDP file missing: /usr/local/WowzaMediaServerPro/content/MyStream

Any hint?

Same thing with JWPlayer.

StreamNameAliasMap.txt:

*=${Stream.Name}

MyStream=rtsp://192.168.0.104/axis-media/media.amp

MyServer=rtmp://192.168.0.251/rtplive2

JWPlayer:

or:

This time no output from wowza!

I think I’m forgetting something, but don’t understand what :confused:

2 questions:

  1. I tried wowza flash player with rtplive application. Is it correct to use this even with flowplayer and jwplayer?

  2. What does it mean the error:

RTPSessionDescriptionDataProviderBasic.getStreamIn fo: SDP file missing: /usr/local/WowzaMediaServerPro/content/MyStream ?

Should I create the SDP file? How should I do it?

Thanks!

Have you tried with the Wowza example player, SimpleVideoStreaming?

Richard

I tried with the How to setup a live streaming application guide on https://www.wowza.com/quickstart.html

And it works with these parameters:

Server: rtmp://192.168.0.251/rtplive

Stream: rtsp://192.168.0.104/axis-media/media.amp

Should I try even with simplevideostreaming?

Thanks for help… I can’t get out of this :eek:

This is my HTML page:

Testing JWPlayer

These are the files into the directory:

index.html, player.swf, swfobject.js

The page I open has only the “Testing JWPlayer” text and the rest is blank. It does not even open the player and no output from wowza.

If I make the same thing with flowplayer I have the player but the stream does not start.

Got it working with flowplayer using the alias MyStream as rtsp://…

nothing with jwplayer…

After a lot of tests on both linux and windows server I’m a little happier now!

I’ll go saving this configuration for now :smiley:

It seems that even watching the webcam through flowplayer, the client PC connects to the webcam to reach the stream (port 80 and 1935).

Is it possible to get everything by the wowza server (wowza and webserver are on the same hardware).

What I want is clients not to be directly connected to the webcam.

Thanks!

And do you know a way to avoid this?

Using other softwars?

VLC between webcam and wowza could permit me doing this thing?

I should have a webcam on private network, visible by the server, but the server on public network. So, obviously users can’t see the private IP of the webcam.

Uhm… maybe I’m starting to understand my problem:

it’s not working on public IP cause of the client trying to connect to the webcam, but because I was doing a NAT from a public IP to the private IP of the server.

I think the server needs to have a public IP, or to NAT both ports 80 and 1935.

I’ll make some more tests on this…

Thanks!