bmff 1.0.0 copy "bmff: ^1.0.0" to clipboard
bmff: ^1.0.0 copied to clipboard

The package provides a library for reading ISO Base Media File Format (BMFF) files.

bmff of dart #

The package provides a library for reading ISO Base Media File Format (BMFF) files.

Usage #

dependencies:
  bmff: any
import 'package:bmff/bmff.dart';

Example #

Simple example #

Click to show codes
import 'package:bmff/bmff.dart';

void main() {
  final assetPath = 'assets/compare_still_1.heic';
  final bmff =
      Bmff.file(assetPath); // The path is file path, not flutter asset path.

  final boxes = bmff.childBoxes;
  for (final box in boxes) {
    print(box);
  }

  showFtyp(bmff);
}

void useByteListSource(List<int> bytes) {
  final bmff = Bmff.memory(bytes);
  final boxes = bmff.childBoxes;
  for (final box in boxes) {
    print(box);
  }
}

void showFtyp(Bmff bmff) {
  final typeBox = bmff.typeBox;
  final type = typeBox.type;

  final majorBrand = typeBox.majorBrand;
  final minorVersion = typeBox.minorVersion;
  final compatibleBrands = typeBox.compatibleBrands;

  print('type: $type');
  print('majorBrand: $majorBrand');
  print('minorVersion: $minorVersion');
  print('compatibleBrands: $compatibleBrands');
}

All examples #

See example.

Other resources #

ISO Base Media File Format (BMFF) The project wiki

LICENSE #

BSD 3-Clause License

0
likes
0
pub points
19%
popularity

Publisher

verified publisherkikt.top

The package provides a library for reading ISO Base Media File Format (BMFF) files.

Repository (GitHub)
View/report issues

License

unknown (license)

More

Packages that depend on bmff