
Recherche avancée
Autres articles (86)
-
Gestion des droits de création et d’édition des objets
8 février 2011, parPar défaut, beaucoup de fonctionnalités sont limitées aux administrateurs mais restent configurables indépendamment pour modifier leur statut minimal d’utilisation notamment : la rédaction de contenus sur le site modifiables dans la gestion des templates de formulaires ; l’ajout de notes aux articles ; l’ajout de légendes et d’annotations sur les images ;
-
Le profil des utilisateurs
12 avril 2011, parChaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...) -
Dépôt de média et thèmes par FTP
31 mai 2013, parL’outil MédiaSPIP traite aussi les média transférés par la voie FTP. Si vous préférez déposer par cette voie, récupérez les identifiants d’accès vers votre site MédiaSPIP et utilisez votre client FTP favori.
Vous trouverez dès le départ les dossiers suivants dans votre espace FTP : config/ : dossier de configuration du site IMG/ : dossier des média déjà traités et en ligne sur le site local/ : répertoire cache du site web themes/ : les thèmes ou les feuilles de style personnalisées tmp/ : dossier de travail (...)
Sur d’autres sites (9358)
-
FFmpeg hangs on buffer fill c++
2 mars 2021, par Derek HaldenI'm processing a bunch of frames from an RTSP stream using ffmpeg. I end up doing a lot of processing on these frames, which means that I'm not always pulling in real-time. If the buffer gets full, the process hangs. I'm wondering if one of the following solutions is feasible/fixes the problem, and if so, how I would implement it using the ffmpeg libraries :



1) Is there a way to clear the buffer if I ever reach a point where it's hanging ? (I can determine when it's hung, I just don't know what to do about it).



2) Is there a way to make the buffer overwrite the old data, and just always read the most recent data ? It doesn't matter to me if I lose frames.



3) I've already discovered that I can make the buffer arbtrarily large with :
av_dict_set(&avd, "buffer_size", "655360", 0);
. This could be a solution, but I don't know how large/small it needs to be, because I don't know how long the stream will post video for ?


4) Is this just a bug that I need to bring up with the ffmpeg people ?



5) Something else I haven't considered ?



while(av_read_frame(context, &(packet)) >= 0 && fcount < fps*SECONDS) {
 clock_t start, end;
 int ret = avcodec_send_packet(codec_context, packet);
 if(!(packet->stream_index == video_stream_index)) {
 continue;
 }

 if (ret == AVERROR(EAGAIN) || ret == AVERROR(EINVAL)) {
 continue;
 } else if (ret < 0) {
 cerr << "Error while decoding frame " << fcount << endl;
 exit(1);
 }

 ret = avcodec_receive_frame(codec_context, frame);
 if (ret == AVERROR(EAGAIN) || ret == AVERROR(EINVAL)) {
 continue;
 } else if (ret < 0) {
 cerr << "Error while decoding frame " << fcount << endl;
 exit(1);
 }

 sws_scale(img_convert_ctx, frame->data, frame->linesize, 0,
 codec_context->height, picture_rgb->data, picture_rgb->linesize);

 if(!frame) {
 cerr << "Could not allocate video frame" << endl;
 exit(1);
 }

 if(codec_context == NULL) {
 cerr << "Cannot initialize the conversion context!" << endl;
 exit(1);
 }

 // Do something with the frame here

 fcount++;
 av_packet_unref(&(packet));

}




I have added the code that causes the program to hang.


-
FFMPEG command runs forever even on using timelimit
21 décembre 2017, par t6nandMostly I use a java code to run FFMPEG bash commands for watermarking a logo on video. I am using the following FFmpeg command to overlay an image on video. I have observed that at times for some random videos, the process keeps on running even after the timelimit assigned to it expires. At times it’s more than a day or couple of days until not directly killed using
kill -9 pid
:ffmpeg -timelimit 900 -y -i
input_video
-i logoImage -filter_complex "[0:v]scale=trunc(iw/2)*2:trunc(ih/2)*2[even] ;[1:v][even]scale2ref=iw*0.25 :(iw*0.25)*(0.46446702)[2nd][ref] ;[ref][2nd]overlay=(main_w-overlay_w) :(main_h-overlay_h)"
-c:v libx264 -b:v 300K -crf 28 -preset slow outputVideoBut this command never completes even on using
-timelimit
flag at times for some videos.I have observed that for such processes output from
ps aux|grep ffmpeg
yeilds in something like :ubuntu 16620 0.6 6.7 1595044 515392 ? Sl Dec20 12:05
ffmpeg -timelimit 900 -y -i
input_video
-i logoImage -filter_complex "[0:v]scale=trunc(iw/2)*2:trunc(ih/2)*2[even] ;[1:v][even]scale2ref=iw*0.25 :(iw*0.25)*(0.46446702)[2nd][ref] ;[ref][2nd]overlay=(main_w-overlay_w) :(main_h-overlay_h)"
-c:v libx264 -b:v 300K -crf 28 -preset slow outputVideoIt indicates that this process is in interruptible sleep state i.e. waiting for an event to complete. On using
sudo strace -p 16620
to trace which system call is this process hung up on it results in something like :Process 16620 attached write(2, "frame= 4121 fps= 10 q=33.0 size="...,
99i.e. it’s stuck writing to a file.
What could be the reason for this problem ?
And is there any other way to kill FFMPEG process which overshoots desired time limit ? -
How do you make a modern bleep censor ? (With ffmpeg or other ready-made software)
1er août 2023, par nick carrawayI have always been a fan of live caller radio shows. These (sports) shows allow callers to call a hotline and talk to the radio host directly.


One of the oldest problems with this show format is what if the caller curses, or says something highly inappropriate ? To keep the show clean (and legal), the radio shows broadcast with a 7 second delay. They also use a "bleep" censor, which historically allowed them to wipe the incriminating phrase with a "Beeeeeep" sound. These days, however, they completely cut out the caller's sentence before it even begins. ("Ah, we had to let you go there pal. Can't say that on the radio"). In the modern method, the transition is seamless, almost like they shorten the 7 second delay to a 4 second delay as they remove the start of the caller's reply entirely, and overwrite it with the host's explanations. The caller does not appear to be "interrupted" at all, the start of their sentence leading to the bad phrase is never even broadcasted.


I've been thinking about how to do this in software. I found a project that looked promising. It adds a 7 second delay to your streams, and allows you to convert X amount of those seconds into silence assuming a caller says something inappropriate. While not ideal (since it's a few seconds of dead silence and would interrupt the caller mid-sentence), how can you do something like this in ffmpeg ? It is a good starting point before implementing the more modern features.


- 

-
How do you use ffmpeg to livestream a video/audio stream with a delay ?


-
How do you overwrite the last 3 seconds of that stream with silence or a "bleep", when you need to ?


-
Are you able to easily switch your stream to overwrite those 3 seconds with new audio (e.g. the host's explanation for why the caller was hung-up on) ? And how can you go back from a 4 second delay to a 7 second delay ?


-
OR, is there a ready-made way to get flawless "radio-like" hang-ups on bad callers ?












-