Recherche avancée

Médias (91)

Autres articles (37)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • Soumettre améliorations et plugins supplémentaires

    10 avril 2011

    Si vous avez développé une nouvelle extension permettant d’ajouter une ou plusieurs fonctionnalités utiles à MediaSPIP, faites le nous savoir et son intégration dans la distribution officielle sera envisagée.
    Vous pouvez utiliser la liste de discussion de développement afin de le faire savoir ou demander de l’aide quant à la réalisation de ce plugin. MediaSPIP étant basé sur SPIP, il est également possible d’utiliser le liste de discussion SPIP-zone de SPIP pour (...)

  • Ajouter notes et légendes aux images

    7 février 2011, par

    Pour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
    Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
    Modification lors de l’ajout d’un média
    Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)

Sur d’autres sites (3795)

  • Making a movie out of pictures in correct order

    6 novembre 2022, par astrogab

    Short version

    


    How can one combine files img1000.png, img5000.png, img10000.png, img11000.png in the right order into a movie ?

    


    Longer version

    


    I am using ffmpeg to make a movie out of snapshots of a simulation. There should be for instance 5 images per second. The names are :

    


    image0200.png
image0300.png
image0400.png
image0500.png
image1000.png
image1500.png
image2000.png
...
image8500.png
image9000.png
image9500.png
image10000.png
image15000.png


    


    i.e., they are sequential but there are irregular gaps in the numbers. The numbers are formatted according to '%04d' but go above 9999. I have tried

    


    ffmpeg -y -loglevel debug -nostats \
-r:v 5 -thread_queue_size 1024 -f image2 \
-pattern_type glob -i "*[0-9][0-9][0-9][0-9].png" \
-r:v 30 -preset veryslow -pix_fmt yuv420p -crf 28 \
-an  AMDG.mp4


    


    and many, many other variations but either only two frames end up being visible in the movie (even though the images are found when using -debug) or only the files up to image9500.png are used (and glob does not seem to allow [0-9]{4,} as for regex), or, with

    


        ffmpeg -y -loglevel debug -nostats \
    -r:v 5 \
    -thread_queue_size 1024 -f image2 -pattern_type glob \
       -i "image[0-9][0-9][0-9][0-9].png" \
    -r:v 5 \
    -thread_queue_size 1024 -f image2 -pattern_type glob \
       -i "image[1-9][0-9][0-9][0-9][0-9].png" \
    -r:v 30 -preset veryslow -pix_fmt yuv420p -crf 28 \
    -map 0 -map 1 \
    -an  AMDG.mp4


    


    there are apparently two streams in the output movie and only one of them is being played. (I realised in the process -map 0 -map 1 was needed in order for both input streams to be used.)

    


    In one of the variations of options I found (now I have lost what it was exactly !) all images were included but the order was not the desired one : image1000.png was shown before image10000.png. Apparently a newer version of ffmpeg (I have ffmpeg version 3.4.8-0ubuntu0.2) has the ability to sort like sort -V, so that image10000 come after image1000, but reinstalling ffmpeg is in general not a practical option. Also renaming the files is not practical and creating e.g. soft links with sequential names in the format '%05d' starting at 0 and in steps of 1 (so that -i '%05d' could be used) is of course not elegant.

    


    With the -concat filter as in https://unix.stackexchange.com/questions/77016/ffmpeg-pattern-type-glob-not-loading-files-in-correct-order, i.e.,

    


      ffmpeg -y -loglevel debug -nostats -r:v 5 \
    -thread_queue_size 1024 -f image2 -f concat \
    -safe 0 -i <(find . -maxdepth 1 -regex 'image*.png' \
       -exec echo "file $(pwd)/"{} \; | sort -V) \
    -r:v 30 -codec:v libx264 -preset veryslow -pix_fmt yuv420p -crf 28 \
    -an \
    AMDG.mp4


    


    the processing took a long time and made the whole system sluggish, while producing a movie of 60 kB showing only two different images.

    


    I have the impression that there are several issues at once... Thanks if you can help !

    


  • h264 : Fix direct temporal mvs for bottom-field-first poc order

    18 juillet 2014, par Ronald S. Bultje
    h264 : Fix direct temporal mvs for bottom-field-first poc order
    

    Such files can be created using the —bff x264 option.

    Sample-Id : h264_direct_temporal_mvs_bff.mkv
    Signed-off-by : Luca Barbato <lu_zero@gentoo.org>
    Signed-off-by : Vittorio Giovara <vittorio.giovara@gmail.com>

    • [DH] libavcodec/h264_direct.c
  • Change the frame order/sequence of a video (avconv/ffmpeg)

    2 novembre 2014, par Simon Streicher

    I want to use Python and a similar method explained by http://zulko.github.io/blog/2013/09/27/read-and-write-video-frames-in-python-using-ffmpeg :

    import subprocess as sp
    command = [ 'ffmpeg',
           '-y', # (optional) overwrite output file if it exists
           '-f', 'rawvideo',
           '-vcodec','rawvideo',
           '-s', '420x360', # size of one frame
           '-pix_fmt', 'rgb24',
           '-r', '24', # frames per second
           '-i', '-', # The imput comes from a pipe
           '-an', # Tells FFMPEG not to expect any audio
           '-vcodec', 'mpeg'",
           'my_output_videofile.mp4' ]

    pipe = sp.Popen( command, stdin=sp.PIPE, stderr=sp.PIPE)
    pipe.proc.stdin.write(image_array.tostring())

    to write an image array as frames to ffmpeg. In my application I will write the frames to the buffer as they are completed (not all at once as above).

    want to apply time-distortion to the output video from a "frame-map" :

    Frame order In : [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
    Frame order Out: [1, 1, 2, 3, 3.5, 4, 4.5, 6, 7, 8, 9.5 10]

    Is there any way I can pipe in the frame sequence ?

    I know I can just program my script to sent the frames in the correct order, but I was kind of hoping to discard the frames as I am done with them (I am talking about long HD videos) and let avconv/ffmpeg handle the ordering and inter-frame averaging (for example frame 3.5).

    My other option is to read the input frames at the output frame speed (by playing catchup) and keep the last 300 frames or so. Beforehand I can make sure my pipe wouldn’t need a 301-or-more-frames-back frame. I can even make it more robust by keeping track of any 301-or-more-frames-back frames and make an exception for storing them.

    So could ffmpeg/avconv handle all this drama on its own, or do I have to code this up ?