It's very simle to use, just choose a file of mp4 video ,and return the duration info (seconds) of the video.
- ๐ Cross platform: mobile, desktop, browser
- โค๏ธ Simple, powerful, & intuitive API
- ๐ NO native dependencies
add to project
dependencies:
get_mp4_duration: ^0.0.1
use in project
you can use in async function like this :
const file = File('/xxx/xx.mp4');
const mp4Tool = GetMp4Duration();
int duration = await mp4Tool.getMp4Duration(file.path);
print(duration);