
Recherche avancée
Médias (1)
-
Bug de détection d’ogg
22 mars 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Video
Autres articles (35)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Librairies et logiciels spécifiques aux médias
10 décembre 2010, parPour un fonctionnement correct et optimal, plusieurs choses sont à prendre en considération.
Il est important, après avoir installé apache2, mysql et php5, d’installer d’autres logiciels nécessaires dont les installations sont décrites dans les liens afférants. Un ensemble de librairies multimedias (x264, libtheora, libvpx) utilisées pour l’encodage et le décodage des vidéos et sons afin de supporter le plus grand nombre de fichiers possibles. Cf. : ce tutoriel ; FFMpeg avec le maximum de décodeurs et (...)
Sur d’autres sites (6211)
-
Is there any way that I can speed up the ffmpeg processing time
20 mai 2020, par Ahmed Al-RayanI am facing a problem with the processing process. I use a real joint server in a digital hosting package of $ 10 and use cloud service from Amazon s3. The problem is when uploading a video, whatever the size of the video, whether its size is 1 megabyte or 2 Giga. After the upload process, the processing process starts to upload, there is no problem But when the processing process takes a very long time so that I cannot complete it, what is the solution to that, is there a problem for me or is this process normal ?
 I use laravel-ffmpeg and through laravel queue I am cutting the video into several qualities I will attach the code to you below.



public function handle()
{
 //180p
 $lowBitrate1 = (new X264('aac'))->setKiloBitrate(613);
 //270p
 $lowBitrate2 = (new X264('aac'))->setKiloBitrate(906);
 //360p
 $midBitrate1 = (new X264('aac'))->setKiloBitrate(1687);
 //540p
 $midBitrate2 = (new X264('aac'))->setKiloBitrate(2227);
 //720p
 $highBitrate1 = (new X264('aac'))->setKiloBitrate(4300);
 //1080
 $highBitrate2 = (new X264('aac'))->setKiloBitrate(7917);

FFMpeg::fromDisk('s3')
 ->open($this->movie->path)
 ->exportForHLS()
 ->onProgress(function ($percent) {
 $this->movie->update([
 'percent' => $percent
 ]);
 })
 ->setSegmentLength(10)// optional
 ->addFormat($lowBitrate1)
 ->addFormat($lowBitrate2)
 ->addFormat($midBitrate1)
 ->addFormat($midBitrate2)
 ->addFormat($highBitrate1)
 ->addFormat($highBitrate2)
 ->toDisk('s3')
 ->save("public/Movies/{$this->movie->id}/{$this->movie->id}.m3u8");
}//end of handle



-
Generating random thumbnails with PHP+FFMPEG
30 décembre 2014, par MrGhostI’m trying to generate thumbnails from random points in a movie using FFMPEG and FFMPEG-PHP extension.
My script works OK.. however takes 20 minutes just to generate 5-10 thumbnails !!
The script works by generating random numbers which are used as frame numbers later. All numbers generated are within the movies frame count.
Can you work out why this script is taking 20 mins to finish ?
If not, a better solution ?<?php
//Dont' timeout
set_time_limit(0);
//Load the file (This can be any file - still takes ages)
$mov = new ffmpeg_movie('1486460.mp4');
//Get the total frames within the movie
$total_frames = $mov->getFrameCount();
//Loop 5-10 times to generate random frames 5-10 times
for ($i = 1; $i <= 5; ) {
// Generate a number within 200 and the total number of frames.
$frame = mt_rand(200,$total_frames);
$getframe = $mov->getFrame($frame);
// Check if the frame exists within the movie
// If it does, place the frame number inside an array and break the current loop
if($getframe){
$frames[$frame] = $getframe ;
$i++;
}
}
//For each frame found generate a thumbnail
foreach ($frames as $key => $getframe) {
$gd_image = $getframe->toGDImage();
imagejpeg($gd_image, "images/shot_".$key.'.jpeg');
imagedestroy($gd_image);
echo $key.'<br />';
}
?>The script SHOULD be generating frame numbers which are valid ? Anything within START - END should be valid frame numbers ? Yet the loop takes ages !
-
ffmpeg API encoding mpeg-4 Windows Media Player error
9 juin 2017, par user1505129We have an app that uses the ffmpeg C API to encode mpeg-4 (AV_CODEC_ID_MPEG4) files in a mp4 container. The problem is that the files don’t play in Windows Media Player or the Windows 10 video player "Movies & TV" app. It plays in VLC, google chrome, Ubuntu’s video player, and all other video players I’ve tried.
The two Windows players are able to play other files encoded with mpeg-4 in mp4 container. I also tested transcoding video files to the same format using the command line ’ffmpeg’ tool and was successfully able to play the video using the following command :
ffmpeg input.avi -c:v mpeg4 output.mp4
While I found the following commands do not work :
ffmpeg input.avi -c:v mpeg4 -vtag xvid output.mp4
ffmpeg input.avi -c:v libxvid output.mp4
# the last command wont play with windows media player but VLC can still play it. If the extension of the output file is changed to avi for the last two commands then Windows media player can play it.
I started looking at the ffmpeg src code but it appears a bit large/complex, I tried using the simpler "encode_video.c" example, which was able to encode a video and play it in Ubuntu’s default video player but VLC nor Windows Media Player could play it.
We need to encode these using the ffmpeg API, not the command line tool, so I am wondering what the ffmpeg command line tool is doing that I am not, or any ideas on what the problem could be and how to get this working.
Thanks.