WebCamTexture Crashing Editor - C# on OS X

I’m running into an issue where the editor crashes when attempting to use the WebCamTexture. I’ve based my script on some tutorials I’ve found on the web. Below is the c# code I’m using. Also, the script is attached to a GameObject with a GUITexture and the cameraTexture object is tied to that texture.

public class NativeCamera: MonoBehaviour {
public GUITexture cameraTexture;
public WebCamTexture webCamTexture;
void Start()
{
webCamTexture = new WebCamTexture();
cameraTexture.texture = webCamTexture;
webCamTexture.Play();
}
}

I would suggest not using a GUITexture since it’s the legacy (Unity 1.0) way of doing things.

Try using the new GUI instead and a RawImage.

Also, you might want to be a bit more verbose in your description like posting the error.

Thanks for the response

I just tried RawImage and received the same crash.

I didn’t receive an error, just a crash in the editor. Is there a dump or a log file somewhere I can look for, or is best way just to send bug using the Unity Bug Reporter?

If you are on a mac, the editor log is in the Console… I’m not sure on Windows.

Yes, that’s true, although the Editor crashes before I could see the log.

No, I mean the Console, meaning the Console application that has all the crash logs for all your applications and OSX itself

Looks like you want
C:\Users\username\AppData\Local\Unity\Editor\Editor.log