Flutter Sound Helpers API
convertFile()
convertFile()
convertFile()- Dart API: convertFile() 
This verb is useful to convert a sound file to a new format.
- infileis the file path of the file you want to convert
- codecinis the actual file format
- outfileis the path of the file you want to create
- codecoutis the new file format
Be careful : outfile and codecout must be compatible. The output file extension must be a correct file extension for the new format.
Note : this verb uses FFmpeg and is not available int the LITE flavor of Flutter Sound.
Example:
        String inputFile = '$myInputPath/bar.wav';
        var tempDir = await getTemporaryDirectory();
        String outpufFile = '${tempDir.path}/$foo.mp3';
        await flutterSoundHelper.convertFile(inputFile, codec.pcm16WAV, outputFile, Codec.mp3)
        Lorem ipsum ...</div>
Last updated
Was this helpful?
