Search Unity

How to get a bool if device camera is hidden/returns black pixels

Discussion in 'AR/VR (XR) Discussion' started by Myrmidou, Sep 28, 2015.

  1. Myrmidou

    Myrmidou

    Joined:
    Jun 7, 2014
    Posts:
    30
    Hi everyone!

    I'm actually working on a project with cardboard and I can't use my smartphone's compass. I saw a VR app where we could hide the device camera to move and I want to do the same.
    There is not that much doc about it but I think I need to use WebCamTexture.GetPixels and check if returned pixels are close to black.

    Is there a better way to do it?

    Thanks!