Recherche avancée

Médias (21)

Mot : - Tags -/Nine Inch Nails

Autres articles (56)

  • 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

  • Librairies et binaires spécifiques au traitement vidéo et sonore

    31 janvier 2010, par

    Les logiciels et librairies suivantes sont utilisées par SPIPmotion d’une manière ou d’une autre.
    Binaires obligatoires FFMpeg : encodeur principal, permet de transcoder presque tous les types de fichiers vidéo et sonores dans les formats lisibles sur Internet. CF ce tutoriel pour son installation ; Oggz-tools : outils d’inspection de fichiers ogg ; Mediainfo : récupération d’informations depuis la plupart des formats vidéos et sonores ;
    Binaires complémentaires et facultatifs flvtool2 : (...)

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

Sur d’autres sites (7813)

  • how to make the script re-ask for the input again after failure ?

    6 avril 2022, par Rami Magdi

    this some script for ffmpeg that i added to windows context menu
so i just copy paste what i want done
when this .bat fails [wrong argument for instance ] it closes and i have to restart it
how to make the script re-ask for the input again after failure ?

    


    @echo off
echo    -------------------------------------------------------------
echo                             FILTERS
echo    -------------------------------------------------------------
echo,
echo   VERTICAL FLIP=    -lavfi vflip
echo   HORIZONTAL FLIP=  -lavfi hflip
echo   NEGAT COLORS=     -lavfi Enegate
echo   NEGATE LUMINANCE= -lavfi lutyuv=y=negval
echo   GRAYSCALE=        -lavfi hue=s=0
echo   ISOLATE COLOR=    -lavfi colorhold=color="orange":similarity=0.29:blend=0
echo   PS CURVES PRESET= -lavfi curves=psfile='MyCurvesPresets/purple.acv'
echo   VIGNETTE EFFECT=  -lavfi vignette=PI/4
echo   LOOKUP TABLE=     -lavfi lut3d=c\\:/nnn/ggg.cube
echo   SPEED UP OR SLOW DOWN=    -lavfi setpts=PTS/2
echo   SPEED UP VIDEOS, AUDIOS=  -lavfi "[0:v]setpts=PTS/2[v];[0:a]atempo=2.0[a]" -map "[v]" -map "[a]"
echo   REVERSE=     -lavfi reverse
echo   POSTERIZE=   -lavfi elbg=l=8:n=1
echo   MOTION BLUR= -lavfi tmix=frames=20:weights="10 1 1"
echo   HARD SUB=    -lavfi subtitles=s.ass
echo   SOFT SUB=    -scodec mov_text -metadata:s:s:0 language=eng
echo   ONE IMAGE=   -lavfi -frames 1
echo   AN IMAGE EVERY 60 SEC= -lavfi fps=1/60
echo   ONLY IFRAMES= -skip_frame nokey
echo   GIF=    -lavfi "fps=10,scale=320:-2:flags=lanczos,split[s0][s1];[s0]palettegen[p];[s1][p]paletteuse" -loop 0
echo   STACKS= -lavfi "[0:v][1:v][2:v][3:v]xstack=inputs=4:layout=0_0|w0_0|0_h0|w0_h0[v]" -map "[v]"
echo   EMBED THUMBNAIL = -i 1.jpg -map 0:0 -map 0:1 -map 1 -c:0 copy -c:v:1 png -disposition:v:1 attached_pic
ECHO,
echo    -------------------------------------------------------------
echo                             CODEC OPTIONS
echo    -------------------------------------------------------------
echo,
echo   -lavfi "[0:v]scale=-2:720,setpts=PTS/1.5[v];[0:a]atempo=1.5[a]" -map "[v]" -map "[a]" -crf 40 -preset ultrafast
echo   -map 0 -codec copy
echo   -acodec copy -vcodec libx264 -vsync cfr -crf 20 -pix_fmt yuv420p -tune film -preset veryfast -movflags +faststart
echo   -acodec aac -ac 2 -ab 128k -ar 44100 / -acodec libmp3lame -ab 320k -ar 44100 -id3v2_version 3 
echo   -qscale:v 2
echo,


    


    the main part :

    


    set /P extra="ENTER CODEC OPTIONS="

