
Recherche avancée
Médias (2)
-
Exemple de boutons d’action pour une collection collaborative
27 février 2013, par
Mis à jour : Mars 2013
Langue : français
Type : Image
-
Exemple de boutons d’action pour une collection personnelle
27 février 2013, par
Mis à jour : Février 2013
Langue : English
Type : Image
Autres articles (70)
-
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 est la première version de MediaSPIP stable.
Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
Diogene : création de masques spécifiques de formulaires d’édition de contenus
26 octobre 2010, parDiogene est un des plugins ? SPIP activé par défaut (extension) lors de l’initialisation de MediaSPIP.
A quoi sert ce plugin
Création de masques de formulaires
Le plugin Diogène permet de créer des masques de formulaires spécifiques par secteur sur les trois objets spécifiques SPIP que sont : les articles ; les rubriques ; les sites
Il permet ainsi de définir en fonction d’un secteur particulier, un masque de formulaire par objet, ajoutant ou enlevant ainsi des champs afin de rendre le formulaire (...) -
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)
Sur d’autres sites (6858)
-
ffmpeg - Encoding Percentage in PHP
13 juillet 2012, par JimboI've written a whole system in PHP and bash on the server to convert and stream videos in HTML5 on my VPS. The conversion is done by ffmpeg in the background and the contents is output to block.txt.
Having looked at the following posts :
Can ffmpeg show a progress bar ?
and
ffmpeg video encoding progress bar
amongst others, I can't find a working example.
I have always struggled with the regexes and maths, and I need to grab the currently encoded progress as a percentage.
The first post I linked above gives :
$log = @file_get_contents('block.txt');
preg_match("/Duration:([^,]+)/", $log, $matches);
list($hours,$minutes,$seconds,$mili) = split(":",$matches[1]);
$seconds = (($hours * 3600) + ($minutes * 60) + $seconds);
$seconds = round($seconds);
$page = join("",file("$txt"));
$kw = explode("time=", $page);
$last = array_pop($kw);
$values = explode(' ', $last);
$curTime = round($values[0]);
$percent_extracted = round((($curTime * 100)/($seconds)));
echo $percent_extracted;The $percent_extracted variable echoes zero, and as maths is not my strong point, I really don't know how to progress here.
Here's one line from the ffmpeg output from block.txt (if it's helpful)
time=00:19:25.16 bitrate= 823.0kbits/s frame=27963 fps= 7 q=0.0 size=
117085kB time=00:19:25.33 bitrate= 823.1kbits/s frame=27967 fps= 7
q=0.0 size= 117085kB time=00:19:25.49 bitrate= 823.0kbits/s
frame=27971 fps= 7 q=0.0 size= 117126kBPlease help me output this percentage, once done I can create my own progress bar. Thanks.
-
avformat_close_input memory leak ?
20 janvier 2021, par Keen JackdawI developed an app to push live stream with ffmpeg. When I checked the app with
leaks --atExit -- <the app="app"></the>
(I'm on mac), I found some memory leak with AVFormatContext.

The minimized code are provided below :


#include <iostream>

extern "C" {
#include <libavcodec></libavcodec>avcodec.h>
#include <libavformat></libavformat>avformat.h>
#include <libavdevice></libavdevice>avdevice.h>
}

void foo() {
 avdevice_register_all();

 AVFormatContext *avInputFormatContext = avformat_alloc_context();
 AVInputFormat *avInputFormat = av_find_input_format("avfoundation");
 std::cout << "open input" << std::endl;
 int ret = avformat_open_input(&avInputFormatContext, "Capture screen 0", avInputFormat, nullptr);
 if (ret < 0) { std::cout << "open input failed: " << ret << std::endl; return;}

 avformat_close_input(&avInputFormatContext);

}

int main() {
 foo();
 return 0;
}

</iostream>


The output is


Process: ffmpegtest [87726]
Path: /Users/USER/*/ffmpegtest
Load Address: 0x10a752000
Identifier: ffmpegtest
Version: ???
Code Type: X86-64
Platform: macOS
Parent Process: leaks [87725]

Date/Time: 2021-01-20 15:44:57.533 +0800
Launch Time: 2021-01-20 15:44:55.760 +0800
OS Version: macOS 11.1 (20C69)
Report Version: 7
Analysis Tool: /Applications/Xcode.app/Contents/Developer/usr/bin/leaks
Analysis Tool Version: Xcode 12.3 (12C33)

Physical footprint: 9.9M
Physical footprint (peak): 10.6M
----

leaks Report Version: 4.0
Process 87726: 14143 nodes malloced for 2638 KB
Process 87726: 1 leak for 32 total leaked bytes.

 1 (32 bytes) ROOT LEAK: 0x7f8c61e1b040 [32] length: 16 "Capture screen 0"



Did I miss something ?


-
split videos with ffmpeg
23 novembre 2020, par 5DiraptorI'm trying to create a script that scans a directory, and for all videos larger then X size, splits them down into smaller chunks.


There are two similar questions :


- 

- Using ffmpeg to split video files by size
- Split into equal parts and convert many mp4 videos using ffmpeg






Neither of these work in the way I want. The first you have to manually input every file that you want to process. The second doesn't check for filesize, or output the files in the way I want.


So far, this is the contents of the .bat file :


%~d1

for %%a in (*.MOV) do (

if %%~za GTR 2000000000 (

REM usage %%a <filename>
set "_filename=%~n1"
set "_tally=.SPLIT-%03d"
set "_extension=%~x1"

set "_outputname=%_filename%%_tally%%_extension%"


 ffmpeg -i "%%a" ^
 -crf 0 -c copy -map 0 -segment_time 00:00:30 -f segment -reset_timestamps 1 ^
 %_outputname%
)
)
pause
</filename>


My aim is for the script to work in the following way :


- 

- Drag a video (from a folder of videos) onto the .bat file.
- Script opens up, and targets each file ending
.MOV
, and is greater then 2GB - ffmpeg splits the video down into >2GB chunks. (I know it's currently split down in 30 second chunks, still working on understanding how to use the
-fs
parameter). - Each chunk gets saved with the original filename and extension, but the filename is suffixed with ".SPLIT" and then a unique number that relates to which file it is - first file is 000 and second is 001 etc.










Problems :


- 

- Firstly, I want to split by filesize and not time, but I don't understand how to use the -fs parameter in this case. I guess I could use something like
ffprobe -i input.file -show_format -v quiet | sed -n 's/duration=//p'
in conjunction with it but I'm not confident... - Secondly, I'm getting a problem with
%03d
in the .bat. Think I'm mixing up languages ? It retrieves the filepath of the .bat file instead of counting number of loops.






Any help really appreciated !