ahsanrazapk / has_audio

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

has_audio

pub license: MIT

A Flutter plugin for checking if a video file contains an audio track. This plugin provides a simple method to quickly determine the presence of audio in a video file on both Android and iOS platforms.

Features

  • Check if a video file has an audio track.
  • Easy-to-use with a simple method call.
  • Supports both Android and iOS.

Installation

To use this plugin, add has_audio as a dependency in your pubspec.yaml file.

dependencies:
  has_audio: ^0.0.6

To use the has_audio plugin, first import it in your Dart code:

import 'package:has_audio/has_audio.dart';

Then, you can call the HasAudio.check method to check if a video file contains an audio track.

String videoPath = 'path/to/your/video/file.mp4';
bool hasAudio = await HasAudio.check(videoPath);
print(hasAudio ? 'The video has audio' : 'The video does not have audio');

About

License:MIT License


Languages

Language:Dart 42.7%Language:Kotlin 20.5%Language:Swift 18.3%Language:Ruby 18.1%Language:Objective-C 0.3%