[Transcoder settings] Adding overlay image to the original stream

Hi everybody,

I am pretty new to Wowza Streaming engine, just started using it for couple of weeks. So I have some questions below, hope some of you can help me to figure it out.

  • To add an overlay image, I have to create the transcoder and let the stream go through that transcoder, however I want to keep the original video format (audio can be disabled). But when I tried to let the video settings as passthrough, the output stream (test.stream_720p for example) didn’t show the overlay image. And can I discard the wowza overlay image as well ?

  • Can I add the overlay image into the stream but still keep the same name of the stream (e.g. just test.stream instead of test.stream_720p) ?

  • If I have to use/touch the server-side API, how can I do that, I saw many tutorials about adding some codes and modules but I just wondered how to get that work. I tried looking in the documentation folder but it seems there are just html files. (updated: I’ve figured it out how to create a simple Wowza module after installling WowzaIDE, just begin to test simple things :slight_smile: )

Thank you and have a good day.

AD

Hi there, first, you can not remove the Wowza logo when running a trial license.

You have to have a different name for the transcoded rendition of the stream, and only the rendition will have the overlay. Make sure you are playing back the transcoded rendition to see the overlay.

With that said, you can use the StreamNameAlias AddOn to play “myStream” and have it resolve to “myStream_rendition”:

How to get the StreamNameAlias AddOn

Salvadore

If the source for a Transcoder application is named “myStream”, the transcoded renditions, myStream_160p for example, will have the overlay if that is configured and if using H264 not PassThru, as mentioned.

If you playback myStream, you will be playing the source, and that will not have the overlay. I tried to use StreamNameAlias to alias a stream in the aliasmap.stream.txt to start, and aliasmap.play.txt for playback, but it doesn’t work. The only way to use the same stream name is use another application, pull from the first app with live repeater and StreamNameAlias to map myStream to the origin stream.

Richard

Hi,

The reason it doesn’t work as expected is because the mechanism used to start the remote stream reads the play alias first to get the stream name that it then passes into the stream alias part. If you remap the name in aliasmap.play.txt, it will try to start the wrong stream name.

The easiest way would be to use a different name for playback and alias that to the name used to start the stream originally.

Example:

original stream name is myStream. This is the remote stream (ip camera for example)

transcoded stream name is myStream_360p. this has the overlay.

playback stream name is stream1. this will be mapped to myStream_360p

In aliasmap.play.txt:

stream1=myStream_360p
*=${Stream.Name}

The first line will map the player request for stream1 to myStream_360p.

the second line will pass thru any other stream name unchanged. This will include any direct requests for myStream_360p or the request to start the remote source.

Because you cannot use .stream files to start your remote source, you need the following in your aliasmap.stream.txt file.

myStream=[ip camera url]

To start the remote stream, use Startup Streams and use myStream and the mediacaster name. You can also use the old stream manager on http://[wowza-ip]:8086/streammanager to start it manually. Either way will have the stream show up in the list of published streams for the application.

Roger.

Hi Richard and Roger,

Thank you for your support. Due to some pre-defined constraints, in which the stream format should be XXX.YYY.stream, so I just move the “720p” part to the top of the stream name. I think I won’t use the alias name because I have also need the real stream name to do with some HTTP Providers. I will try the alias some other days.

Many thanks.

AD

Hi,

You can use XXX.YYY.stream as the names with the aliasing plugin. You just cannot use the actual stream files.

test.stream=[contents of original steam file] in aliasmap.stream.txt will work exactly like a stream file.

The point I was trying to get across is that you cannot map a stream name to some other name in aliasmap.play.txt and then use the same original name in aliasmap.stream.txt. You need to have different names on the left side of the = for each file.

If you need to do anything more complicated then you will need to create a module that implements the IMediaStreamNameAliasProvider2 interface.

When a mediaCaster is started, it first reads the play alias and uses the name returned from that to input into the stream alias. That must return the url for the remote stream.

If you have the wildcard entry in the play alias, you can always access the streams by their original names.

Roger.

Sorry I missed these 2 details in your first post, looking back I see you had included them in your original post.

First, when using PassThru you will not have access to the Overlay feature.

Second, you can’t use .stream files as the source for the StreamNameAlias AddOn, at least this is my understanding.

I will be thinking of a solution. In the mean time, keep working on it and maybe someone from support will step in with more information.

Salvadore

Hi Salvadore,

Thank you for your quick response, I will try it out and let you know soon.

Regards,

AD

