다양한 오디오 형식을 지원하는 오디오 파일의 메타데이터(태그)를 읽고 편집할 수 있는 플러터 플러그인입니다. 제목, 아티스트, 앨범, 장르와 같은 일반적인 태그 필드에 접근하고 수정할 수 있는 간단한 인터페이스를 제공합니다. 음악 관리 또는 오디오 처리에 중점을 둔 플러터 앱에 원활하게 통합되도록 안드로이드용으로 설계되었습니다. 신뢰할 수 있는 태그 조작을 보장하기 위해 네이티브 안드로이드 기능을 활용합니다.
사용 사례
음악 앱에서 오디오 파일 메타데이터 편집
미디어 플레이어에서 곡 정보 표시하기
오디오 파일 일괄 태깅
장치 간 메타데이터 동기화
개인 음악 라이브러리 관리
주요 기능
다양한 오디오 형식을 지원합니다
메타데이터 태그 읽기 및 쓰기
일반 태그 필드를 위한 간단한 API
안드로이드 전용 플랫폼 지원
신뢰할 수 있는 네이티브 통합
적합한 대상
음악 앱 개발자
오디오 파일 관리자
미디어 라이브러리 도구
태그 도구
안드로이드 중심의 오디오 프로젝트
고려 사항
Android 플랫폼에 한정
적절한 파일 권한이 필요합니다
모든 오디오 형식을 지원하지 않을 수 있습니다
메타데이터 변경에는 파일 쓰기 접근 권한이 필요합니다
iOS 지원 사용 불가
원본 README
연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.
flutter_audio_tagger
A Flutter plugin for reading and editing audio file metadata (ID3 tags) on Android. The plugin reads tag data from audio files and returns edited files as raw bytes (Uint8List), giving your app full control over where and how the resulting file is saved.
Platform Support
Platform
Supported
Android
Yes
iOS
No
Web
No
Desktop
No
Features
Read all metadata tags from an audio file, including artwork
Read metadata tags only (without artwork)
Read artwork only
Edit metadata tags (without touching artwork)
Edit artwork only
Edit metadata tags and artwork together in a single call
Returns the complete modified audio file as bytes (Uint8List) along with the file extension, so your app decides where to write it
Every editing method returns an AudioFileData object. The plugin does not write the file to disk. Your app receives the raw bytes and is responsible for saving them. Use dart:io to write the bytes to any path your app has access to.
import'dart:io';
// Edit tagsAudioFileData editedFile = await tagger.editTags(updatedTag, originalFilePath);
// Write the bytes to a fileString savePath = '/storage/emulated/0/Download/edited.${editedFile.fileExtension}';
File outputFile = File(savePath);
await outputFile.writeAsBytes(editedFile.musicData);
You can save to any writable location: the app's documents directory, the downloads folder, an external storage path, or overwrite the original file. The fileExtension field tells you the format of the audio data so you can construct the correct filename.
import'package:path_provider/path_provider.dart';
// Save to app documents directoryDirectory appDir = awaitgetApplicationDocumentsDirectory();
String fileName = 'my_song.${editedFile.fileExtension}';
File file = File('${appDir.path}/$fileName');
await file.writeAsBytes(editedFile.musicData);
// Or overwrite the original fileFile original = File(originalFilePath);
await original.writeAsBytes(editedFile.musicData);