Results 1 to 3 of 3

Thread: call onStreamCreate only once

  1. Default call onStreamCreate only once

    Hi! I noticed that the IModuleOnStream.onStreamCreate gets called not only when the stream is created (i.e. when I push start in FMLE), but also each time a client connects to the stream. But I want a method or trigger that runs only once when the stream is published on the server, not when clients connect.

    My actual try is to implement the sample code on page 1317 of the API manual and create a new Publisher for each stream that is published on the server, in order to pick up the AMF packets from that stream, add some data to the publisher with the publisher.addDataData method. Or is there an other way to implement the "amfPacket = readPacketFromSomewhere();" in that sample?

  2. #2
    Join Date
    May 2013


    Sounds like you'll want to use IMediaStreamActionNotify2 so you can distinguish between these types of events. Check out the following:

    How to monitor live streams using IMediaStreamActionNotify2

  3. Default

    Thanks! Exactly how do I check on the event type?

Similar Threads

  1. Trying to authenticate, only onStreamCreate is fired?
    By ickmund in forum Live Streaming and Encoder Discussion
    Replies: 5
    Last Post: 06-07-2012, 07:38 AM
  2. Get RTSP Session in onStreamCreate
    By asimkhan in forum Live Streaming and Encoder Discussion
    Replies: 5
    Last Post: 02-23-2012, 07:21 AM

Posting Permissions

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