Recherche avancée

Médias (1)

Mot : - Tags -/sintel

Autres articles (35)

  • Supporting all media types

    13 avril 2011, par

    Unlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)

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

Sur d’autres sites (3600)

  • avformat/rtsp : initialize reply1

    8 juin 2024, par Michael Niedermayer
    avformat/rtsp : initialize reply1
    

    It seems reply1 is initialized by ff_rtsp_send_cmd() in most cases but there
    are code paths like "continue" which look like they could skip it but even if not
    writing this so a complex loop after several layers of calls initialized a local
    variable through a pointer is just bad design.
    This patch simply initialized the variable.

    Fixes : CID1473532 Uninitialized scalar variable

    Sponsored-by : Sovereign Tech Fund
    Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>

    • [DH] libavformat/rtsp.c
  • Different container duration between ffmpeg versions which causes audio gaps

    4 septembre 2024, par blits

    I'm trying to make a looped RTMP stream from a single video (in this&#xA;example - YouTube), but starting with version 6.0 it introduces a gap in-between loops in the audio which is quite audible. Version before 6.0 (I&#xA;tried 5.1.6 and 4.4.2) work as expected and don't introduce any gaps.

    &#xA;

    The difference I spotted is that the master version (7.0.2) and the 5.1.6, for&#xA;example, report a different duration time. Is there any reason why that might happen ?

    &#xA;

    v5.1.6 :

    &#xA;

     Input #0, mov,mp4,m4a,3gp,3g2,mj2, from &#x27;demo-video.mp4&#x27;:&#xA;   Metadata:&#xA;     major_brand     : isom&#xA;     minor_version   : 512&#xA;     compatible_brands: isomiso2avc1mp41&#xA;     creation_time   : 2024-09-03T15:30:51.000000Z&#xA;     encoder         : Blackmagic Design DaVinci Resolve Studio&#xA;   Duration: 00:00:05.00, start: 0.000000, bitrate: 35440 kb/s&#xA;

    &#xA;

    v7.0.2 :

    &#xA;

    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from &#x27;demo-video.mp4&#x27;:&#xA;  Metadata:&#xA;    major_brand     : isom&#xA;    minor_version   : 512&#xA;    compatible_brands: isomiso2avc1mp41&#xA;    creation_time   : 2024-09-03T15:30:51.000000Z&#xA;    encoder         : Blackmagic Design DaVinci Resolve Studio&#xA;  Duration: 00:00:05.01, start: 0.000000, bitrate: 35346 kb/s&#xA;  Stream #0:0[0x1](und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709, progressive), 2560x1440 [SAR 1:1 DAR 16:9], 35240 kb/s, 24 fps, 24 tbr, 12288 tbn (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-03T15:30:51.000000Z&#xA;        handler_name    : VideoHandler&#xA;        vendor_id       : [0][0][0][0]&#xA;        encoder         : H.264 NVIDIA&#xA;        timecode        : 01:00:00:00&#xA;

    &#xA;

    As you can see, v5.1.6 report duration of 00:00:05.00 (which is correct) and v7.0.2 is 00:00:05.01 (1ms longer), which is what I think is causing the issue (but I'm not so sure about that). The original file is 5 seconds long which is what can be checked by ffprobe as well, but some streams report a 00:05.01 duration time.

    &#xA;

    I tried to remedy this issue in many different ways by trimming the video/audio, using different flags, like -shortest, but that didn't help in any way - there's still a gap in the audio which is noticeable when looping the video. And like I said versions such as v5.1.6 work fine and there's no such gap.

    &#xA;

    I guess what changed between versions is how ffmpeg interprets these streams but in the end I spent 2 days trying to avoid gaps in audio when streaming and nothing helped.

    &#xA;

    How to reproduce :

    &#xA;

    You can just stream the video in any RTMP destination of your liking, like YouTube and observe that there would be gaps (audio break-ups) in between every 5 seconds (once video ends). Video is accessible through the link from the curl command

    &#xA;

    curl -o stream-audio-gap-issue.mp4 https://r2v.streamloop.app/obj_01j6y0pk83fy8vp06a9mmkkqah.mp4&#xA;ffmpeg -re -stream_loop -1 -i stream-audio-gap-issue.mp4 -c copy -f flv rtmp://a.rtmp.youtube.com/live2/[your-key]&#xA;

    &#xA;

    Expected : there are no gaps every 5 seconds, like in old versions of ffmpeg

    &#xA;

    Instead : there are tiny audio gaps which are quite noticable

    &#xA;

    ffprobe outputs is available on gist : https://gist.github.com/blitss/1e221b4fa8885b1df8ac2096746239cf

    &#xA;

    I'm looking for literally any workarounds that will help avoid audio gaps whilst still preserving the latest version of ffmpeg.

    &#xA;

  • Transcoding/ Converting mpeg to h264 using ffmpeg h264_nvenc

    15 septembre 2024, par Mustafa

    I'm trying to transcode a video rendered by Davinci Resolve, using ffmpeg from mpeg4 to h264, on Ubuntu, using the following command.

    &#xA;

    ffmpeg -y -vsync 0 -hwaccel cuda -hwaccel_output_format cuda -i input.mov -c:a copy -c:v h264_nvenc -b:v 8M -preset 7 output-h264_nvenc-p7.mp4 -v verbose&#xA;

    &#xA;

    And my Nvidia card is NVIDIA GeForce GTX 1650.

    &#xA;

    I'm gettting the following error :

    &#xA;

    [mpeg4 @ 0x55a893ed3200] Video width 3840 not within range from 48 to 2032&#xA;[mpeg4 @ 0x55a893ed3200] Failed setup for format cuda: hwaccel initialisation returned error.&#xA;

    &#xA;

    And here's the complete output. The command produces an output but its quality is significantly less than the original.

    &#xA;

      built with gcc 13 (Ubuntu 13.2.0-23ubuntu4)&#xA;  configuration: --enable-nonfree --enable-cuda-nvcc --enable-libnpp --extra-cflags=-I/usr/local/cuda/include --extra-ldflags=-L/usr/local/cuda/lib64 --disable-static --enable-shared --enable-gpl --enable-libx264&#xA;  libavutil      59. 36.100 / 59. 36.100&#xA;  libavcodec     61. 13.100 / 61. 13.100&#xA;  libavformat    61.  5.101 / 61.  5.101&#xA;  libavdevice    61.  2.101 / 61.  2.101&#xA;  libavfilter    10.  2.102 / 10.  2.102&#xA;  libswscale      8.  2.100 /  8.  2.100&#xA;  libswresample   5.  2.100 /  5.  2.100&#xA;  libpostproc    58.  2.100 / 58.  2.100&#xA;-vsync is deprecated. Use -fps_mode&#xA;Passing a number to -vsync is deprecated, use a string argument as described in the manual.&#xA;Selecting decoder &#x27;mpeg4&#x27; because of requested hwaccel method cuda&#xA;Input #0, mov,mp4,m4a,3gp,3g2,mj2, from &#x27;input.mov&#x27;:&#xA;  Metadata:&#xA;    major_brand     : qt  &#xA;    minor_version   : 512&#xA;    compatible_brands: qt  &#xA;    creation_time   : 2024-09-15T04:25:29.000000Z&#xA;    encoder         : Blackmagic Design DaVinci Resolve&#xA;  Duration: 00:20:34.87, start: 0.000000, bitrate: 347243 kb/s&#xA;  Stream #0:0[0x1]: Video: mpeg4 (Simple Profile), 1 reference frame (mp4v / 0x7634706D), yuv420p(bt709/bt709/unknown, left), 3840x2160 [SAR 1:1 DAR 16:9], 345703 kb/s, 60 fps, 60 tbr, 15360 tbn (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-15T04:25:29.000000Z&#xA;        handler_name    : VideoHandler&#xA;        vendor_id       :     &#xA;        encoder         : MPEG4 Video&#xA;        timecode        : 01:00:00:00&#xA;  Stream #0:1[0x2]: Audio: pcm_s16le (lpcm / 0x6D63706C), 48000 Hz, stereo, s16, 1536 kb/s (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-15T04:25:29.000000Z&#xA;        handler_name    : SoundHandler&#xA;        vendor_id       : [0][0][0][0]&#xA;  Stream #0:2[0x3](eng): Data: none (tmcd / 0x64636D74) (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-15T04:25:29.000000Z&#xA;        handler_name    : TimeCodeHandler&#xA;        timecode        : 01:00:00:00&#xA;[out#0/mp4 @ 0x55a8929e8d80] No explicit maps, mapping streams automatically...&#xA;[vost#0:0/h264_nvenc @ 0x55a8929f5880] Created video stream from input stream 0:0&#xA;[aost#0:1/copy @ 0x55a893867080] Created audio stream from input stream 0:1&#xA;Stream mapping:&#xA;  Stream #0:0 -> #0:0 (mpeg4 (native) -> h264 (h264_nvenc))&#xA;  Stream #0:1 -> #0:1 (copy)&#xA;[vost#0:0/h264_nvenc @ 0x55a8929f5880] Starting thread...&#xA;[vf#0:0 @ 0x55a8929f17c0] Starting thread...&#xA;[vist#0:0/mpeg4 @ 0x55a89293a100] [dec:mpeg4 @ 0x55a8929f4440] Starting thread...&#xA;[in#0/mov,mp4,m4a,3gp,3g2,mj2 @ 0x55a8929e0600] Starting thread...&#xA;Press [q] to stop, [?] for help&#xA;[mpeg4 @ 0x55a893ed3200] NVDEC capabilities:&#xA;[mpeg4 @ 0x55a893ed3200] format supported: yes, max_mb_count: 8192&#xA;[mpeg4 @ 0x55a893ed3200] min_width: 48, max_width: 2032&#xA;[mpeg4 @ 0x55a893ed3200] min_height: 16, max_height: 2032&#xA;[mpeg4 @ 0x55a893ed3200] Video width 3840 not within range from 48 to 2032&#xA;[mpeg4 @ 0x55a893ed3200] Failed setup for format cuda: hwaccel initialisation returned error.&#xA;[graph -1 input from stream 0:0 @ 0x75c970002e40] w:3840 h:2160 pixfmt:yuv420p tb:1/15360 fr:60/1 sar:1/1 csp:bt709 range:unknown&#xA;[graph -1 input from stream 0:0 @ 0x75c970002e40] video frame properties congruent with link at pts_time: 0&#xA;[h264_nvenc @ 0x55a8929e62c0] Using device cuda0 (type cuda) with h264_nvenc encoder.&#xA;[h264_nvenc @ 0x55a8929e62c0] Loaded Nvenc version 12.2&#xA;[h264_nvenc @ 0x55a8929e62c0] Nvenc initialized successfully&#xA;[h264_nvenc @ 0x55a8929e62c0] The selected preset is deprecated. Use p1 to p7 &#x2B; -tune or fast/medium/slow.&#xA;Output #0, mp4, to &#x27;output-h264_nvenc-p7.mp4&#x27;:&#xA;  Metadata:&#xA;    major_brand     : qt  &#xA;    minor_version   : 512&#xA;    compatible_brands: qt  &#xA;    encoder         : Lavf61.5.101&#xA;  Stream #0:0: Video: h264 (Main), 1 reference frame (avc1 / 0x31637661), yuv420p(tv, bt709/bt709/unknown, progressive, left), 3840x2160 [SAR 1:1 DAR 16:9], q=2-31, 8000 kb/s, 60 fps, 15360 tbn (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-15T04:25:29.000000Z&#xA;        handler_name    : VideoHandler&#xA;        vendor_id       :     &#xA;        timecode        : 01:00:00:00&#xA;        encoder         : Lavc61.13.100 h264_nvenc&#xA;      Side data:&#xA;        cpb: bitrate max/min/avg: 0/0/8000000 buffer size: 16000000 vbv_delay: N/A&#xA;  Stream #0:1: Audio: pcm_s16le (ipcm / 0x6D637069), 48000 Hz, stereo, s16, 1536 kb/s (default)&#xA;      Metadata:&#xA;        creation_time   : 2024-09-15T04:25:29.000000Z&#xA;        handler_name    : SoundHandler&#xA;        vendor_id       : [0][0][0][0]&#xA;

    &#xA;

    How can I find the cause of the error and resolve it ?

    &#xA;

    Also is there a way to improve the quality of the output video as it's much lower than the original ? I tried doing the same conversion using libxh264 (using the CPU) and that produced a far better video.

    &#xA;