Iphone simulator and webcam

后端 未结 4 828
南旧
南旧 2021-02-19 04:35

Can we make able the iphone simulator to capture an image via webcam, I\'ve written a program to take image from iphone camera. Can i test this with the iphone simulator??? Pls

相关标签:
4条回答
  • 2021-02-19 04:42

    (Sorry for my english)

    In android world, the phone emulator don't have a live camera preview so the solution is create a "Webcam Server" running on emulator host (PC/Mac). This program is a socket server to capture frames from the built-in Webcam and transmit them using a socket.

    Then in the phone code (android emulator) you can read the frame through socket and then shows and simulate a real phone camera.

    Is that posible in iPhone simulator?

    0 讨论(0)
  • 2021-02-19 04:43

    You cannot use mac's camera. For camera, you need to test it on a device.

    From Apple documentation:

    The hardware features that are not simulated as of iOS 8.2 are:

    • Motion support (accelerometer and gyroscope) are unsupported.
    • Audio and video input (camera and microphone) are unsupported.
    • Proximity sensor
    • Barometer Ambient light sensor
    0 讨论(0)
  • 2021-02-19 04:50

    You cannot take image via Mac's webcam from iPhone Simulator. For camera, you need to test it on a device.

    0 讨论(0)
  • 2021-02-19 04:55

    Imagine if this would be possible on the Simulator, your Mac camera resoultion would be very different from the device one and your mac performances too. This could lead to bad surprises when moving and testing the application on the device.

    0 讨论(0)
提交回复
热议问题