Upgrade to Pro — share decks privately, control downloads, hide ads and more …

ココがダメだよWebCamTexture

 ココがダメだよWebCamTexture

イケてないと悪評高いUnityのWebCamTextureを使ってみたので、ダメな部分を紹介します。

Masaya Yashiro

June 21, 2017
Tweet

More Decks by Masaya Yashiro

Other Decks in Technology

Transcript

  1. ࢖͍ํ private struct Fhd { public const int Width =

    1920; public const int Height = 1080; } private int Fps = 30; private WebCamTexture WebCam { get; set; } void Start() { WebCam = new WebCamTexture( WebCamTexture.devices[0].name, Fhd.Width, Fhd.Height, Fps ); WebCam.Play(); } private void OnDestroy() { WebCam.Stop(); Destroy(WebCam); }
  2. ͳΜ͔ΊͬͪΌॏ͍ private struct Fhd { public const int Width =

    1920; public const int Height = 1080; } private int Fps = 8; private WebCamTexture WebCam { get; set; } void Start() { WebCam = new WebCamTexture( WebCamTexture.devices[0].name, Fhd.Width, Fhd.Height, Fps ); WebCam.Play(); }
  3. ·ͩ୺຤ʹΑͬͯ͸ॏ͍ private struct Hd { public const int Width =

    1280; public const int Height = 720; } private int Fps = 8; private WebCamTexture WebCam { get; set; } void Start() { WebCam = new WebCamTexture( WebCamTexture.devices[0].name, Hd.Width, Hd.Height, Fps ); WebCam.Play(); }
  4. ͳΜ͔Portraitͷ࣌ө૾͕ߥ͍ private struct Hd { public const int Width =

    720; public const int Height = 1280; } private int Fps = 8; private WebCamTexture WebCam { get; set; } void Start() { WebCam = new WebCamTexture( WebCamTexture.devices[0].name, Hd.Width, Hd.Height, Fps ); WebCam.Play(); }