Recherche avancée

Médias (0)

Mot : - Tags -/optimisation

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

Autres articles (45)

  • 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

  • De l’upload à la vidéo finale [version standalone]

    31 janvier 2010, par

    Le chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
    Upload et récupération d’informations de la vidéo source
    Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
    Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)

  • Automated installation script of MediaSPIP

    25 avril 2011, par

    To overcome the difficulties mainly due to the installation of server side software dependencies, an "all-in-one" installation script written in bash was created to facilitate this step on a server with a compatible Linux distribution.
    You must have access to your server via SSH and a root account to use it, which will install the dependencies. Contact your provider if you do not have that.
    The documentation of the use of this installation script is available here.
    The code of this (...)

Sur d’autres sites (8501)

  • how to generate rtsp stream using laptop cam [closed]

    13 décembre 2023, par Mubahsir

    I am using the following command to capture video from the laptop camera and stream it as an RTSP using ffmpeg :

    


    ffmpeg -f v4l2 -i /dev/video0 -c:v libx264 -profile:v baseline -pix_fmt yuv420p -b:v 500k -r 30 -f rtsp rtsp://127.0.0.1:1234


    


    Upon executing this command, the laptop camera's indicator light turns on, indicating that it is in use. However, when attempting to view the RTSP stream on VLC using the URL rtsp://127.0.0.1:1234, no video is displayed.

    


  • doxy : Fix link in badge color

    16 décembre 2013, par Luca Barbato
    doxy : Fix link in badge color
    

    Green on blue was not exactly optimal.

    Signed-off-by : Luca Barbato <lu_zero@gentoo.org>

    • [DH] doc/doxy/doxy_stylesheet.css
  • Center crop image overlay using FFmpeg

    27 mai 2020, par HB.

    I currently have an image that is being overlayed on top of a video, as demonstrated in this image :

    &#xA;&#xA;

    original

    &#xA;&#xA;

    The blue square is representing the video and the purple lines are representing the image on top of the video.

    &#xA;&#xA;


    &#xA;&#xA;

    Currently, I have the following command :

    &#xA;&#xA;

    "-i", InputVideoPath, "-i", InputImagePath, "-filter_complex", "[0:v]scale=iw*sar:ih,setsar=1,pad=&#x27;max(iw\\,2*trunc(ih*9/16/2))&#x27;:&#x27;max(ih\\,2*trunc(ow*16/9/2))&#x27;:(ow-iw)/2:(oh-ih)/2[v0];[1:v][v0]scale2ref[v1][v0];[v0][v1]overlay=x=(W-w)/2:y=(H-h)/2[v]", "-map", "[v]", "-map", "0:a", "-c:v", "libx264", "-preset", "ultrafast", "-r", "30", OutputPath&#xA;

    &#xA;&#xA;

    This adds black padding to the sides of the video and outputs the following :

    &#xA;&#xA;

    Output

    &#xA;&#xA;

    But I would like the center crop the image that is being overlayed instead, giving me this output :

    &#xA;&#xA;

    DesiredResult

    &#xA;&#xA;

    I've seen answers that demonstrate how to crop an image or crop 2 videos, but I couldn't find a way to center crop an image that is being overlayed on top of a video.

    &#xA;&#xA;

    The video I'm testing with is 1920x1080 and the size of the image is not constant.

    &#xA;&#xA;

    Any help in achieving this will be appreciated.

    &#xA;&#xA;


    &#xA;&#xA;

    EDIT (This edit is to add more clarification).

    &#xA;&#xA;

    Please have a look at the image below :

    &#xA;&#xA;

    enter image description here

    &#xA;&#xA;

    The image above demonstrates :

    &#xA;&#xA;

      &#xA;
    • Purple Lines : The entire screen of the device/player, this will be used as the input image. The user draws on the screen/player.
    • &#xA;

    • Blue : The input video, scaled to fill the screen
    • &#xA;

    • Green : The actual size of the input video
    • &#xA;

    &#xA;&#xA;

    With this example, the player/image is 1920x1080 and the actual video size is 640x640. So the video is scaled 440x440 to fill the player.

    &#xA;&#xA;


    &#xA;&#xA;

    I tried to use a simple overlay, with the hopes that it will crop the video/image and output a video with the image at the same position as what was displayed on the device, by doing the following :

    &#xA;&#xA;

    ffmpeg -i InputVideo -i InputImage -filter_complex "overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2" -c:v libx264 -preset ultrafast OutputPath&#xA;

    &#xA;&#xA;

    But, the image is not at the same position as what it was on the device.

    &#xA;&#xA;

    I suspect that I will have to take into account the size difference between the scaling of the video to fit into the video player.

    &#xA;&#xA;

    I'm not sure how I can do this ?

    &#xA;