Recherche avancée

Médias (1)

Mot : - Tags -/epub

Autres articles (85)

  • 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

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • MediaSPIP Init et Diogène : types de publications de MediaSPIP

    11 novembre 2010, par

    À l’installation d’un site MediaSPIP, le plugin MediaSPIP Init réalise certaines opérations dont la principale consiste à créer quatre rubriques principales dans le site et de créer cinq templates de formulaire pour Diogène.
    Ces quatre rubriques principales (aussi appelées secteurs) sont : Medias ; Sites ; Editos ; Actualités ;
    Pour chacune de ces rubriques est créé un template de formulaire spécifique éponyme. Pour la rubrique "Medias" un second template "catégorie" est créé permettant d’ajouter (...)

Sur d’autres sites (8480)

  • avcodec/h2645_sei : loosen up min luminance requirements

    25 mai 2024, par Niklas Haas
    avcodec/h2645_sei : loosen up min luminance requirements
    

    The H.265 specification is quite clear on this case :

    > When min_display_mastering_luminance is not in the range of 1 to
    > 50000, the nominal maximum display luminance of the mastering display
    > is unknown or unspecified or specified by other means not specified in
    > this Specification.

    And so the current code is correct in marking luminance data as invalid
    if min luminance is set to 0. However, this breaks playback of at least
    several real-world Blu-ray releases, for example La La Land, Planet of
    the Apes, and quite possibly a lot more. These come with ostensibly
    valid max_luminance tags (1000 nits), but min_luminance set to 0.

    Loosen up this requirement by guarding it behind FF_COMPLIANCE_STRICT.
    We still reject blatantly invalid metadata (wrong value range on
    luminance, max set to 0, max below min, min above 50 nits etc.), so this
    shouldn't cause any unintended regressions.

    Fixes : https://github.com/mpv-player/mpv/issues/14177

    • [DH] libavcodec/h2645_sei.c
  • Use ffmpeg to transform rtsp stream containing B-Frames and no DTS into fragmented mp4 [closed]

    13 octobre 2023, par Stuntman11

    The goal is to play a rtsp video stream in the chrome browser using Websocket and MSE. The structure of the system looks almost identical to FFmpeg live streaming for media source extensions(MSE). This setup works in most situations but the moment B-Frames come into play everything breaks. FFmpeg starts to output Non-monotonous DTS in output stream and shortly after the video played via MSE freezes for a few seconds. As a layman my understanding of the situation is that :

    


      

    1. There are decode timestamp (DTS) and presentation timestamp (PTS) and an RTSP stream does not carry DTS information but allows somehow to relay PTS information.

      


    2. 


    3. Without B-Frames DTS=PTS but when B-Frames occur, the frames have to be decoded ahead of time for later frames to be displayed correctly, resulting in a PTS > DTS for these frames.

      


    4. 


    5. A mp4 muxer requires monotonously increasing DTS and DTS <= PTS. As the RTSP does not have DTS ffmpeg deduces DTS from PTS by default which results in jumps when a B-Frame occurs, hinted by the output Non-monotonous DTS in output stream. FFmpeg repairs the DTS by increment from the last valid DTS.

      &#xA;

    6. &#xA;

    7. Now DTS is running behind video playback time the video presentation breaks down. Even the mode segments does not help here as ffmpeg rewrote DTS to make it monotonous for the mp4 container and the underlying h264 does not include any timestamps so reordering can no longer happen.

      &#xA;

    8. &#xA;

    &#xA;

    As I have no control over the existence of B-Frames in the RTSP stream, I must assist FFmpeg in the deduction of DTS or at least fix the decoding order. Important : The live stream can only have a latency around one second so that expensive operations like reencoding the stream without B-Frames is not a valid option ! I would also prefer to not build a specific application with ffmpeg's lib and instead use FFmpeg only via command line.

    &#xA;

    Idea 1 : Buffer around one second of the rtsp packets, reoder them by PTS and then generate DTS based on PTS. The reordering should effectivly prevent the issues of non monotonous dts increase and presentation. While I think this is the most promising solution, it does not seem to be possible with ffmpeg cli ?

    &#xA;

    Idea 2 : Offset PTS by one second and set DTS to decode as soon as possible that frames are always ready for presentation. This assumes that B-Frames can be decoded after their respective partners are already decoded. I am not sure if this is even possible because the decoder may uses B-Frames as direct dependecies for the frames afterwards ?

    &#xA;

    Idea 3 : Somehow export ISO BMFF with non monotonous DTS for each packet and let the MediaSource sort the segments by DTS. As far as I understand the segments mode reorders by PTS and not DTS, but maybe someone has more knowledge here ?

    &#xA;

    I already did a ton of research but was not able to implement the mentioned ideas with ffmpeg cli. Does someone know how to do it or has someone successfully used a similar system ? I greatly appreciate other suggestions or technical feedback to improve my understanding. Solutions using ffmpeg as a programming library are also welcome but I am more interested in cli.

    &#xA;

    Here the current ffmpeg command that works well without B-Frames :

    &#xA;

    ffmpeg -nostats -hide_banner -loglevel fatal -i  -c copy -an -f mp4 -frag_duration 50000 -movflags &#x2B;frag_keyframe&#x2B;empty_moov&#x2B;default_base_moof pipe:1&#xA;

    &#xA;

    My understanding is based on these sources :
    &#xA;How to write a video stream containing B-frame and no DTS to a MP4 container ?
    &#xA;Does RTP timestamp represents the PTS of the audio/video present in media ?
    &#xA;h264 RTP timestamp
    &#xA;https://www.ietf.org/rfc/rfc3550.txt
    &#xA;https://www.w3.org/TR/mse-byte-stream-format-isobmff/

    &#xA;

  • Why is audio bitrate value of ffprobe output higher ?

    9 mars 2023, par 19xlr95

    When I check audio bitrate of my video via OS file details, media players or ffprobe -i my_video.mp4, I get the bitrate is 128 kbps. And I want to get more detailed meta information of the video by ffprobe -loglevel 0 -print_format json -show_format -show_streams my_video.mp4. However audio bitrate value of the output is 128615 bps.

    &#xA;

    I thought it should be 128000 not 128615. Or 128 x 1024 = 131072. I wonder why it is not one of the values that I assumed. Also how can I safely say that this 128615 bps is 128 kbps ?

    &#xA;

    Below is the detailed meta information for my video.

    &#xA;

    {&#xA;    "streams": [&#xA;        {&#xA;            "index": 0,&#xA;            "codec_name": "aac",&#xA;            "codec_long_name": "AAC (Advanced Audio Coding)",&#xA;            "profile": "LC",&#xA;            "codec_type": "audio",&#xA;            "codec_tag_string": "mp4a",&#xA;            "codec_tag": "0x6134706d",&#xA;            "sample_fmt": "fltp",&#xA;            "sample_rate": "48000",&#xA;            "channels": 2,&#xA;            "channel_layout": "stereo",&#xA;            "bits_per_sample": 0,&#xA;            "initial_padding": 0,&#xA;            "id": "0x1",&#xA;            "r_frame_rate": "0/0",&#xA;            "avg_frame_rate": "0/0",&#xA;            "time_base": "1/48000",&#xA;            "start_pts": 0,&#xA;            "start_time": "0.000000",&#xA;            "duration_ts": 965760,&#xA;            "duration": "20.120000",&#xA;            "bit_rate": "128615",&#xA;            "nb_frames": "946",&#xA;            "extradata_size": 2,&#xA;            "disposition": {&#xA;                "default": 1,&#xA;                "dub": 0,&#xA;                "original": 0,&#xA;                "comment": 0,&#xA;                "lyrics": 0,&#xA;                "karaoke": 0,&#xA;                "forced": 0,&#xA;                "hearing_impaired": 0,&#xA;                "visual_impaired": 0,&#xA;                "clean_effects": 0,&#xA;                "attached_pic": 0,&#xA;                "timed_thumbnails": 0,&#xA;                "captions": 0,&#xA;                "descriptions": 0,&#xA;                "metadata": 0,&#xA;                "dependent": 0,&#xA;                "still_image": 0&#xA;            },&#xA;            "tags": {&#xA;                "creation_time": "2023-02-20T09:00:58.000000Z",&#xA;                "language": "deu",&#xA;                "handler_name": "Core Media Audio",&#xA;                "vendor_id": "[0][0][0][0]"&#xA;            }&#xA;        },&#xA;        {&#xA;            "index": 1,&#xA;            "codec_name": "h264",&#xA;            "codec_long_name": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10",&#xA;            "profile": "High",&#xA;            "codec_type": "video",&#xA;            "codec_tag_string": "avc1",&#xA;            "codec_tag": "0x31637661",&#xA;            "width": 1080,&#xA;            "height": 1920,&#xA;            "coded_width": 1080,&#xA;            "coded_height": 1920,&#xA;            "closed_captions": 0,&#xA;            "film_grain": 0,&#xA;            "has_b_frames": 0,&#xA;            "sample_aspect_ratio": "1:1",&#xA;            "display_aspect_ratio": "9:16",&#xA;            "pix_fmt": "yuv420p",&#xA;            "level": 42,&#xA;            "color_range": "tv",&#xA;            "color_space": "bt709",&#xA;            "color_transfer": "bt709",&#xA;            "color_primaries": "bt709",&#xA;            "chroma_location": "left",&#xA;            "field_order": "progressive",&#xA;            "refs": 1,&#xA;            "is_avc": "true",&#xA;            "nal_length_size": "4",&#xA;            "id": "0x2",&#xA;            "r_frame_rate": "50/1",&#xA;            "avg_frame_rate": "50/1",&#xA;            "time_base": "1/50000",&#xA;            "start_pts": 0,&#xA;            "start_time": "0.000000",&#xA;            "duration_ts": 1006000,&#xA;            "duration": "20.120000",&#xA;            "bit_rate": "20958903",&#xA;            "bits_per_raw_sample": "8",&#xA;            "nb_frames": "1006",&#xA;            "extradata_size": 35,&#xA;            "disposition": {&#xA;                "default": 1,&#xA;                "dub": 0,&#xA;                "original": 0,&#xA;                "comment": 0,&#xA;                "lyrics": 0,&#xA;                "karaoke": 0,&#xA;                "forced": 0,&#xA;                "hearing_impaired": 0,&#xA;                "visual_impaired": 0,&#xA;                "clean_effects": 0,&#xA;                "attached_pic": 0,&#xA;                "timed_thumbnails": 0,&#xA;                "captions": 0,&#xA;                "descriptions": 0,&#xA;                "metadata": 0,&#xA;                "dependent": 0,&#xA;                "still_image": 0&#xA;            },&#xA;            "tags": {&#xA;                "creation_time": "2023-02-20T09:00:58.000000Z",&#xA;                "language": "und",&#xA;                "handler_name": "Core Media Video",&#xA;                "vendor_id": "[0][0][0][0]"&#xA;            }&#xA;        }&#xA;    ],&#xA;    "format": {&#xA;        "filename": "my_video.mp4",&#xA;        "nb_streams": 2,&#xA;        "nb_programs": 0,&#xA;        "format_name": "mov,mp4,m4a,3gp,3g2,mj2",&#xA;        "format_long_name": "QuickTime / MOV",&#xA;        "start_time": "0.000000",&#xA;        "duration": "20.120000",&#xA;        "size": "53309460",&#xA;        "bit_rate": "21196604",&#xA;        "probe_score": 100,&#xA;        "tags": {&#xA;            "major_brand": "mp42",&#xA;            "minor_version": "1",&#xA;            "compatible_brands": "isommp41mp42",&#xA;            "creation_time": "2023-02-20T09:00:58.000000Z"&#xA;        }&#xA;    }&#xA;}&#xA;

    &#xA;

    I checked 1 kbps is 1000 bps and assumed 128 kbps of the audio bitrate should be 128000 bps. But it is 128615 bps when I run ffprobe.

    &#xA;