echo,
echo Processing "%~nx1"
echo Output will be "%~n1"_output.mp4"
ffmpeg -v error -stats -y -i "%~1"  %extra%  "%~n1"_output.mp4
pause


    


  • After ffmpeg encode, AVPacket pts and dts is AV_NOPTS_VALUE

    29 novembre 2017, par Li Zehan

    I would like to ask a question about ffmpeg when i use encoder (x264).

    this is my code :

    int
    FFVideoEncoder::init(AVCodecID codecId, int bitrate, int fps, int gopSize,
                        int width, int height, AVPixelFormat format) {
       release();

       const AVCodec *codec = avcodec_find_encoder(codecId);
       m_pCodecCtx = avcodec_alloc_context3(codec);
       m_pCodecCtx->width = width;
       m_pCodecCtx->height = height;
       m_pCodecCtx->pix_fmt = format;
       m_pCodecCtx->bit_rate = bitrate;
       m_pCodecCtx->thread_count = 5;
       m_pCodecCtx->max_b_frames = 0;
       m_pCodecCtx->gop_size = gopSize;

       m_pCodecCtx->time_base.num = 1;
       m_pCodecCtx->time_base.den = fps;

       //H.264
       if (m_pCodecCtx->codec_id == AV_CODEC_ID_H264) {
    //        av_dict_set(&opts, "preset", "slow", 0);
           av_dict_set(&m_pEncoderOpts, "preset", "superfast", 0);
           av_dict_set(&m_pEncoderOpts, "tune", "zerolatency", 0);

           m_pCodecCtx->flags |= CODEC_FLAG_GLOBAL_HEADER;
           m_pCodecCtx->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
       }
       int ret = avcodec_open2(m_pCodecCtx, m_pCodecCtx->codec, &m_pEncoderOpts);
       if (ret == 0) {
           LOGI("open avcodec success!");
       } else {
           LOGE("open avcodec error!");
           return -1;
       }
       return ret;
    }

    int FFVideoEncoder::encode(const Frame &inFrame, AVPacket *outPacket) {
       AVFrame *frame = av_frame_alloc();
    //    avpicture_fill((AVPicture *) frame, inFrame.getData(), AV_PIX_FMT_YUV420P, inFrame.getWidth(),
    //                   inFrame.getHeight());
       av_image_fill_arrays(frame->data, frame->linesize, inFrame.getData(), m_pCodecCtx->pix_fmt,
                            inFrame.getWidth(), inFrame.getHeight(), 1);

       int ret = 0;
       ret = avcodec_send_frame(m_pCodecCtx, frame);
       if (ret != 0) {
           LOGE("send frame error! %s", av_err2str(ret));
       } else {
           ret = avcodec_receive_packet(m_pCodecCtx, outPacket);
           LOGI("extract data size = %d", m_pCodecCtx->extradata_size);
           if (ret != 0) {
               LOGE("receive packet error! %s", av_err2str(ret));
           }
       };
       av_frame_free(&frame);
       return ret;
    }

    I expect that the AVPacket will carry the pts and dts about this frame.

    but in fact, i only can get encoded frame data and size.

    //====================================

    except this question, i have another quesiont :

    x264 docs say that "tune" opts can be set like film、animation and others. but i only can get a normal video when i set "zerolatency" params. When i set others opts, video’s bitrate is very low.

    Thanks your answer.

  • Révision 103307 : - Les plugins-dist de spip 3.2 ne sont pas supposé avoir de support pour qu’il f...

    17 mars 2017, par spip.franck@lien-d-amis.net

    - La version de mini de compatibilité est maintenant 3.2.0-dev, comme, ça, quand l’alpha sortira, cela devrait être bon (quand la version 3.2.0 stable sortira, je mettrais 3.2.0 comme version mini)
    - Il y avait aussi un ou deux mots avec des accents comme par exemple è j’ai fait le changement pour y mettre à la place è ou autres