Skip to main content
Known Participant
July 15, 2010
Question

How to detect webcam connection in runtime

  • July 15, 2010
  • 1 reply
  • 1039 views

Hi,

Is there any way to detect webcam  and microphone connections in runtime in flex.Suppose the clients are participated in a videoconnference .One of clients joins the conference without webcam.In meantime he connects to webcam as he  in the conference.How to stream  that user video to all connected clints.Any suggetions appreciated.

Thanks

Srinivas

    This topic has been closed for replies.

    1 reply

    calmchessplayer
    Inspiring
    July 15, 2010

    this is how we detect if a camera is attached or not as Camera.getCamera() returns null if no camera is attached

    camera0=Camera.getCamera();

    if (camera0 == null){

    trace("camera0 is not attached");

    }

    Known Participant
    July 16, 2010

    Hi,

    At the initial stage ,

    camera0=Camera.getCamera();

    if (camera0 == null){

    trace("camera0 is not attached");

    }

    will work.If user plugged the camera in runtime it won't detect

    calmchessplayer
    Inspiring
    July 16, 2010

    well you could call a timer to continously check and then stop the timer once the if statement returns true. Just try some actionscript/logiic jeesh.