Recherche avancée

Médias (1)

Mot : - Tags -/book

Autres articles (13)

  • 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 (...)

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

  • Les vidéos

    21 avril 2011, par

    Comme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
    Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
    Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...)

Sur d’autres sites (4049)

  • Stack AVFrame side by side (libav/ffmpeg)

    22 février 2018, par dronemastersaga

    So I am trying to combine two H264 livestreams of 1920x1080 resolution side-by-side to a livestream of 3840x1080 resolution.

    For this, I can decode streams to AVFrames in libav/FFmpeg that I would like to combine into a bigger frame. The Input AVFrames : Two 1920x1080 frames in NV12 format (description : planar YUV 4:2:0, 12bpp, 1 plane for Y and 1 plane for the UV components, which are interleaved (first byte U and the following byte V))

    The way I have figured out is with colorspace conversion (YUV to BGR) in libav, then to change it to OpenCV Mat, then to use hconcat in OpenCV to stack together, then colorspace conversion (BGR to YUV) in AVFormat.

    Below is the method currently being used :

    //Prior code is too long: Basically it decodes 2 streams to AVFrames frame1 and frame2 in a loop
    sws_scale(swsContext, (const uint8_t *const *) frame1->data, frame1->linesize, 0, 1080, (uint8_t *const *) frameBGR1->data, frameBGR1->linesize);
    sws_scale(swsContext, (const uint8_t *const *) frame2->data, frame2->linesize, 0, 1080, (uint8_t *const *) frameBGR2->data, frameBGR2->linesize);
    Mat matFrame1(1080, 1920, CV_8UC3, frameBGR1->data[0], (size_t) frameBGR1->linesize[0]);
    Mat matFrame2(1080, 1920, CV_8UC3, frameBGR2->data[0], (size_t) frameBGR2->linesize[0]);
    Mat fullFrame;
    hconcat(matFrame1, matFrame2, fullFrame);
    const int stride[] = { static_cast<int>(fullFrame.step[0]) };
    sws_scale(modifyContext, (const uint8_t * const *)&amp;fullFrame.data, stride, 0, fullFrame.rows, newFrame->data, newFrame->linesize);
    //From here, newFrame is sent to the encoder
    </int>

    The resulting image is satisfactory but it does lose quality in colorspace conversion. However this method is too slow to use (I’m at 15 fps and I need 30). Is there a way to stack AVFrames directly without colorspace conversion ? Or is there any better way to do this ? I searched a lot about this and I couldn’t find any solution to this. Please advise.

  • FFMPEG, resize and pad a video by and odd number of pixels ?

    18 février 2018, par Jules

    I’m trying to resize and pad a video from 1917 x 1080 to 1920 x 1080.

    I’ve tried various syntax, which works but doesn’t change the size.

    ffmpeg -i input.mp4 -filter:v scale=1920:1080,pad=1920:1080 -c:a copy output.mp4

    However, I have go to this point by resize, joint audio and rotate. The initial size is 640 x 1136, I believe this is the source of the problem.

    ffmpeg -i input.mp4 -filter:v scale=900:1200 -c:a copy output.mp4

    ffmpeg \
    -i input.m4a \
    -i resize.mp4 -acodec copy -vcodec copy -shortest \
    output.mp4

    ffmpeg -i input.mp4" -vf "transpose=2" output/mp4

    So I’m wondering if I should do something different earlier

  • ffmpeg scale/forcing fixed video resolution issue

    31 janvier 2018, par Massimo Vantaggio

    I try to be sure that the video comes out with a resolution of 1920 x1080,
    If not the encoding must force this resolution.
    I need this to create fine adaption set from a video input with standard resolution (HD).

    Im unable to get always this resolution, for example with a movie of
    1920 x 1040 i get 1993 x 1080

    , below my ffmpeg command line :

    ffmpeg -y -i $name -i logo1080.png -c:a aac -b:a 256k -ar 48000 -ac 2 -async 1 -c:v libx264 -x264opts keyint=$GOP:min-keyint=$GOP:no-scenecut -bf 0 -r $FPSC -b:v 2400k -maxrate 2400k -bufsize 1200k -profile:v main -t $FDUR -filter_complex "[0:v][1:v]overlay=main_w-overlay_w-10:10,scale=1920:1080" format1080.mp4

    I tried every possibility that the ffmpeg scale page tells, without understand how to fix it.
    I think i need some help,
    Thanks,
    Massimo