AdityaMulgundkar/flutter_opencv

[BUG] Function calls block main UI thread

Opened this issue · 0 comments

The function calls are futures, but they still block the main UI thread causing jank, frozen app.

Steps to reproduce the behavior:

  1. Load a bigger image as Uint8List. The bigger the image, the longer the freezing time.
  2. Use on this any of the ImgProc methods, ex ImgProc.resize, ImgProc.blur
  3. See freeze

Expected behavior
The method call shouldn't block the main UI thread.

Additional context
If the methods would be sync calls we could use compute, isolates avoiding this issue.