Recherche avancée

Médias (3)

Mot : - Tags -/plugin

Autres articles (63)

  • Dépôt de média et thèmes par FTP

    31 mai 2013, par

    L’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 (...)

  • Emballe Médias : Mettre en ligne simplement des documents

    29 octobre 2010, par

    Le plugin emballe médias a été développé principalement pour la distribution mediaSPIP mais est également utilisé dans d’autres projets proches comme géodiversité par exemple. Plugins nécessaires et compatibles
    Pour fonctionner ce plugin nécessite que d’autres plugins soient installés : CFG Saisies SPIP Bonux Diogène swfupload jqueryui
    D’autres plugins peuvent être utilisés en complément afin d’améliorer ses capacités : Ancres douces Légendes photo_infos spipmotion (...)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

Sur d’autres sites (7061)

  • Truncated prog_index.m3u8 in fluent-ffmpeg

    10 juillet 2020, par Hassnain Alvi

    I am creating a master playlist using fluent FFmpeg but the result prog_index.m3u8 contains last few entries it doesn't include full playlist data

    


    Here is the code for generating playlist

    


    const bitrate64 = ffmpeg("file.mp3").audioBitrate('64k');
    bitrate64.outputOptions([
        '-preset slow',
    '-g 48',
    "-map", "0:0",
        '-hls_time 6',
        '-master_pl_name master.m3u8',
        '-hls_segment_filename 64k/fileSequence%d.ts'
    ])
    .output('./64k/prog_index.m3u8')
    .on('progress', function(progress) {
        console.log('Processing 64k bitrate: ' + progress.percent + '% done')
    })  
    .on('end', function(err, stdout, stderr) {
        console.log('Finished processing 64k bitrate!')
    })
    .run() 


    


    Here is the output from prog_index.m3u8

    


    #EXTM3U
#EXT-X-VERSION:3
#EXT-X-TARGETDURATION:6
#EXT-X-MEDIA-SEQUENCE:1221
#EXTINF:5.990756,
fileSequence1221.ts
#EXTINF:6.013967,
fileSequence1222.ts
#EXTINF:5.990744,
fileSequence1223.ts
#EXTINF:6.013967,
fileSequence1224.ts
#EXTINF:5.953600,
fileSequence1225.ts
#EXT-X-ENDLIST


    


    when I run this command manually I get full index file but not with FFmpe. All .ts sequence files are correctly generated but. prog_index is not updated accordingly

    


    Can anyone tell me what I am doing wrong here ?

    


  • ffmpeg concatenate a large number of videos with different codecs and resolutions

    21 avril 2024, par Paul H

    The videos I am trying to concatenate can have different technical metadata, like codec, resolution, etc. So I wrote a filtergraph that works for my purposes. My complete command can look like this :

    



    ffmpeg -i "vid1.mp4" -i "vid2.mp4" -i "vid3.mp4" -filter_complex_script "filtergraph.txt" -map "[outv]" -map "[outa]" -c:v libx264 -r 60 -preset medium -crf 24 -c:a aac -b:a 160k "output.mp4"


    



    And "filtergraph.txt" looks like this (autogenerated by my own script before). I have the filters to change all input resolutions to Full HD. (Newlines in the following snippet are just introduced for readability, they are not contained in my filtergraph.txt)

    



    [0:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1[v0];
[1:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1[v1];
[2:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1[v2];
[v0][0:a][v1][1:a][v2][2:a]concat=n=3:v=1:a=1[outv][outa]


    



    Now in this case, it works, I have the three source videos, they can have different resolutions, codecs or even different framerates - they are all combinded into one Full HD 60 FPS output video.

    



    The problem is, that I want to concatenate a large number of video files and get the error, that the command contains too many characters for cmd. That's why I already put the filtergraph to a seperate file and read it using -filter_complex_script which works.

    



    But it can still get too long if I have a few hundred source files that I want to concat.

    



    As far as I tested it, I can't use -f concat -i listOfFiles.txt because every source file would have to be in the same codec, resolution etc then, and I could not use the filtergraph for scaling due to the fact that ffmpeg would try to concat before demuxed output goes into filter.

    



    So, how could I concat hundreds of videos while resizing them all to Full HD and applying the other filters, but keep the cmd line short ?

    



    Is there something similar to -filter_complex_script but for input files ? Or will I have to encode each source video to my desired target format first and then concat them with stream copy ?

    


  • How to encode with ffmpeg if number of images smaller than GOP size

    10 avril 2013, par theateist

    The code bellow creates mp4 video file from jpeg images. When number of images is greater than GOP size the encoding success and after 10th image gotPacket that returned by avcodec_encode_video2 is > 0.

    BUT when number of images is smaller than GOP size gotPacket is always = 0 and therefore no images written to the file.

    My guess is that avcodec_encode_video2 allocates buffer with length equals to GOP size and until it won't be full gotPacket will be 0.

    My question is how to force avcodec_encode_video2 to encode even if it's buffer is not full ?

    ...
    _outStream->codec.gop_size = 10;
    _outStream->codec.keyint_min = 10;
    ...

    AVFrame* frame = getFrame();


    AVPacket packet;
    av_init_packet(&packet);
    packet.data = NULL;
    packet.size = 0;

    int gotPacket = 0;
    if (avcodec_encode_video2(_outStream->codec, &packet, frame, &gotPacket) < 0)
       throw std::runtime_error("failed to encode frame");

    if (gotPacket)
    {
       ...
       if (av_write_frame(_outContainer.get(), &packet) < 0)
           throw std::runtime_error("failed to write frame");      
       av_free_packet(&packet);
    }