
Recherche avancée
Autres articles (50)
-
Les formats acceptés
28 janvier 2010, parLes commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
ffmpeg -codecs ffmpeg -formats
Les format videos acceptés en entrée
Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
Les formats vidéos de sortie possibles
Dans un premier temps on (...) -
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 (...) -
Utilisation et configuration du script
19 janvier 2011, parInformations spécifiques à la distribution Debian
Si vous utilisez cette distribution, vous devrez activer les dépôts "debian-multimedia" comme expliqué ici :
Depuis la version 0.3.1 du script, le dépôt peut être automatiquement activé à la suite d’une question.
Récupération du script
Le script d’installation peut être récupéré de deux manières différentes.
Via svn en utilisant la commande pour récupérer le code source à jour :
svn co (...)
Sur d’autres sites (5902)
-
Laravel php timelapse an UploadedFile video element, without saving it as a file
24 août 2022, par The Blind HawkI want to be able to change the frame rate of a video from 0.05fps to 3fps.

I receive the video as anIlluminate\Http\UploadedFile
element, with mp4 format, how do I speed up its frame rate before sending it via email ?

The video is 25 minutes long, it should become 25 seconds long after changing the frame rate.

Is there a way to change the fps without saving the element as a File ?

I was planning to use the ffmpeg repository here but it requires me to save both the initial file, and the second file after changing the fps.
This is my code :


<?php

namespace Server\Mail;

use Carbon\Carbon;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Http\UploadedFile;

class TimeLapse extends Mailable
{
 use Queueable, SerializesModels;

 public UploadedFile $video;

 public bool $is_timelapsed;

 public string $format;

 /**
 * Create a new message instance.
 */
 public function __construct(
 UploadedFile $video, 
 bool $is_timelapsed, 
 string $format
 ){
 $this->video = $video;
 $this->is_timelapsed = $is_timelapsed;
 $this->format = $format;
 }

 private function timelapse(){
 // here I want to change $video element's fps from 0.05 to 3
 }

 /**
 * Build the message.
 *
 * @return $this
 */
 public function build()
 {
 if ( !$is_timelapsed ) { timelapse(); }

 $this->subject('message')
 ->text('emails.timelapse');

 $this->attach($this->video, [
 'as' => 'sample'.$format,
 'mime' => 'video/'.$format,
 ]);

 return $this;
 }
}



-
ffmpeg thumbnailer configure/make trouble in CentOS6
16 décembre 2013, par Juneyoung OhI am using CentOS 6.4 86x64.
What I am planning to do is install ffmpegthumbnailer.
I have downloaded at the link below.
https://code.google.com/p/ffmpegthumbnailer/The problem is when I extract the tar.gz and command configure,
It alway says like this.
checking for FFMPEG... no
configure: error: Package requirements (libavutil libavformat libavcodec >= 52.26.0 libswscale) were not met:
No package 'libavutil' found
No package 'libavformat' found
No package 'libavcodec' found
No package 'libswscale' foundOf course, I already installed ffmpeg 1.2.
/usr/lib64/libswscale.so.0.11.0
/usr/lib64/libswscale.so.0and also have libswscale.so.
What can I do to solve this ?
Thanks:D
============I solved one and get another===============
I solved(?) this with what console said.
adjust PKG_CONFIG_PATH.
I find my libavutil.pc and give that path to PKG_CONFIG_PATH, like below.
export PKG_CONFIG_PATH=/usr/lib/pkgconfig/
then It looks OK, but I got another one.
./configure works nice with suspected message.
CONFIGURATION SUMMARY ----
png support : disabled
jpeg support : disabled
gio support : disabled
register thumbnailer : disabled
unittests : disabled
debug mode : disabledanyway, configure was OK, and I have make files now.
The problem is when I do make command, it shows error like below.
/usr/bin/ld: /usr//lib/libavformat.a(allformats.o): relocation R_X86_64_32 against `ff_a64_muxer' can not be used when making a shared object; recompile with -fPIC
/usr//lib/libavformat.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make[2]: *** [libffmpegthumbnailer.la] Error 1
make[2]: Leaving directory `/home/guest/Downloads/ffmpegthumbnailer-2.0.8'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/guest/Downloads/ffmpegthumbnailer-2.0.8'
make: *** [all] Error 2Please, tell me that I have to do solve this:D
-
ffmpeg H264 Encode Frame at a time for network streaming
4 février 2017, par Richard HarrowI’m working on a remote desktop application, I would like to send an encoded H264 packet over TCP by using ffmpeg for the encoding. However I couldn’t find useful info for the particular case of encoding just one frame (already on YUV444) and get the packet.
I have several issues, the first was that :
avcodec_encode_video2
Was not blocking, I found that most of the time you get the "delayed" frames at the end, however, since this is a real time streaming the solution was :
av_opt_set(mCodecContext->priv_data, "tune", "zerolatency", 0);
Now I got the frame, but several issues, it takes a while and even worse I got a gray with trash pixels video as result. My configuration for the Codec Context :
m_pCodecCtx->bit_rate=8000000;
m_pCodecCtx->codec_id=AV_CODEC_ID_H264;
m_pCodecCtx->codec_type = AVMEDIA_TYPE_VIDEO;
m_pCodecCtx->width=1920;
m_pCodecCtx->height=1080;
m_pCodecCtx->pix_fmt=AV_PIX_FMT_YUV444P;
m_pCodecCtx->time_base.num = 1;
m_pCodecCtx->time_base.den = 25;
m_pCodecCtx->gop_size = 1;
m_pCodecCtx->keyint_min = 1;
m_pCodecCtx->i_quant_factor = float(0.71);
m_pCodecCtx->b_frame_strategy = 20;
m_pCodecCtx->qcompress = (float)0.6;
m_pCodecCtx->qmax = 51;
m_pCodecCtx->qmin = 20;
m_pCodecCtx->max_qdiff = 4;
m_pCodecCtx->refs = 4;
m_pCodecCtx->max_b_frames = 1;
m_pCodecCtx->thread_count = 1;I would like to know how this could be done, how do I set the "I Frames" ? and, that would be the optimal for a "one at a time" encoding ? Also I’m not concerned right now with the quality, just need to be fast enough (under 16 ms).
For the encoding part :
nres = avcodec_encode_video2(m_pCodecCtx,&packet,m_pFrame,&framefinished);
if(nres<0){
qDebug() << "error encoding: " << nres << endl;
}
if(framefinished){
m_pFrame->pts++;
ofstream vidout("video.h264",ios::app);
if(vidout.good()){
vidout.write((const char*)&packet.data[0],packet.size);
}
vidout.close();
av_packet_unref(&packet);
}I’m not using a container, just a raw file, ffplay reproduce raw files if the packets are right, and that’s my principal issue. I’m planning to send the packet over tcp and decode on the client. Any help would be greatly appreciated.