기술 자료

Unity Engine

Unity Engine

Play()

Starts the camera.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

  • Type: Method
  • Namespace: UnityEngine
  • Assembly: UnityEngine.AudioModule
public void Play()

Remarks

Call Application.RequestUserAuthorization before creating a WebCamTexture.

Examples

// Starts the default camera and assigns the texture to the current rendererusing UnityEngine;using System.Collections;public class ExampleClass : MonoBehaviour{ void Start() { WebCamTexture webcamTexture = new WebCamTexture(); Renderer renderer = GetComponent<Renderer>(); renderer.material.mainTexture = webcamTexture; webcamTexture.Play(); }}