Recherche avancée

Médias (1)

Mot : - Tags -/biographie

Autres articles (45)

  • Other interesting software

    13 avril 2011, par

    We don’t claim to be the only ones doing what we do ... and especially not to assert claims to be the best either ... What we do, we just try to do it well and getting better ...
    The following list represents softwares that tend to be more or less as MediaSPIP or that MediaSPIP tries more or less to do the same, whatever ...
    We don’t know them, we didn’t try them, but you can take a peek.
    Videopress
    Website : http://videopress.com/
    License : GNU/GPL v2
    Source code : (...)

  • MediaSPIP Core : La Configuration

    9 novembre 2010, par

    MediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
    Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...)

  • Gestion des droits de création et d’édition des objets

    8 février 2011, par

    Par 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 ;

Sur d’autres sites (7270)

  • FFmpeg drawtext over multiple lines

    26 août 2023, par Jay

    I have the code :

    


    import subprocess , os

ffmpeg = "C:\\ffmpeg_10_6_11.exe"
inVid = "C:\\test_in.avi"
outVid = "C:\\test_out.avi"

if os.path.exists( outVid ):
os.remove( outVid )
proc = subprocess.Popen(ffmpeg + " -i " + inVid + ''' -vf drawtext=fontfile=/Windows/Fonts/arial.ttf:text="onLine1 onLine2 onLine3":fontcolor=white:fontsize=20 -y ''' + outVid , shell=True, stderr=subprocess.PIPE)
proc.wait()
print proc.stderr.read()
os.startfile( outVid )


    


    to write text to a video file. But I want to write out many lines of text instead of just having it all on the one line.

    


    How can I do that ?

    


  • FFmpeg drawtext over multiple lines

    22 novembre 2015, par Jared Glass

    I have the code :

    import subprocess , os

    ffmpeg = "C:\\ffmpeg_10_6_11.exe"
    inVid = "C:\\test_in.avi"
    outVid = "C:\\test_out.avi"

    if os.path.exists( outVid ):
    os.remove( outVid )
    proc = subprocess.Popen(ffmpeg + " -i " + inVid + ''' -vf drawtext=fontfile=/Windows/Fonts/arial.ttf:text="onLine1 onLine2 onLine3":fontcolor=white:fontsize=20 -y ''' + outVid , shell=True, stderr=subprocess.PIPE)
    proc.wait()
    print proc.stderr.read()
    os.startfile( outVid )

    to write text to a video file. But I want to write out many lines of text instead of just having it all on the one line.

    Pls help. Thanks

  • How to optimize encoding and packaging videos using ffmpeg and shaka-packager

    16 novembre 2020, par Saidamir Botirov

    I'm trying to encode and package uploaded videos for an LMS website where video size may differ. How can I write a sh script that converts and packages the given video based on its size (For ex. if the given video resolution is bigger than 720p and less than 1080p FFmpeg should convert videos in 2 sizes [360p, 720p] then shaka-packager should package them).

    


    So far I have this script assuming that input video resolution is 1080p (or 1080p <= size < 4k)

    &#xA;

    #!/bin/sh&#xA;pwd&#xA;URL="$1"&#xA;ID="$2"&#xA;FOLDER="$3"&#xA;&#xA;if [ -z "$URL" ];then&#xA;    echo "Must input a file"&#xA;    $SHELL&#xA;    exit&#xA;fi&#xA;&#xA;DIR="$FOLDER/$ID"&#xA;OUTDIR="$DIR/cmaf"&#xA;mkdir -p -v $DIR&#xA;mkdir -p -v $OUTDIR&#xA;&#xA;GOP_SIZE=50&#xA;FPS=25&#xA;CRF=28&#xA;&#xA;INPUT="$DIR/input"&#xA;wget -c -O $INPUT $URL &amp;&amp;&#xA;&#xA;if [ ! -f $FILE ]; then&#xA;    echo "$FILE does not exists"&#xA;    $SHELL&#xA;    exit&#xA;fi&#xA;&#xA;ffmpeg -i $INPUT -y \&#xA;-threads 1 \&#xA;-c:v libx264 -crf $CRF -profile:v high -pix_fmt yuv420p \&#xA;-keyint_min $GOP_SIZE -g $GOP_SIZE -sc_threshold 0 \&#xA;-color_primaries 1 -color_trc 1 -colorspace 1 -movflags &#x2B;faststart \&#xA;-c:a aac -b:a 128k -ar 44100 \&#xA;-r $FPS \&#xA;"$DIR/input.mp4" &amp;&amp;&#xA;&#xA;ffmpeg -i "$DIR/input.mp4" -y \&#xA;-threads 1 \&#xA;-vn -acodec copy "$DIR/a.mp4" \&#xA;-vf scale=640:360 -an "$DIR/360p.mp4" \&#xA;-vf scale=1280:720 -an "$DIR/720p.mp4" \&#xA;-vf scale=1920:1080 -an "$DIR/1080p.mp4" &amp;&amp;&#xA;&#xA;rm -R $OUTDIR&#xA;&#xA;packager \&#xA;in="$DIR/a.mp4",stream=audio,output="$OUTDIR/a.mp4",drm_label=AUDIO \&#xA;in="$DIR/360p.mp4",stream=video,output="$OUTDIR/360p.mp4",drm_label=SD \&#xA;in="$DIR/720p.mp4",stream=video,output="$OUTDIR/720p.mp4",drm_label=HD \&#xA;in="$DIR/1080p.mp4",stream=video,output="$OUTDIR/1080p.mp4",drm_label=HD \&#xA;--enable_raw_key_encryption \&#xA;--keys label=AUDIO:key_id=f3c5e0761e6654b28f8049c778b23947:key=a4637a153a443df9eed0593043db7517,label=SD:key_id=abba277e8bcf552bbd2e86a434a9a5d7:key=69eaa807a6763af979e8d1940fb88397,label=HD:key_id=6d76f25cb17f5e76b8eaef6b7f582d87:key=cb541784c99737aef4fff74500c12ea7 \&#xA;--pssh 000000377073776800000000EDEF8BA979D64ACEA3C877DCD51D21ED00000071220F7465737420636F6E74656E74206967 \&#xA;--mpd_output "$OUTDIR/h264.mpd" \&#xA;--hls_master_playlist_output "$OUTDIR/h264_master.m3u8"&#xA;

    &#xA;

    The above script first downloads a video by a given URL then converts it to appropriate video format before resizing and packaging. I assumed if I convert the video before scaling would be more performant than every time converting and resizing it. Also, I assumed if I resize to all resolutions in one command it would be much faster, but I think that is not how FFmpeg works. I'm stack in the world of FFmpeg not knowing how to write sh(or bash) script better, cleaner and dynamic for encoding and packaging videos for online streaming. I think there are others with the same problem or the same case. So any help, fix and recommendation is appreciated

    &#xA;