Results 1 to 3 of 3

Thread: Switch to smil playlist when live cut off or stops

  1. #1
    Join Date
    Jan 2013
    Posts
    14

    Default Switch to smil playlist when live cut off or stops

    Hi, i am trying to write a handler incase the live stream stops or cuts off.

    i am not sure if i should create a listener on the client or server side module

    I already have a working scheduler that starts off playing the smil file and switches when the live come back on but i can't seem to get it to switch back to the smil file when the live stops.

    I get the error "Failed to play myStream; stream not found." and then i would have to restart wowza to get the smil file to work again.

    I presume i put a handler on the onUnpublish to help switch me pack to the playlist smil but i have not managed to achieve this

    public void onUnPublish(IMediaStream stream, String streamName, boolean isRecord, boolean isAppend)
    		{
    			getLogger().info("onUNPublish");
    			Stream streams = (Stream)stream.getProperties().getProperty(streamName);
    			String name = streams.getCurrentItem().getName();
                streams.getPublisher().getAppInstance().broadcastMsg("PlaylistItemStart", name);
    
    
    		}
    I have search all over the forum but i am new to wowza ide and i don't seem to understand it

    Thank you

  2. #2
    Join Date
    Jan 2013
    Posts
    14

    Default

    Please any help for this problem. I can switch from smil to live but i dont know how to switch back when Adobe flash media Live encoder stops. after that i i get the error on the rtmp player page

  3. #3
    Join Date
    Dec 2007
    Posts
    21,962

    Default

    I posted in your other thread:

    http://www.wowza.com/forums/showthre...tify2/page2#15

    Use that with the Scheduler and LoopUntilLive example.

    public void onUnPublish(IMediaStream stream, String streamName, boolean isRecord, boolean isAppend)
    {
    	Stream outStream = (Stream)stream.getClient().getAppInstance().getProperties().getProperty(outStreamName);
    	getLogger().info("CurrentListItemName: " + CurrentListItemName);
    	outStream.play(CurrentListItemName,0,-1,true);
    }
    Richard

Similar Threads

  1. HOWTO: stream from playlist with automatic switch to live and back?
    By thosmos in forum Live Streaming and Encoders
    Replies: 1
    Last Post: 03-09-2014, 06:23 AM
  2. Replies: 3
    Last Post: 09-01-2013, 10:03 PM
  3. Switch between 24/7 playlist and live stream
    By hundstage in forum Server-side Modules and Code Samples Discussion
    Replies: 6
    Last Post: 07-17-2012, 05:49 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •