Recherche avancée

Médias (91)

Autres articles (68)

  • Gestion des droits de création et d’édition des objets

    8 février 2011, par

    Par défaut, beaucoup de fonctionnalités sont limitées aux administrateurs mais restent configurables indépendamment pour modifier leur statut minimal d’utilisation notamment : la rédaction de contenus sur le site modifiables dans la gestion des templates de formulaires ; l’ajout de notes aux articles ; l’ajout de légendes et d’annotations sur les images ;

  • Keeping control of your media in your hands

    13 avril 2011, par

    The vocabulary used on this site and around MediaSPIP in general, aims to avoid reference to Web 2.0 and the companies that profit from media-sharing.
    While using MediaSPIP, you are invited to avoid using words like "Brand", "Cloud" and "Market".
    MediaSPIP is designed to facilitate the sharing of creative media online, while allowing authors to retain complete control of their work.
    MediaSPIP aims to be accessible to as many people as possible and development is based on expanding the (...)

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

Sur d’autres sites (9976)

  • rtmp : Return an error when the client bandwidth is incorrect

    25 juillet 2012, par Samuel Pitoiset

    rtmp : Return an error when the client bandwidth is incorrect

  • Django StreamingHttpResponse : How to quit Popen process when client disconnects ?

    2 avril 2022, par seriousm4x

    In django, i want to convert a m3u8 playlist to mp4 and stream it to the client with ffmpeg pipe. The code works and the ffmpeg process also quits, but only when client waits till the end and received the whole file.

    


    I want to quit the process when the client disconnects but the process keeps running forever.

    


    I have this code :

    


    import subprocess
from functools import partial
from django.http.response import StreamingHttpResponse
from django.shortcuts import get_object_or_404
from django.utils.text import slugify


def stream(request, uuid):
    vod = get_object_or_404(Vod, uuid=uuid)

    def iterator(proc):
        for data in iter(partial(proc.stdout.read, 4096), b""):
            if not data:
                proc.kill()
            yield data

    cmd = ["ffmpeg", "-i", "input.m3u8", "-c", "copy", "-bsf:a", "aac_adtstoasc", "-movflags", "frag_keyframe+empty_moov", "-f", "mp4", "-"]
    proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.DEVNULL)
    response = StreamingHttpResponse(iterator(proc), content_type="video/mp4")
    response["Content-Disposition"] = f"attachment; filename={slugify(vod.date)}-{slugify(vod.title)}.mp4"
    return response



    


    I've seen this answer but I'm not sure if I could use threading to solve my problem.

    


  • configure : suppress "enumerated type mixed with another type" for icc

    3 janvier 2013, par Michael Niedermayer

    configure : suppress "enumerated type mixed with another type" for icc