#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2013
    Posts
    31
    Rep Power
    2

    Webcam function on Android


    There is a function built into the Android module which activates the phone's (or tablet) camera for use as an MJPEG streaming webcam and is supposed to return a tuple for the address and port # of the stream.

    My question is.....once it is enabled for streaming, how would you have the tuple values for the address and port displayed? When you call the function, it enables the camera and you basically only have a camera preview displayed on the screen.

    Code:
    import android
    droid = android.Android()
    
    droid.webcamStart()
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2013
    Posts
    138
    Rep Power
    2
    Originally Posted by Guitarman2010
    There is a function built into the Android module which activates the phone's (or tablet) camera for use as an MJPEG streaming webcam and is supposed to return a tuple for the address and port # of the stream.

    My question is.....once it is enabled for streaming, how would you have the tuple values for the address and port displayed? When you call the function, it enables the camera and you basically only have a camera preview displayed on the screen.

    Code:
    import android
    droid = android.Android()
    
    droid.webcamStart()
    From https://code.google.com/p/android-scripting/wiki/unofficial_apiref#webcamStart : "Starts an MJPEG stream and returns a Tuple of address and port for the stream."

    Code:
    (address, port) = droid.webcamStart()
    http://www.catb.org/esr/faqs/smart-questions.html#code
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2013
    Posts
    31
    Rep Power
    2
    Originally Posted by partoj
    From https://code.google.com/p/android-scripting/wiki/unofficial_apiref#webcamStart : "Starts an MJPEG stream and returns a Tuple of address and port for the stream."

    Code:
    (address, port) = droid.webcamStart()
    The answer was that easy? I keep that website always book marked and have it saved as a PDF for offline viewing but I still couldn't gather that easy answer lol.......thanks for the help

IMN logo majestic logo threadwatch logo seochat tools logo