UnityでWebカメラを使っているのですが、Webカメラの映像を白黒で表示したいのですが、可能なのでしょうか。
お分かりになりましたら、方法もご教示頂けますと幸いです。
現在は以下のスクリプトをcubeにアタッチしております。
public int Width = 3000; public int Height = 2000; public int FPS = 30; public WebCamTexture webcamTexture; void Start() { WebCamDevice[] devices = WebCamTexture.devices; webcamTexture = new WebCamTexture(devices[0].name, Width, Height, FPS); GetComponent<Renderer>().material.mainTexture = webcamTexture; webcamTexture.Play(); }
よろしくお願いします。
回答2件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2017/02/10 10:43