Recherche avancée

Médias (1)

Mot : - Tags -/stallman

Autres articles (28)

  • Les vidéos

    21 avril 2011, par

    Comme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
    Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
    Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...)

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

Sur d’autres sites (3627)

  • lavc/hevcdec : move active VPS from HEVCParamSets to HEVCContext

    5 juin 2024, par Anton Khirnov
    lavc/hevcdec : move active VPS from HEVCParamSets to HEVCContext
    

    Active VPS is a property of the decoding process, not of the list of
    parameter sets.

    Check that the VPS can only change in a base layer - while this can
    never happen currently (as no other layers can exist in the decoder), it
    will become useful when multilayer decoding is supported.

    • [DH] libavcodec/hevc/hevcdec.c
    • [DH] libavcodec/hevc/hevcdec.h
    • [DH] libavcodec/hevc/ps.c
    • [DH] libavcodec/hevc/ps.h
  • AWS Lambda - FFmpeg to extract frames doesn't write anything

    7 avril 2024, par Stormsson

    I have a lambda with a ffmpeg layer on it.

    


    The command i want to use is basically

    


    ffmpeg -i video.mp4 -qscale:v 2 -vf fps=8 '%04d.jpg'


    


    so it has an input file, and creates 8 frames per second in the same folder

    


    This code seems to do everything except writing the files, what am I missing ?

    


    import ...
SIGNED_URL_TIMEOUT = 60
FPS_SAMPLES = 8

def lambda_handler(event, context):
    # Set up logging.
    logger = logging.getLogger(__name__)

    s3_client = boto3.client('s3')

    s3_source_bucket = event['Records'][0]['s3']['bucket']['name']
    s3_source_key = event['Records'][0]['s3']['object']['key']

    s3_source_basename = os.path.splitext(os.path.basename(s3_source_key))[0]

    logger.info( "bucket: %s, key: %s, basename: %s",s3_source_bucket, s3_source_key, s3_source_basename)

    s3_source_signed_url = s3_client.generate_presigned_url('get_object',
    Params={'Bucket': s3_source_bucket, 'Key': s3_source_key},
    ExpiresIn=SIGNED_URL_TIMEOUT)

    with tempfile.TemporaryDirectory() as tmpdir:
        os.chdir(tmpdir) # change the current folder to that one (current one is in     os.getcwd())
        cwd = os.getcwd()
        ffmpeg_cmd = "/opt/bin/ffmpeg -i \"" + s3_source_signed_url + "\" -qscale:v 2 -vf fps="+str(FPS_SAMPLES)+" "+ cwd + "/'%04d.jpg'"
    print("COMMAND: "+ffmpeg_cmd)
    
        command1 = shlex.split(ffmpeg_cmd)
        p1 = subprocess.run(command1, stdout=subprocess.PIPE, stderr=subprocess.PIPE)

        # List all files and directories in the current directory
        contents = os.listdir(cwd)
    
        # Print the contents
        print(f"Contents of {cwd}:")
        for item in contents:
            print(item) # <--- NOthing here...

   
return {
    'statusCode': 200,
    'body': json.dumps("bucket: %s, key: %s, basename: %s" % (s3_source_bucket, s3_source_key, s3_source_basename))
}


    


  • How can I automatically embed commit information into a subtitles file that I'm tracking ?

    23 février 2015, par microspace

    I use git to track *.ass subtitle files.
    Here is example of *.ass file :

    [Script Info]
    ; Script generated by Aegisub 3.1.2
    ; http://www.aegisub.org/
    Title: Default Aegisub file
    ScriptType: v4.00+

    [V4+ Styles]
    Format: Name, Fontname, Fontsize, PrimaryColour, SecondaryColour, OutlineColour,    BackColour, Bold, Italic, Underline, StrikeOut, ScaleX, ScaleY, Spacing, Angle, BorderStyle, Outline, Shadow, Alignment, MarginL, MarginR, MarginV, Encoding
    Style: Default,Arial,20,&H00FFFFFF,&H000000FF,&H00000000,&H00000000,0,0,0,0,100,100,0,0,1,2,2,2,10,10,10,1
    Style: titr,DejaVu    

    Sans,20,&H007DDBFA,&H000000FF,&H00000000,&HFF000000,0,0,0,0,100,100,0,0,1,2,2,1,10,10,10,1

    [Events]
    Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text
    Dialogue: 0,0:00:00.46,0:00:11.22,Default,,0,0,0,,Если это можно было бы
    Dialogue: 0,0:00:03.44,0:00:08.96,titr,,0,0,0,,{\pos(20,240)\fad(600,600)}бывший министр

    After commit I burn subtitles into video :

    ffmpeg -i video.avi -vf "ass=subtitle.ass" out.avi

    My goal is to show commit date for 10 second at the start of movie. This should be done automatically.

    1) It can be easily done with by modifying subtitle.ass itself, but I can’t do it after commit and there are other reasons.

    2) It can be done by ffmpeg from command line : How to use ffmpeg to add a text to avi video ?

    Problem is that in this case text will be shown for the whole lenght of movie.

    3) I can copy *.ass file to temporary directory, insert date, render and delete *.ass file.

    Is there a simpler way ?