Hi there, first, you can not remove the Wowza logo when running a trial license.

You have to have a different name for the transcoded rendition of the stream, and only the rendition will have the overlay. Make sure you are playing back the transcoded rendition to see the overlay.

With that said, you can use the StreamNameAlias AddOn to play “myStream” and have it resolve to “myStream_rendition”:

How to get the StreamNameAlias AddOn

Salvadore

Hi there, first, you can not remove the Wowza logo when running a trial license.

You have to have a different name for the transcoded rendition of the stream, and only the rendition will have the overlay. Make sure you are playing back the transcoded rendition to see the overlay.

With that said, you can use the StreamNameAlias AddOn to play “myStream” and have it resolve to “myStream_rendition”:

How to get the StreamNameAlias AddOn

Salvadore

Hi Salvadore,

I tried with the StreamNameAlias, but I don’t really get the idea of creating alias from the stream. Currently I have 1 “original” stream, the URL to connect is: rtsp://198.xxx.xxx.xxx:1935/live/test.stream, and another transcoded stream with URL: rtsp://198.xxx.xxx.xxx:1935/live/test.stream_360p (with the 360p template settings). So the idea you suggested me is that every time a client connects to rtsp://198.xxx.xxx.xxx:1935/live/test.stream, they will be redirect to rtsp://198.xxx.xxx.xxx:1935/live/test.stream_360p ?

If so, I have problem at the initial step, when I successfully added the StreamNameAlias module (by using the web UI), after a restart, when I try to add stream files, it said: "Stream alias access denied test.stream. " I currently don’t know which does it come from. I let the play.txt and stream.txt as default: *.stream=mp4:${Stream.Name}

And one more thing, I tried transcode with the passthrough setting for video and disable audio, but the overlay images (both custom and wowza images) didn’t appear, so I have to specify the video format to use the overlay ? Actually all I want is the overlay, not to transcode or change the image format.

Thanks a lot!

AD

Sorry I missed these 2 details in your first post, looking back I see you had included them in your original post.

First, when using PassThru you will not have access to the Overlay feature.

Second, you can’t use .stream files as the source for the StreamNameAlias AddOn, at least this is my understanding.

I will be thinking of a solution. In the mean time, keep working on it and maybe someone from support will step in with more information.

Salvadore

Hi Salvadore,

thank you for your help. So in order to have the overlay images, I have to use the video settings instead of let the PassThru. But with different cameras source quality, is it possible to modify the settings of the video settings differently ?

Now I have only 1 transcoded stream, is it because of the trial version ?

If the source for a Transcoder application is named “myStream”, the transcoded renditions, myStream_160p for example, will have the overlay if that is configured and if using H264 not PassThru, as mentioned.

If you playback myStream, you will be playing the source, and that will not have the overlay. I tried to use StreamNameAlias to alias a stream in the aliasmap.stream.txt to start, and aliasmap.play.txt for playback, but it doesn’t work. The only way to use the same stream name is use another application, pull from the first app with live repeater and StreamNameAlias to map myStream to the origin stream.

Richard

Hi,

The reason it doesn’t work as expected is because the mechanism used to start the remote stream reads the play alias first to get the stream name that it then passes into the stream alias part. If you remap the name in aliasmap.play.txt, it will try to start the wrong stream name.

The easiest way would be to use a different name for playback and alias that to the name used to start the stream originally.

Example:

original stream name is myStream. This is the remote stream (ip camera for example)

transcoded stream name is myStream_360p. this has the overlay.

playback stream name is stream1. this will be mapped to myStream_360p

In aliasmap.play.txt:

stream1=myStream_360p
*=${Stream.Name}

The first line will map the player request for stream1 to myStream_360p.

the second line will pass thru any other stream name unchanged. This will include any direct requests for myStream_360p or the request to start the remote source.

Because you cannot use .stream files to start your remote source, you need the following in your aliasmap.stream.txt file.

myStream=[ip camera url]

To start the remote stream, use Startup Streams and use myStream and the mediacaster name. You can also use the old stream manager on http://[wowza-ip]:8086/streammanager to start it manually. Either way will have the stream show up in the list of published streams for the application.

Roger.

Hi Richard and Roger,

Thank you for your support. Due to some pre-defined constraints, in which the stream format should be XXX.YYY.stream, so I just move the “720p” part to the top of the stream name. I think I won’t use the alias name because I have also need the real stream name to do with some HTTP Providers. I will try the alias some other days.

Many thanks.

AD