Recherche avancée

Médias (0)

Mot : - Tags -/page unique

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (100)

  • Submit bugs and patches

    13 avril 2011

    Unfortunately a software is never perfect.
    If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information : the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
    If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
    You may also (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

  • Activation de l’inscription des visiteurs

    12 avril 2011, par

    Il est également possible d’activer l’inscription des visiteurs ce qui permettra à tout un chacun d’ouvrir soit même un compte sur le canal en question dans le cadre de projets ouverts par exemple.
    Pour ce faire, il suffit d’aller dans l’espace de configuration du site en choisissant le sous menus "Gestion des utilisateurs". Le premier formulaire visible correspond à cette fonctionnalité.
    Par défaut, MediaSPIP a créé lors de son initialisation un élément de menu dans le menu du haut de la page menant (...)

Sur d’autres sites (11496)

  • ffmpeg one draw text to multiple outputs

    31 juillet 2023, par kRicha

    I've created command with ffmpeg-fluent, which connects video file with music, use shortest(video) duration, and output this to result file

    


    const newVideo = Ffmpeg(`./source/video/${category}/${dayNumber}.mp4`)
                .addInput(`./source/audio/${category}.mp3`)
                .addOption([
                    '-map 0:v:0',
                    '-map 1:a:0',
                    '-shortest'
                ]);

            newVideo.videoFilters({
                filter: 'drawtext',
                options: { ...FONT_OPTIONS, ...{ text: '1', boxcolor: 'black@1', y: 280 } }
            }).output('out1.mp4')
                .output('out2.mp4');


    


    generated command line :

    


    ffmpeg \
-i ./source/video/women/1.mp4 \
-i ./source/audio/women.mp3 -y \
-filter:v drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=1:boxcolor=black@1:y=280,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=a0:boxcolor=black@0.8:enable='between(t,0,6.5)':y=700,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=a1:boxcolor=black@0.8:enable='between(t,0,6.5)':y=800,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=a2:boxcolor=black@0.8:enable='between(t,0,6.5)':y=900,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=a3:boxcolor=black@0.8:enable='between(t,0,6.5)':y=1000,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=b0:boxcolor=black@0.8:enable='between(t,7,10)':y=1000,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=b1:boxcolor=black@0.8:enable='between(t,7,10)':y=1100,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=b2:boxcolor=black@0.8:enable='between(t,7,10)':y=1200,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=b3:boxcolor=black@0.8:enable='between(t,7,10)':y=1300,drawtext=fontsize=80:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=b4:boxcolor=black@0.8:enable='between(t,7,10)':y=1400,drawtext=fontsize=30:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=c:enable='between(t,10.2,inf)':boxcolor=black@1:y=1500,drawtext=fontsize=30:fontcolor=white:x=(w-tw)/2:box=1:boxborderw=20:fontfile=./OpenSans-Light.ttf:text=d:enable='between(t,10.2,inf)':boxcolor=black@1:y=1550 \
-map 0:v:0 \
-map 1:a:0 \
-shortest out2/_.mp4


    


    if I add second output it works, but without audio and drawtext ? How could I fixe this and get draw text works on both outputs

    


  • Different filesizes for images generated using octave and python

    17 décembre 2020, par lakshayg

    I am using python (scikit-image) and octave to generate 200 images as follows

    


    Python3

    


    import numpy as np
from skimage.io import imsave

images = [255*np.ones((100,100), dtype=np.uint8),  # white
             np.zeros((100,100), dtype=np.uint8)]  # black

for i in range(200): # save alternating black and white images
    imsave('%04d.png'%(i+1), images[i%2])


    


    Octave

    


    pkg load image;

im1 = 255*ones(100,100); # white
im2 = zeros(100,100);    # black
for i=1:200
    name = sprintf('%04d.png', i);
    if mod(i,2) == 0
        imwrite(im1, name);
    else
        imwrite(im2, name);
    end
end


    


    Next, I use ffmpeg to generate two videos (alternating white and black frames) from these two sets of images using the following command

    


    ffmpeg -r 10 -loglevel quiet \
       -i ./%04d.png -c:v libx264 \
       -preset ultrafast -crf 0 ./out.mkv


    


      

    1. Sizes of image files generated by both these codes are different.
    2. 


    


      

    • Octave white : 192 bytes, black : 98 bytes
    • 


    • Python white : 120 bytes, black : 90 bytes
    • 


    


      

    1. Sizes of video files generated from these octave and python images are significantly different from each other.
    2. 


    


      

    • Octave filesize : 60 kilobytes
    • 


    • Python filesize : 116 kilobytes
    • 


    


    Why do we have this apparently very strange behavior ?

    


    EDIT

    


    Since it was suggested that the behavior might be due to octave and python using different bit-depths to store the images, I changed the octave code to use 8 bit numbers

    


    im1 = uint8(255*ones(100,100)); # white
im2 = uint8(zeros(100,100));    # black


    


    and now the image file sizes are nearly the same

    


      

    • Octave white : 118 bytes, black : 90 bytes
    • 


    • Python white : 120 bytes, black : 90 bytes
    • 


    


    but the problem is still the same for video files, octave : 60K, python : 116K

    


  • How do I chromakey an enclosed shape (or background) in ffmpeg ? [closed]

    31 janvier, par JustAnotherCodemonkey

    I have an animation with a fully contiguous 0xFFFFFF white background I want to remove. The issue is that the foreground contains the same exact color. These parts are all completely enclosed and contained within at least several pixels of a different shade at its weakest.

    


    All I need is to be able to essentially, for each frame, make all pixels that are white and connected by white to 0,0, transparent. Chromakey and its siblings remove those bits from the foreground as well which is unacceptable and backgroundkey, well you can imagine how that goes.

    


    I'm somewhat proficient with ffmpeg and can handle severe filter shenanigans, I've just thought about this for like 10 min and decided I seemingly don't have the creativity to piece together a clever solution. I just don't want to have to spend some time sitting down and manually writing out a program to do this frame-by-frame.