kplayer
0.4.2, released 3 years ago by physia.dev
A cross-platform audio player wrapper supporting assets, network, files, and bytes.
What it does
Provides a unified API for playing audio from various sources across Android, iOS, Windows, macOS, and Linux. It includes built-in state management mixins, helper streams, and helper widgets like PlayerBar and PlayerBuilder.
AI-written summary of version 0.4.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need a cross-platform audio player that supports Android, iOS, Windows, macOS, and Linux.
- You want easy playback from assets, network, files, or bytes with minimal setup.
- You want access to ready-made widgets like PlayerBar and PlayerBuilder.
Skip it when
- You need complex video playback features (the package documentation notes it is currently only audio).
- You are using backend implementations that have been deprecated (such as just_audio or dart_vlc wrappers).
Strengths
- Supports multiple platforms (Android, iOS, Windows, macOS, Linux).
- Provides convenient built-in widgets such as PlayerBar and PlayerBuilder.
- Includes stream support and a PlayerStateMixin to automatically handle state changes.
Weaknesses
- Video support is currently not implemented/documented (audio only).
- Some backend wrappers are marked as deprecated.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 2
no action required, just add package and use it. Optionally call Player.boot() in main.dart.
var player = Player.asset("/assets/sound.mp3");
player.play();Alternatives
Packages that do the same job and could replace kplayer.
- just_audio
A feature-rich alternative audio player for Flutter with advanced looping, clipping, and playlist support.
80Compare - audioplayers
A widely-used core audio playback library that kplayer itself can use as a backend wrapper.
87Compare