Recherche avancée

Médias (2)

Mot : - Tags -/kml

Autres articles (88)

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

  • Organiser par catégorie

    17 mai 2013, par

    Dans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
    Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
    Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...)

  • Récupération d’informations sur le site maître à l’installation d’une instance

    26 novembre 2010, par

    Utilité
    Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
    Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...)

Sur d’autres sites (10460)

  • ffmpeg options to stream to Youtube

    24 octobre 2022, par David Goncalves

    Please bear with me as I don't really understand most of the commands behind ffmpeg.

    


    I am using this code to live stream from a raspberry 4B with a USB Logitech C920 to YouTube :
ffmpeg -re -f s16le -i /dev/zero -f v4l2 -thread_queue_size 512 -codec:v h264 -s 1920x1080 -i /dev/video0 -codec:v copy -acodec aac -b:v 128k -g 60 -f flv rtmp ://a.rtmp.youtube.com/live2/[key]

    


    The streaming works but I get the following error in the command line :
Non-monotonous DTS in output stream 0:0 ; previous : 0, current : -167 ; changing to 0. This may result in incorrect timestamps in the output file.

    


    I also get this error in Youtube studio :
Please use a keyframe frequency of four seconds or less. Currently, keyframes are not being sent often enough, which can cause buffering. The current keyframe frequency is 8.0 seconds. Note that ingestion errors can cause incorrect GOP (group of pictures) sizes.
Any help ?

    


  • Image generated by System.Drawing.Image is 10x larger than original file

    13 mai 2021, par Ninbura

    I've written a Powershell script that extracts one frame from a dshow capture device using FFmpeg, and then copies the output image from a file to my clipboard :

    


    $screenshot = [System.Drawing.Image]::FromFile((Get-Item -Path $outputFilePath))
[System.Windows.Forms.Clipboard]::SetImage($screenshot)
$screenshot.Dispose()


    


    The original file is a 1MB JPEG, but the image in my clipboard is an 11MB PNG. When I go to paste this file into something like Discord the file size is too large, unless you have Discord Nitro.

    


    Is there any way to avoid this file size inflation while using [System.Drawing.Image]::FromFile() ?

    


    Here's an easy test template :

    


    Add-Type -AssemblyName System.Drawing
Add-Type -AssemblyName System.Windows.Forms

$screenshot = [System.Drawing.Image]::FromFile((Get-Item -Path "Path to picture"))
[System.Windows.Forms.Clipboard]::SetImage($screenshot)
$screenshot.Dispose()


    


    Edit 2021/05/13 :

    


    Interestingly, it's starting to seem like this is a limitation of copying an image to a clipboard. I decided to dig deeper and see if the image size was increasing when I drew the image with System.Drawing.Image or when I pushed it in my clipboard with System.Windwos.Forms.Clipboard. If I save the image before putting it my clipboard like so, it retains the original file size, even if I change the extension to png :

    


    Add-Type -AssemblyName System.Drawing
Add-Type -AssemblyName System.Windows.Forms

$screenshot = [System.Drawing.Image]::FromFile((Get-Item -Path "C:\Users\gabri\Pictures\FFScreenshots\2021-05-12 19-04-26.845.jpeg"))
$screenshot.Save("C:\Users\gabri\Pictures\FFScreenshots\test.jpeg") # test.png makes no difference
$screenshot.Dispose()


    


    So it would seem that the image grows exponentially in size specifically when I push it to my clipboard. I verified this by simply uploading an image to Discord, copying it to my clipboard (click image > Open original > right click and copy result), and uploading it again. Sure enough, the new image pasted from my clipboard was around 10x the size of the original image (1MB vs 12MB). I wondered if this was a "limitation" of Windows so I ran the same test on Ubuntu 20.04. Uploaded an image to Discord, copied the image to my clipboard, and uploaded it again. Once again the image was about 10x larger, though slightly smaller than then when I uploaded the image from my clipboard on my Windows machine (11.4MB VS 12MB). Just to make sure this wasn't limited to Discord, I ran the same test with Gmail in-browser on both operating systems, same result.

    


    Alas, there appears to be something happening when you copy an image to a clipboard that drastically increases file size. One thing's for sure, whatever's happening is definitely over my head.

    


  • Overlay gif on image using ffmpeg in android [duplicate]

    18 juin 2019, par Sagar Poshiya

    I am trying to overlay gif on Image and save it as Video. And use ffmpeg to do this but getting this error :

    Command

    String strFilter = "[1:v]scale=h="+ 150 +":w=" + 150 + "[overlay_scaled],"
                           + "[0:v][overlay_scaled]overlay=eval=init:x=W*" + 0
                           + ":y=H*" + 0;

    String[] bb = new String[]{ "-i", inputFile,"-itsoffset", "0", "-i", inputGif, "-filter_complex", strFilter, "-preset", "ultrafast", "-g", "120", outputFile };

    Here

    • inputFile is png image
    • inputGif is gif image
    • outputFile is mp4 Video

    Log

    06-17 18:09:38.201 989-989/com.photo.editor E/FFmpeg ERROR::::::: ffmpeg version n3.0.1 Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 4.8 (GCC)
     configuration: --target-os=linux --cross-prefix=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/bin/arm-linux-androideabi- --arch=arm --cpu=cortex-a8 --enable-runtime-cpudetect --sysroot=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/sysroot --enable-pic --enable-libx264 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-fontconfig --enable-pthreads --disable-debug --disable-ffserver --enable-version3 --enable-hardcoded-tables --disable-ffplay --disable-ffprobe --enable-gpl --enable-yasm --disable-doc --disable-shared --enable-static --pkg-config=/home/vagrant/SourceCode/ffmpeg-android/ffmpeg-pkg-config --prefix=/home/vagrant/SourceCode/ffmpeg-android/build/armeabi-v7a --extra-cflags='-I/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/include -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all' --extra-ldflags='-L/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/lib -Wl,-z,relro -Wl,-z,now -pie' --extra-libs='-lpng -lexpat -lm' --extra-cxxflags=
     libavutil      55. 17.103 / 55. 17.103
     libavcodec     57. 24.102 / 57. 24.102
     libavformat    57. 25.100 / 57. 25.100
     libavdevice    57.  0.101 / 57.  0.101
     libavfilter     6. 31.100 /  6. 31.100
     libswscale      4.  0.100 /  4.  0.100
     libswresample   2.  0.101 /  2.  0.101
     libpostproc    54.  0.100 / 54.  0.100
    Input #0, png_pipe, from '/storage/emulated/0/Pictures/MyCameraApp/IMG_20190617_180929.png':
     Duration: N/A, bitrate: N/A
       Stream #0:0: Video: png, rgb24(pc), 1357x1485, 25 tbr, 25 tbn, 25 tbc
    Input #1, gif, from '/storage/emulated/0/Pictures/MyCameraApp/t.gif':
     Duration: N/A, bitrate: N/A
       Stream #1:0: Video: gif, bgra, 400x400, 6.67 fps, 6.67 tbr, 100 tbn, 100 tbc
    [libx264 @ 0xb76dff30] width not divisible by 2 (1357x1485)
    Output #0, mp4, to '/storage/emulated/0/Pictures/MyCameraApp/VID_20190617_180935.mp4':
       Stream #0:0: Video: h264, none, q=2-31, 128 kb/s, 25 fps (default)
       Metadata:
         encoder         : Lavc57.24.102 libx264
    Stream mapping:
     Stream #0:0 (png) -> overlay:main
     Stream #1:0 (gif) -> scale
     overlay -> Stream #0:0 (libx264)
    Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height