Recherche avancée

Médias (39)

Mot : - Tags -/audio

Autres articles (43)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

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

Sur d’autres sites (8415)

  • Can't play mp4 video using html5 video tag

    7 août 2020, par John Doe

    I am trying to present an mp4 video (h264) using html5 :

    


    <video width="320" controls="controls">&#xA;            <source src="/home/nabil/FWork/hikvision/ch01_00000100068000101.mp4" type="video/mp4">&#xA;</source></video>&#xA;

    &#xA;

    analyzing video codec with ffmpeg gives the following :

    &#xA;

    ffprobe ch01_00000100068000101.mp4 &#xA;ffprobe version 2.8.17-0ubuntu0.1 Copyright (c) 2007-2020 the FFmpeg developers&#xA;  built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.12) 20160609&#xA;  configuration: --prefix=/usr --extra-version=0ubuntu0.1 --build-suffix=-ffmpeg --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --cc=cc --cxx=g&#x2B;&#x2B; --enable-gpl --enable-shared --disable-stripping --disable-decoder=libopenjpeg --disable-decoder=libschroedinger --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzvbi --enable-openal --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-frei0r --enable-libx264 --enable-libopencv&#xA;  libavutil      54. 31.100 / 54. 31.100&#xA;  libavcodec     56. 60.100 / 56. 60.100&#xA;  libavformat    56. 40.101 / 56. 40.101&#xA;  libavdevice    56.  4.100 / 56.  4.100&#xA;  libavfilter     5. 40.101 /  5. 40.101&#xA;  libavresample   2.  1.  0 /  2.  1.  0&#xA;  libswscale      3.  1.101 /  3.  1.101&#xA;  libswresample   1.  2.101 /  1.  2.101&#xA;  libpostproc    53.  3.100 / 53.  3.100&#xA;Invalid UE golomb code&#xA;    Last message repeated 3 times&#xA;Input #0, mpeg, from &#x27;ch01_00000100068000101.mp4&#x27;:&#xA;  Duration: 00:09:27.33, start: 35024.106667, bitrate: 507 kb/s&#xA;    Stream #0:0[0x1e0]: Video: h264 (Baseline), yuv420p, 1280x720, 10 fps, 10 tbr, 90k tbn, 20 tbc&#xA;

    &#xA;

    a possible relevant detail is that playing the video using ubuntu's default video reader (ffmpeg in the background) doesn't show any video controls

    &#xA;

  • Fragmented MP4 not playing in ffplay/QuickTime/Safari, but in VLC

    6 août 2020, par Stack64

    I encoded a fMP4-Video (HEVC) in Swift using VideoToolbox and CoreMedia. The resulting fragmented MP4 is only playing in VLC.

    &#xA;

    The library I am using to write the fMP4 is an HEVC-adapted version of this GitHub-Project : https://github.com/krad/morsel

    &#xA;

    Process of encoding and writing :

    &#xA;

      &#xA;
    1. VideoToolbox : Encoding SampleBuffer from the camera (VTCompressionSession, as described in WWDC 2014 Session 513)
    2. &#xA;

    3. Using CoreMedia-Functions (e.g. CMVideoFormatDescriptionGetHEVCParameterSetAtIndex, CMVideoFormatDescriptionGetDimensions) to get the encoded streams metadata. I am writing the content of CMFormatDescriptionGetExtension(description, extensionKey: "SampleDescriptionExtensionAtoms" as CFString)["hvcC"] directly to the hvcC box. This box is obviously written correctly, when I alter one bit of the box of the mp4, QuickTime throws an error.
    4. &#xA;

    5. I am appending the sample buffer data to the morsel-library, which manages fragmentation and creates the moof and mdat atoms.
    6. &#xA;

    &#xA;

    The result file is playable in VLC, when I just let the playback "run" without doing anything. When I scroll the time in VLC, VLC crashes and the playback stops.

    &#xA;

    It is also sort of "playable" in Safari and QuickTime (no error message shown, the playback window opens and the correct length of the file is shown, I can even change to playback time / play/pause, but there is no video shown. The window remains empty. And that is the problem I have. I need to get an fMP4 running in Safari and QuickTime.

    &#xA;

    The file is not playing at all in ffplay (same problem when converting with ffmpeg). The line where the playback time is shown remains nan M-V:    nan fd=   0 aq=    0KB vq=    0KB sq=    0B f=0/0 , there are no error messages. The playback just does not start.&#xA;When playing the file with ffplay, this is the output :

    &#xA;

    ffplay version 4.3 Copyright (c) 2003-2020 the FFmpeg developers&#xA;  built with Apple clang version 11.0.3 (clang-1103.0.32.62)&#xA;  configuration: --prefix=/usr/local/Cellar/ffmpeg/4.3_2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack&#xA;  libavutil      56. 51.100 / 56. 51.100&#xA;  libavcodec     58. 91.100 / 58. 91.100&#xA;  libavformat    58. 45.100 / 58. 45.100&#xA;  libavdevice    58. 10.100 / 58. 10.100&#xA;  libavfilter     7. 85.100 /  7. 85.100&#xA;  libavresample   4.  0.  0 /  4.  0.  0&#xA;  libswscale      5.  7.100 /  5.  7.100&#xA;  libswresample   3.  7.100 /  3.  7.100&#xA;  libpostproc    55.  7.100 / 55.  7.100&#xA;Input #0, mov,mp4,m4a,3gp,3g2,mj2, from &#x27;test.mp4&#x27;:&#xA;  Metadata:&#xA;    major_brand     : mp42&#xA;    minor_version   : 1&#xA;    compatible_brands: mp41mp42isomhlsf&#xA;    creation_time   : 2020-08-03T20:41:08.000000Z&#xA;  Duration: N/A, bitrate: N/A&#xA;    Stream #0:0(und): Video: hevc (Main) (hvc1 / 0x31637668), yuv420p(tv), 1920x1080, SAR 1:1 DAR 16:9, 1000000000.00 tbr, 1000000000.00 tbn, 1000000000.00 tbc (default)&#xA;    Metadata:&#xA;      creation_time   : 2020-08-03T20:41:08.000000Z&#xA;      handler_name    : video&#xA;    nan M-V:    nan fd=   0 aq=    0KB vq=    0KB sq=    0B f=0/0 &#xA;

    &#xA;

    My file has this structure :

    &#xA;

    ftyp&#xA;moov&#xA;    mvhd&#xA;    trak&#xA;        tkhd&#xA;        mdia&#xA;            mdhd&#xA;            hdlr&#xA;            minf&#xA;                vmhd&#xA;                dinf&#xA;                    dref&#xA;                stbl&#xA;                    stsd&#xA;                    stts&#xA;                    stsc&#xA;                    stsz&#xA;                    stco&#xA;    mvex&#xA;        trex&#xA;moof-(1)&#xA;mdat&#xA;moof-(2)&#xA;mdat &#xA;...&#xA;

    &#xA;

    The result file I want to create should be like the fMP4 served within this HLS playlist : (Example : https://developer.apple.com/streaming/examples/advanced-stream-hevc.html, Playlist : https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_adv_example_hevc/master.m3u8)&#xA;This file has the following structure :

    &#xA;

    ftyp&#xA;moov&#xA;    mvhd&#xA;    trak&#xA;        tkhd&#xA;        mdia&#xA;            mdhd&#xA;            hdlr&#xA;            minf&#xA;                vmhd&#xA;                dinf&#xA;                    dref&#xA;                stbl&#xA;                    stsd&#xA;                    stts&#xA;                    stsc&#xA;                    stsz&#xA;                    stco&#xA;    trak (same structure as above)&#xA;    mvex&#xA;        trex&#xA;moof-(1)&#xA;mdat&#xA;moof-(2)&#xA;mdat &#xA;...&#xA;

    &#xA;

    This file from Apple plays perfectly in ffmpeg and QuickTime/Safari. Except for the second trak atom, it has the same structure.

    &#xA;

    The "good" file is : https://devstreaming-cdn.apple.com/videos/streaming/examples/bipbop_adv_example_hevc/v14/main.mp4 (It is intended for use in a HLS Playlist I've downloaded it with curl)

    &#xA;

    The "bad" file is : https://www.transfernow.net/ddl/fmp4_bad (link should work, tested it just now :) ). The video shows a slowly rotating sheet of paper.

    &#xA;

    Any suggestions what the problem with my file is ?&#xA;Thanks in advance !

    &#xA;

  • Recording Camlink 4k feed with ffmpeg

    5 août 2020, par Nitzan Yogev

    its my first question ! awesome !&#xA;so im new to python, and im working on some program for work&#xA;I have the Elgato CamLink 4k connected to Sony A7III.&#xA;im looking for the best way to record a video file from the camlink feed using python&#xA;I know that ffmpeg is a good way to record webcam feed. but im having trouble with it&#xA;here is my code.

    &#xA;

        import ffmpeg&#xA;&#xA;(&#xA;    ffmpeg&#xA;    .input(&#x27;0&#x27;, format=&#x27;avfoundation&#x27;, pix_fmt=&#x27;nv12&#x27;, framerate=25)&#xA;    .output(&#x27;test.mp4&#x27;, pix_fmt=&#x27;nv12&#x27;, vframes=125)&#xA;    .overwrite_output()&#xA;    .run()&#xA;)&#xA;

    &#xA;

    im using this ffmpeg-python module

    &#xA;

    im getting a output file with only the first frame and nothing more

    &#xA;

    here is what im getting in the run terminal

    &#xA;

    ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers&#xA;  built with Apple clang version 11.0.3 (clang-1103.0.32.62)&#xA;  configuration: --prefix=/usr/local/Cellar/ffmpeg/4.3.1 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack&#xA;  libavutil      56. 51.100 / 56. 51.100&#xA;  libavcodec     58. 91.100 / 58. 91.100&#xA;  libavformat    58. 45.100 / 58. 45.100&#xA;  libavdevice    58. 10.100 / 58. 10.100&#xA;  libavfilter     7. 85.100 /  7. 85.100&#xA;  libavresample   4.  0.  0 /  4.  0.  0&#xA;  libswscale      5.  7.100 /  5.  7.100&#xA;  libswresample   3.  7.100 /  3.  7.100&#xA;  libpostproc    55.  7.100 / 55.  7.100&#xA;[avfoundation @ 0x7ff043814600] Stream #0: not enough frames to estimate rate; consider increasing probesize&#xA;Input #0, avfoundation, from &#x27;0&#x27;:&#xA;  Duration: N/A, start: 6247.240967, bitrate: N/A&#xA;    Stream #0:0: Video: rawvideo (NV12 / 0x3231564E), nv12, 3840x2160, 1000k tbr, 1000k tbn, 1000k tbc&#xA;Stream mapping:&#xA;  Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264))&#xA;Press [q] to stop, [?] for help&#xA;[mp4 @ 0x7ff043856c00] Frame rate very high for a muxer not efficiently supporting it.&#xA;Please consider specifying a lower framerate, a different muxer or -vsync 2&#xA;[libx264 @ 0x7ff043868000] MB rate (32400000000) > level limit (16711680)&#xA;[libx264 @ 0x7ff043868000] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2&#xA;[libx264 @ 0x7ff043868000] profile High, level 6.2, 4:2:0, 8-bit&#xA;[libx264 @ 0x7ff043868000] 264 - core 160 r3011 cde9a93 - H.264/MPEG-4 AVC codec - Copyleft 2003-2020 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=18 lookahead_threads=3 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00&#xA;Output #0, mp4, to &#x27;test.mp4&#x27;:&#xA;  Metadata:&#xA;    encoder         : Lavf58.45.100&#xA;    Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), nv12, 3840x2160, q=-1--1, 1000k fps, 1000k tbn, 1000k tbc&#xA;    Metadata:&#xA;      encoder         : Lavc58.91.100 libx264&#xA;    Side data:&#xA;      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A&#xA;frame=  125 fps= 30 q=-1.0 Lsize=     788kB time=00:00:00.00 bitrate=52509528.5kbits/s dup=124 drop=1 speed=2.99e-05x    &#xA;video:786kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.290685%&#xA;[libx264 @ 0x7ff043868000] frame I:1     Avg QP:19.49  size:588332&#xA;[libx264 @ 0x7ff043868000] frame P:31    Avg QP:20.24  size:  4202&#xA;[libx264 @ 0x7ff043868000] frame B:93    Avg QP:33.28  size:   922&#xA;[libx264 @ 0x7ff043868000] consecutive B-frames:  0.8%  0.0%  0.0% 99.2%&#xA;[libx264 @ 0x7ff043868000] mb I  I16..4:  2.8% 86.0% 11.3%&#xA;[libx264 @ 0x7ff043868000] mb P  I16..4:  0.0%  0.0%  0.0%  P16..4:  6.9%  0.3%  0.5%  0.0%  0.0%    skip:92.3%&#xA;[libx264 @ 0x7ff043868000] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  4.4%  0.0%  0.0%  direct: 0.0%  skip:95.6%  L0:19.0% L1:81.0% BI: 0.0%&#xA;[libx264 @ 0x7ff043868000] 8x8 transform intra:86.0% inter:88.3%&#xA;[libx264 @ 0x7ff043868000] coded y,uvDC,uvAC intra: 93.8% 87.1% 55.6% inter: 0.1% 1.5% 0.0%&#xA;[libx264 @ 0x7ff043868000] i16 v,h,dc,p:  9% 10%  9% 72%&#xA;[libx264 @ 0x7ff043868000] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 15% 14% 34%  6%  5%  5%  6%  7%  7%&#xA;[libx264 @ 0x7ff043868000] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 18% 16%  9%  8%  7%  8%  7%  6%&#xA;[libx264 @ 0x7ff043868000] i8c dc,h,v,p: 48% 26% 20%  6%&#xA;[libx264 @ 0x7ff043868000] Weighted P-Frames: Y:0.0% UV:0.0%&#xA;[libx264 @ 0x7ff043868000] ref P L0: 82.6%  0.1% 14.0%  3.3%&#xA;[libx264 @ 0x7ff043868000] ref B L0: 99.8%  0.2%  0.0%&#xA;[libx264 @ 0x7ff043868000] ref B L1: 76.2% 23.8%&#xA;[libx264 @ 0x7ff043868000] kb/s:51475456.00&#xA;

    &#xA;

    if im plugging the camlink off I get a video from my macbook internal camera. so I know this should somehow work

    &#xA;