Open DawidWetzler opened 2 weeks ago
Hi there,
I'm trying to open video to apply some advanced filters (complex filters) but it looks openAdvanced isn't properly working with MediaCollection.
openAdvanced
I've shorten in completely to get the smallest reproducible version:
$media = new MediaCollection([ Media::make('local', 'input.mp4'), ]); $result = $ffmpeg->openAdvanced($media) ->export() ->toDisk('local') ->addFormatOutputMapping(new WebM(videoCodec: 'libvpx-vp9'), Media::make('local', 'output.webm'), []) ->dd(); // -y -threads 12 -vcodec libvpx-vp9 -b:v 1000k -acodec libvorbis -b:a 128k -f webm /var/www/html/storage/app/output.webm
Meanwhile this in raw phpffmpeg is working.
$ffmpeg = \FFMpeg\FFMpeg::create(); $video = $ffmpeg->openAdvanced([storage_path('app/input.mp4')]); $cmd = $video->map([], new WebM(videoCodec: 'libvpx-vp9'), storage_path('app/output.webm')) ->getFinalCommand(); dd($cmd); //output: -y -i /var/www/html/storage/app/input.mp4 -map -vcodec libvpx-vp9 -acodec libvorbis -b:a 128k -f webm /var/www/html/storage/app/output.webm
I'm not sure what's causing this but the chain led to ->open method where the media collection this is already empty.
->open
This results in Output file #0 does not contain any stream. error from ffmpeg.
Output file #0 does not contain any stream.
Hi there,
I'm trying to open video to apply some advanced filters (complex filters) but it looks
openAdvanced
isn't properly working with MediaCollection.I've shorten in completely to get the smallest reproducible version:
Meanwhile this in raw phpffmpeg is working.
I'm not sure what's causing this but the chain led to
->open
method where the media collection this is already empty.This results in
Output file #0 does not contain any stream.
error from ffmpeg.