Recherche avancée

Médias (91)

Autres articles (41)

  • HTML5 audio and video support

    13 avril 2011, par

    MediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
    The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
    For older browsers the Flowplayer flash fallback is used.
    MediaSPIP allows for media playback on major mobile platforms with the above (...)

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

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

  • Convert Cairo ImageSurface to PIL Image object

    31 octobre 2015, par Simon

    I’m trying to convert a Cairo ImageSurface to a PIL Image object so it can be passed to an ffmpeg pipe.

    What I have so far is :

    where svgstr holds the SVG data of the image as a string.

    img = cairo.ImageSurface(cairo.FORMAT_ARGB32, 386,1080)
    ctx = cairo.Context(img)

    #render the svg as a png
    handle= rsvg.Handle(None, svgstr)
    handle.render_cairo(ctx)

    imgPIL = Image.frombuffer("RGBA",( img.get_width(),img.get_height() ),img.get_data(),"raw","RGBA",0,1)

    img44 = imgPIL.convert("RGBA")
    img44.save(p.stdin,"PNG")

    If I save the image to file rather than passing it to the pipe, I get some version of grayscale. When passed to the pipe it gives "IOError : [Errno 32] Broken pipe"

    Ultimately I’m just trying to convert SVG data to some sort of object that I can pass to the ffmpeg pipe to concatenate images into a video without having to save the images to disk first.

  • Raspberry Pi Camera Module - Stream to LAN

    20 août 2015, par user3096434

    have a little problem with the setup of my RasPi camera infrastructure. Basically I have a RPi 2 which shall act as a MontionEye server from now on and 2 Pi B+ with camera modules.

    Previously, when I had only one camera in my network, I used the following command to stream the output from RPi B+ camera module to Youtube in full HD. So far, this command works flawless :

    raspivid -n -vf -hf -t 0 -w 1920 -h 1080 -fps 30 -b 3750000 -g 50 -o - | b ffmpeg -ar 8000 -ac 2 -acodec pcm_s16le -f s16le -ac 2 -i /dev/zero -f h264 -i - -vcodec copy -acodec aac -ab 64k -g 50 -strict experimental -f flv $RTMP_URL/$STREAM_KEY

    Now I have a 2nd RPi with a camera module and figured it might be the time for a change towards motioneye, as I then can view both/all camera’s in my network within the same software. I have motioneye installed on my RPi 2 and the software is running correctly.

    I have a little problem when it comes to access the data stream from the RPi B+ camera on my local network.

    Basically I cannot seem to figure out how to change the ffmpeg portion of the above mentioned command, in a way so it will stream the data to localhost (Or the RPi2 IP where motioneye runs - which one to use ?) instead of Youtube or any other videohoster.

    I wonder, if changing the following part is a correct assumption :

    Instead of using variables to define Youtube URL and key

    -f flv $RTMP_URL/$STREAM_KEY

    And change this to

    -f flv 10.1.1.11:8080

    Will I then be able to add this RPi B+ video stream to my RPi 2 motioneye server, by using motioneye ’add network camera’ function ?

    From my understanding I should be able to enter the following details into motioneye ’add network camera’wizard :

    Camera type: network camera
    RTSP-URL: 10.1.1.11:8080
    User: Pi
    Pass: [my pwd]
    Camera: [my ffmpeg stream shall show here]

    Thanks in advance !

    Uhm, and then... How do I forwarded the video stream from a given camera connected to motioneye ? Like from motioneye to youtube (or similar), without re-encoding the stream ?

    Like the command shown above streams directly to youtube. But I want to have it in a way, that video is streamed to local network/motioneye server, and from there I can decide which camera’s stream and when I want to send the videostream to youtube ?

    How would a RPi professional realize this ?

    The command above explained : Takes full HD video with 30 fps from Pi camera module and hardware encodes it on GPU with 3.75mbit/s. Then I streamcopy the video (no re-encoding) and add some audio, so that the stream complies with youtube rules (yes, no live stream without audio). Audio is taken from virtual SB16 /dev/zero at low sampling rate then encoded to 32k AAC and sent to youtube. Works fine xD.

    Just when I have like 3 or more of these RPi cams the youtube stream approach ain’t feasible anymore, as my DSL upstream is limited (10 mbit/s=. Thus I need motioneye server and some magic, so I can watch f.e. all 3 camera’s videostream and then motioneye server can select and streamcopy the video from the Pi’s cam I choose and send it to youtube, as the original command did.

    Any help, tips, links to similar projects highly appreciated.

    Again, many thanks in advance, and even more thanks just cause you read until here.

    —mx

  • ffmpeg : How to speed up (and keep only) a specified portion of an input video

    17 avril 2020, par shrimpwidget

    In my input video is a 48 second range that I wish to speed up. I wish to save only that sped up portion to a new video.

    



    Solution :

    



    ffmpeg -y -ss 00:00:03 -t 00:00:48 -i input.mp4 -an -crf 20 -pix_fmt yuv420p -vf "scale=1080:-1, setpts=PTS/10.0" "output.mp4"