Device camera streaming using Remote 4 in 4.5f6

According to this doc, the new Remote 4 now supports streaming back the device cam to the editor, afaik this was newly added with Unity 4.5: http://docs.unity3d.com/Manual/UnityRemote4.html
Just tried the script below with the latest Unity 4.5.0f6 and the Remote 4 from the Play Store on Android (HTC One), but it does not work as expected. I was under the impression that creating and rendering a WebCamTexture using the remote would automatically stream back the device camera (see script code below - just attached to the main camera in the scene), but it does not. Instead, I get the view from the web cam connected to my PC streamed onto my device. If I unplug the webcam, I don’t get the device cam either, just an error log “No available webcams are found. …”.

Is there something I’m doing wrong or is device camera streaming not actually supported yet?

Cheers,
Johannes

using UnityEngine;

public class WebCamBehaviour : MonoBehaviour
{
    WebCamTexture mWebCamTexture;

    void Start()
    {
        mWebCamTexture = new WebCamTexture();
        mWebCamTexture.Play();
    }

    void OnGUI()
    {
        GUI.DrawTexture(new Rect(10f, 10f, (float)mWebCamTexture.width, (float)mWebCamTexture.height), mWebCamTexture);
    }
}
1 Like

i am experiencing the same problem. i have tried all possible strings for camera names. i also tried modifying the remote app that is in the addon store. but without success.

the first problem seems to be that the list of webcam devices on the mobile device is never checked.

i am running osx with 4.5.0f6 and a iphone 5.

Hi Johannes,

I provided an answer about the correct usage of WebCamTexture here. This might also work for your problem.

Hey ludos! Did you find any solution? I really need to get the camera stream from my device…
Thanks in advance.