asus4 / tf-lite-unity-sample

TensorFlow Lite Samples on Unity
861 stars 252 forks source link

Better camera quality or a plugin instead of WebcamTexture #323

Closed cancaglar closed 9 months ago

cancaglar commented 10 months ago

Is there a way to improve FPS and reduce lag in Unity applications made with MoveNet or Blazepose when using 1920x1080 or 4k cameras on Windows? Alternatively, on mobile platforms, is there a way to use an external plugin to obtain higher quality view instead of Unity's WebcamTexture, or is it possible to implement such a solution?

asus4 commented 10 months ago

@cancaglar Yes, the latency will improve if you use other low-latency camera plugins, such as AVPro Live Camera or NatML VideoKit.

However, the camera resolution of the model (not camera preview) would be difficult to improve since pre-trained models accept fixed-sized images. The camera input is trimmed to match this size when you call the model via BaseImagePredictoer.