mvimg 1.1.1 copy "mvimg: ^1.1.1" to clipboard
mvimg: ^1.1.1 copied to clipboard

A library to split mvimg(android motion video) file.

example/mvimg_example.dart

import 'dart:io';

import 'package:buff/buff_io.dart';
import 'package:mvimg/mvimg.dart';

void main() {
  final mvimg = Mvimg(FileBufferInput.fromPath('assets/test.jpg'));
  mvimg.decode();
  try {
    if (!mvimg.isMvimg()) {
      print('not mvimg');
      return;
    }

    final img = mvimg.getImageBytes();
    final video = mvimg.getVideoBytes();

    final videoOutputPath = 'assets/split/output.mp4';
    final imgOutputPath = 'assets/split/output.jpg';

    final videoFile = File(videoOutputPath);
    final imgFile = File(imgOutputPath);

    videoFile.createSync(recursive: true);
    imgFile.createSync(recursive: true);

    videoFile.writeAsBytesSync(video);
    imgFile.writeAsBytesSync(img);
  } finally {
    mvimg.dispose();
  }
}
1
likes
0
points
174
downloads

Publisher

verified publisherfluttercandies.com

Weekly Downloads

A library to split mvimg(android motion video) file.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

buff, collection, xml

More

Packages that depend on mvimg