anarchuser / mic_stream

Flutter plugin to get an infinite audio stream from the microphone
https://pub.dev/packages/mic_stream
GNU General Public License v3.0
100 stars 68 forks source link

recorder null exception when using flutter_isolate on android #71

Closed renanyoy closed 1 year ago

renanyoy commented 1 year ago

the recorder is released as soon as I launch an isolate on android, it works well on iOS.


  flutterCompute(calcMainFrequency, info.samples).then((correlation) {
          calculatingFrequency = false;
          info.correlation = correlation;
        });
renanyoy commented 1 year ago

fixed by removing flutter_isolate package and using directly flutter compute function..

anarchuser commented 1 year ago

do you think there is something that needs fixing from the plugin's side?

renanyoy commented 1 year ago

I think it must be a bug in the flutter_isolate plugin or in flutter directly.. I checked your code all seems good..