Recherche avancée

Médias (3)

Mot : - Tags -/image

Autres articles (94)

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

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

Sur d’autres sites (6542)

  • Change the default audio and video codec loaded by avformat_alloc_output_context2

    8 juin 2021, par mythili3093

    I'm using ffmpeg library for live streaming via RTMP. I want to know how to give my choice of audio and video codec for the particular format in avformat_alloc_output_context2.

    


    In Detail :

    


    The following command works perfectly for me.

    


    ffmpeg -re -stream_loop -1 -i ~/Downloads/Microsoft_Surface.mp4 -vcodec copy -c:a aac -b:a 160k -ar 44100 -strict -2 -f flv -flvflags no_duration_filesize rtmp://192.168.1.7/live/surface


    


    In the output, I have set my audio codec to be aac and copied the video codec from input, which is H264.
I want to emulate this in the library, but don't know how to.

    


    avformat_alloc_output_context2(&_ctx, NULL, "flv", NULL);


    


    Above code sets oformat audio codec to ADPCM_SWF and video codec to FLV1. How to change that to AAC and H264 ?

    


    So far, used av_guess_format to construct AVOutputFormat. It accepts only format as input. And I don't know where to mention audio and video codec.

    


    AVOutputFormat* output_format = av_guess_format("flv", NULL, NULL);


    


    Also tried giving filename to avformat_alloc_output_context2 with the rest of the parameters NULL.

    


    AVOutputFormat* output_format = av_guess_format(NULL, "flv_acc_sample.flv", NULL);


    


    This file has AAC audio and H264 video. But still ffmpeg loads oformat with ADPCM_SWF audio and FLV1 video codecs.

    


    Searched stackoverflow for similar questions, but could not find the solution I was looking for.
Any hint/guidance is hugely appreciated. Thank you.

    


  • ffmpeg/libav easy way to set options

    13 mars 2023, par Patrick

    I recently messed around with ffplay code to see how it works and I noticed it uses a very straight forward way to parse and set all the command line options using the library internal cmdutils.h. I personally find the av_opt_set used in other examples of av wrappers quite confusing (Some args are explicitly stored in the struct, some in priv_data ? Im allowed/supposed to modify void*priv_data ? Which objects can I use av_opt_set on ? Which args go in which object and are they declared or in priv_data ? Where is this documented ?).
In ffplay all args are simply stored in an array and distributed to the right codec/muxer/format instance using cmdutil.
Id like to have exactly this functionality for my program (so that i can simply read a json config and don't need to care about it any further). Apparently the necessary OptionDef arrays are already defined in different implementation files.

    


    However my actual question : I noticed the OptionDef array definition in ffplay does not contain all options (only some from cmdutil included via macro). But other options e.g. fflags are not included anywhere (only defined somewhere else) and yet they work. So how does cmdutil set/parse them ?

    


    I hope someone can answer this, since simply adapting cmdutil would be a quite simple solution for me. Id also really appreciate some general guidance regarding my previous questions.

    


    Many Thanks in advance !

    


    I tried looking into the ffmpeg source and expected all OptionDef array definitions to be connected/collected inside a single array such that cmdutil can parse them easily. However this isn't the case and still some cmd options work. Therefore Im confused on how cmtutil is able to parse them

    


  • How to use the latest version of @ffmpeg/ffmpeg in a React.js project ?

    21 janvier, par Muzammil Raza

    I'm working on a React.js project where I need to process videos in the browser using @ffmpeg/ffmpeg. I noticed that the package has been updated recently, and the API and functions have changed.

    


    In the older version, I used to import the package and functions like this :

    


    import { createFFmpeg, fetchFile } from '@ffmpeg/ffmpeg';


    


    However, in the latest version, I see that the import has changed to :

    


    import { FFmpeg } from '@ffmpeg/ffmpeg';


    


    and all new functions are changed I have checked in by log :

    


    I have check by console ffmpeg, it show :

    


    createDir: path => {…}
deleteDir: path => {…}
deleteFile: path => {…}
exec: ƒ ( /** ffmpeg command line args */ args)
listDir: path => {…}
load: ƒ ()
loaded: true
readFile: ƒ (path)
rename: (oldPath, newPath) => {…}
terminate: () => {…}
writeFile: (path, data) => {…}


    


    I'm not sure about the changes in the API and functions, and I couldn't find any updated documentation or guides on how to use the latest version of @ffmpeg/ffmpeg in a React.js project.

    


    I have task of video processing for streaming and need to add logo in video.

    


    Could someone please provide guidance on how to use the latest version of @ffmpeg/ffmpeg in a React.js project ? Specifically, I'm looking for information on the changes in the API, the new function names, and how to perform video processing tasks with the latest version.

    


    If anyone has experience with the latest version of @ffmpeg/ffmpeg or knows the updated usage, any help or examples would be greatly appreciated. Thank you !