Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Mediainfo Bundle

Mediainfo Bundle Laravel Package

mhor/mediainfo-bundle

mhor/mediainfo-bundle wraps the MediaInfo library for PHP, making it easy to extract technical metadata from audio and video files—codecs, duration, resolution, bitrate, and more—through a clean, bundle-integrated API. Useful for media catalogs, upload validation, and processing pipelines.

View on GitHub
Deep Wiki
Context7

Integrates php-mediainfo library into the Symfony2 full-stack framework.

Frequently asked questions about Mediainfo Bundle
Can I use mhor/mediainfo-bundle in a Laravel application?
No. mhor/mediainfo-bundle is a Symfony bundle that registers a service through Symfony's DI container, and Laravel has no bundle-loading mechanism. For Laravel, install the underlying mhor/php-mediainfo library directly and bind it in a service provider. Treat the bundle as a reference for service wiring, not as an installable Laravel package.
How do I install mhor/mediainfo-bundle?
In a Symfony app you install it with Composer, enable it in config/bundles.php, and configure the extension. It is not a Laravel package, so adding it to a Laravel composer.json will not give you a working integration. Laravel teams should require mhor/php-mediainfo instead.
What is mhor/mediainfo-bundle used for?
It wraps the MediaInfo library for PHP to extract technical metadata from audio and video files, including codecs, duration, resolution, bitrate, frame rate, audio channels, and subtitles. Typical uses include media catalogs, upload validation, and processing pipelines. The bundle itself is a thin Symfony service definition around mhor/php-mediainfo.
Does mhor/mediainfo-bundle support PHP 8 and modern Laravel versions?
The bundle targets Symfony 2.x and 3.x-era conventions and may declare PHP 5.6 or 7.x constraints. It does not target Laravel at all, so Laravel version support is not applicable. Check composer.json for the exact PHP constraint, and pin mhor/php-mediainfo only after confirming PHP 8.1 or newer compatibility.
How do I configure the MediaInfo binary path in Laravel?
Publish a config/media.php file with binary_path and timeout values, driven by an environment variable such as MEDIAINFO_BINARY. Bind mhor/php-mediainfo as a singleton in a service provider that reads that config. Add a health check that runs mediainfo --Version so a missing binary fails fast instead of at first upload.
Can mhor/php-mediainfo read files from S3 or remote URLs?
Most implementations expect a local filesystem path, because the library shells out to the MediaInfo CLI. For S3, HTTP, or streamed sources, download the file to a temporary path first, run extraction, then delete the temp file. Do not pass user-controlled URLs or paths directly into the command.
How do I test MediaInfo metadata extraction in Laravel?
Use a small set of representative fixtures: a large video, an audio-only file, a corrupt file, and an unusual container. Fake the service in unit tests and run a real integration test against the mediainfo binary in CI. Assert both normalized metadata and the persisted raw JSON.
What happens when MediaInfo processes a corrupt or non-media file?
Behavior depends on the underlying library and binary version: it may throw an exception, return null, or return only a General track with partial data. Test corrupt and non-media inputs explicitly and wrap calls in your own error handling. Normalize the result into a predictable success or failure contract for your application.
Is mhor/mediainfo-bundle maintained and production-ready?
It has very low adoption and appears effectively unmaintained, with no dependents and old Symfony-era conventions. Assume no upstream fixes and budget to vendor or fork the thin bundle layer if you use it. For production, track mhor/php-mediainfo separately, document the MediaInfo binary version, run extraction in queued jobs, and ensure the binary exists in every worker container.
What are alternatives to mhor/mediainfo-bundle for Laravel?
Use mhor/php-mediainfo directly, or evaluate php-ffmpeg/ffprobe for video and audio probing. getID3 is a solid option for audio-only metadata, and ExifTool can cover broader file metadata. Put any alternative behind the same internal interface so you can switch without changing ingestion code.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
novasa/laravel-language-center
opencage/geocode
adolfoholzer/parameters
livenetworks/ln-starter
shitoudev/permissionmanager
johannesclimacus/laravel-tui
hocvt/seotools
vitalybaev/sypexgeo
amphibee/themosis-ignition
gito-me/fast-excel
frankyso/laravel-ipaymu
geolize-studio/laravel-chile
boomerangui/chat
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons