duration()

Flutter Sound Helpers API


duration()

This verb is used to get an estimation of the duration of a sound file. Be aware that it is just an estimation, based on the Codec used and the sample rate.

Note : this verb uses FFmpeg and is not available int the LITE flavor of Flutter Sound.

Example:

        Duration d = flutterSoundHelper.duration("$myFilePath/bar.wav");
        Lorem ipsum ...