Recherche avancée

Médias (91)

Autres articles (79)

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

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

  • Mediabox : ouvrir les images dans l’espace maximal pour l’utilisateur

    8 février 2011, par

    La visualisation des images est restreinte par la largeur accordée par le design du site (dépendant du thème utilisé). Elles sont donc visibles sous un format réduit. Afin de profiter de l’ensemble de la place disponible sur l’écran de l’utilisateur, il est possible d’ajouter une fonctionnalité d’affichage de l’image dans une boite multimedia apparaissant au dessus du reste du contenu.
    Pour ce faire il est nécessaire d’installer le plugin "Mediabox".
    Configuration de la boite multimédia
    Dès (...)

Sur d’autres sites (5806)

  • FFMPEG X264 reduce bitrate for unchanging input

    8 juin 2021, par GroovyDotCom
    ffmpeg -f lavfi -i smptebars=duration=1000:size=640x360:rate=30 -preset ultrafast -vcodec libx264 -tune zerolatency -b 900k -g 1000 -f mpegts video.ts


    


    As can be seen when running this command, the encode size continues to grow rapidly even though :

    


      

    1. The input source never changes. It is exactly the same image again and again.
    2. 


    3. The encoder has been told to insert a keyframe only once every 1000 frames
    4. 


    


    Is there some configuration option I could add to change this behaviour ? I can understand it would need to send an empty P frame but right now it seems to be sending much much more ?

    


    UPDATE
After Tim Roberts comment, I realized we can get a clearer picture of the file growth if I change the command to 1 FPS and do the encode in real-time.

    


    ffmpeg -f lavfi -re -i smptebars=duration=1000:size=640x360:rate=1 -preset ultrafast -vcodec libx264 -tune zerolatency -b 900k -g 1000 out.ts

    


    Now I see that it is going up almost exactly 1KB per frame. That seems like a lot for a P-frame that does nothing.

    


    So, just for kicks, I got rid of the TS muxing.

    


    ffmpeg -f lavfi -re -i smptebars=duration=1000:size=640x360:rate=1 -preset ultrafast -vcodec libx264 -tune zerolatency -b 900k -g 1000 out.h264

    


    Now the file grows by 1k every 17 frames - a 17X improvement !

    


    This seems to point to ffmpeg doing something weird in the TS muxer that inflates an 80 byte P-frame into 1K.

    


  • Is there a way to find out whether ffmpeg is performing optimally in my system using a ffmpeg command of sorts ?

    17 octobre 2020, par Aspiring Dev

    I'm encoding a file (mediainfo below) using the following command :

    


    ffmpeg -i AHomeMovie.mkv -map 0 -c copy -c:v libx264 -preset veryslow -crf 17 -c:a aac -b:a 256k -threads 8 resultdir/AHomeMovie.mkv


    


    And getting more or less the following performance after a couple of minutes :

    


    frame= 2036 fps=2.5 q=22.0 size=   87535kB time=00:01:25.25 bitrate=8411.2kbits/s speed=0.104x    


    


    Is this normal performance for a laptop with a i7-8550U, 16gb of RAM, UHD graphics 620 running Linux ? Is there a way to find out whether ffmpeg is performing optimally using a ffmpeg command of sorts ? I know it's commodity hardware by now but I just want to get some perspective on how the system is performing. I'm aware that I can use a different -preset speed btw.

    


    Mediainfo :

    


    General
Unique ID                                : 25145236523685421256398752247554522365 (0x14258745965823652446224452555874)
Complete name                            : AHomeMovie.mkv
Format                                   : Matroska
Format version                           : Version 4
File size                                : 6.35 GiB
Duration                                 : 22 min 47 s
Overall bit rate mode                    : Variable
Overall bit rate                         : 39.9 Mb/s
Movie name                               : A Home Movie
Encoded date                             : UTC 2020-09-10 22:10:12
Writing application                      : mkvmerge v42.0.0 ('Overtime') 64-bit
Writing library                          : libebml v1.3.10 + libmatroska v1.5.2

Video
ID                                       : 1
Format                                   : AVC
Format/Info                              : Advanced Video Codec
Format profile                           : High@L4.1
Format settings                          : CABAC / 4 Ref Frames
Format settings, CABAC                   : Yes
Format settings, Reference frames        : 4 frames
Codec ID                                 : V_MPEG4/ISO/AVC
Duration                                 : 22 min 45 s
Bit rate mode                            : Variable
Bit rate                                 : 38.0 Mb/s
Maximum bit rate                         : 40.0 Mb/s
Width                                    : 1 920 pixels
Height                                   : 1 080 pixels
Display aspect ratio                     : 16:9
Frame rate mode                          : Constant
Frame rate                               : 23.976 (24000/1001) FPS
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Bits/(Pixel*Frame)                       : 0.764
Stream size                              : 6.04 GiB (95%)
Default                                  : Yes
Forced                                   : No

Audio #1
ID                                       : 2
Format                                   : FLAC
Format/Info                              : Free Lossless Audio Codec
Codec ID                                 : A_FLAC
Duration                                 : 22 min 45 s
Bit rate mode                            : Variable
Bit rate                                 : 614 kb/s
Channel(s)                               : 2 channels
Channel layout                           : L R
Sampling rate                            : 48.0 kHz
Frame rate                               : 11.719 FPS (4096 SPF)
Bit depth                                : 16 bits
Compression mode                         : Lossless
Stream size                              : 100 MiB (2%)
Writing library                          : libFLAC 1.2.1 (UTC 2007-09-17)
Language                                 : Japanese
Default                                  : Yes
Forced                                   : No

Audio #2
ID                                       : 3
Format                                   : FLAC
Format/Info                              : Free Lossless Audio Codec
Codec ID                                 : A_FLAC
Duration                                 : 22 min 46 s
Bit rate mode                            : Variable
Bit rate                                 : 1 317 kb/s
Channel(s)                               : 2 channels
Channel layout                           : L R
Sampling rate                            : 48.0 kHz
Frame rate                               : 11.719 FPS (4096 SPF)
Bit depth                                : 24 bits
Compression mode                         : Lossless
Delay relative to video                  : 24 ms
Stream size                              : 215 MiB (3%)
Writing library                          : libFLAC 1.2.1 (UTC 2007-09-17)
Language                                 : English
Default                                  : No
Forced                                   : No


    


  • How Do I Convert a yuv420 Video File to 16-bit (using ffmpeg) ?

    1er novembre 2022, par IanMurphy

    As the title says, my video file has 12-bit depth and I want to convert it to 16-bit. I dont care which yuv pixel format, as long as its 16 bit. I have installed ffmpeg and I can't figure out what combination of arguments to use to convert it. The video file is very small : 20 frames at 352x288.

    


    This is the command I have been trying, but the file size is the same number of bytes as the original :

    


    ffmpeg -video_size 352x288 -pixel_format yuv420p -sample_fmt s16 -i inpput.yuv output.yuv


    


    If there is another way to do this without ffmpeg, I am open to any suggestions. Thanks in advance !