Skip to main content

5 posts tagged with "better-player"

View All Tags

Client-Side Video Ads in Flutter: VAST and VMAP with Better Player Enterprise

· 4 min read
Jakub Homlala
Senior Mobile Engineer

Most video ad integrations in Flutter wrap native platform SDKs (like Google IMA) inside platform views (AndroidView and UiKitView). That approach causes two persistent headaches:

  1. The buffer drop: When a mid-roll ad starts, the platform view mounts over Flutter's canvas. The underlying media player often dumps its decoded buffers to reclaim GPU memory. Once the ad finishes, your user sits staring at a black screen or spinner while the main video re-buffers from scratch.
  2. Platform fragmentation: Native wrappers pull in complex Gradle and CocoaPods dependencies that break during Flutter upgrades, and they do not compile at all on Flutter Web or Desktop.

In better_player_enterprise, we replaced native SDK wrappers with a pure-Dart VAST and VMAP ad engine. It runs across Android, iOS, Web, macOS, Windows, and Linux without native ad dependencies.

Building a Vertical Video Feed in Flutter Without Crashing

· 4 min read
Jakub Homlala
Senior Mobile Engineer

If you put a standard video player inside a PageView.builder, your feed will feel fine in a desktop browser and crash quickly on real mobile devices.

Mobile operating systems share a limited pool of hardware decoders across every running app. Each active video player requests its own decoder session and allocates a GPU texture. Because native engines tear down decoders asynchronously, a user flicking through half a dozen clips creates new players faster than the OS can release old ones. The result: decoder allocation failures, frame drops, or the OS killing your process for hogging graphics memory.

Better Player solves this with controller pooling: recycling a small, fixed set of native player instances instead of allocating a fresh player for every page.

Migrating from media_kit to Better Player

· 6 min read
Jakub Homlala
Senior Mobile Engineer

media_kit is a solid piece of engineering if you're building a desktop app on Windows, Linux, or macOS. Wrapping libmpv gives you an all-in-one codec powerhouse that plays almost any obscure video container you throw at it.

Mobile is a completely different game.

Once your Flutter app targets Android and iOS, bundling libmpv extracts a heavy tax: 30 to 50 MB of native C binaries per ABI in your final APK or IPA. Then your roadmap asks for studio-grade Widevine L1 or FairPlay DRM, native Picture-in-Picture, lock screen media controls, or a scrollable feed like TikTok. That is where libmpv starts fighting the mobile OS, and where Better Player takes over.

Here is why developers make the switch, and how to migrate your codebase in under thirty minutes.

So, You Want to Migrate to Better Player?

· 6 min read
Jakub Homlala
Senior Mobile Engineer

Let’s be honest: we’ve all been there. You start a Flutter project, throw in the official video_player package, and think, "Hey, this is pretty easy."

Then the client (or your own product roadmap) hits you with real-world requirements:

  • "Can we cache videos so users don't burn through their data?"
  • "Why does the player controls overlay break when I rotate the phone?"
  • "Can we add subtitles? And picture-in-picture? And a custom loading spinner?"

Suddenly, you’re drowning in platform channels, custom gesture detectors, and a spaghetti mess of state management to keep a video playing smoothly.

If you're wrapping your head around this and considering a switch to Better Player (or trying to decide between it and Chewie), let's walk through what the transition looks like in practice.