Recherche avancée

Médias (91)

Autres articles (71)

  • Amélioration de la version de base

    13 septembre 2013

    Jolie sélection multiple
    Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
    Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)

  • Le plugin : Gestion de la mutualisation

    2 mars 2010, par

    Le plugin de Gestion de mutualisation permet de gérer les différents canaux de mediaspip depuis un site maître. Il a pour but de fournir une solution pure SPIP afin de remplacer cette ancienne solution.
    Installation basique
    On installe les fichiers de SPIP sur le serveur.
    On ajoute ensuite le plugin "mutualisation" à la racine du site comme décrit ici.
    On customise le fichier mes_options.php central comme on le souhaite. Voilà pour l’exemple celui de la plateforme mediaspip.net :
    < ?php (...)

  • Gestion de la ferme

    2 mars 2010, par

    La ferme est gérée dans son ensemble par des "super admins".
    Certains réglages peuvent être fais afin de réguler les besoins des différents canaux.
    Dans un premier temps il utilise le plugin "Gestion de mutualisation"

Sur d’autres sites (7079)

  • Play mp3 data with audiotrack with ffmpeg

    1er février 2014, par Ichigo Kurosaki

    I am designing an android app where i receive live mp3 data as stream from Red5 server and i need to play it.

    I cant play it using media player class as i don't have any url for the stream, nor i cant use files. Another option is to use Audio track class, but requires PCM data only. So need to convert mp3 to pcm, so using ffmpeg.

    My code for conversion is

    AVCodec *codec;
    AVCodecContext *c= NULL;
    int out_size, len;
    uint8_t *outbuf;

    int iplen=(*env)->GetArrayLength(env, mp3buf);
    int16_t inbuf[AUDIO_INBUF_SIZE + FF_INPUT_BUFFER_PADDING_SIZE];
    AVPacket avpkt;
    av_init_packet(&amp;avpkt);
    av_register_all();
    avcodec_register_all();

    codec = avcodec_find_decoder(CODEC_ID_MP3);
    if(!codec){
       __android_log_print(ANDROID_LOG_DEBUG, "logfromjni", "Codec not found");
    }
    c = avcodec_alloc_context();
    outbuf = malloc(AVCODEC_MAX_AUDIO_FRAME_SIZE);
    avpkt.data = (*env)->GetByteArrayElements(env,mp3buf,NULL);

    avpkt.size = (*env)->GetArrayLength(env, mp3buf);
    out_size = AVCODEC_MAX_AUDIO_FRAME_SIZE;
    int ao=avcodec_open(c, codec);
       if (ao &lt; 0) {
           __android_log_print(ANDROID_LOG_DEBUG, "logfromjni", "avcodec not open");
       }
       len = avcodec_decode_audio3(c, (short *)outbuf, &amp;out_size, &amp;avpkt);

    The Problem is avcodec_decode_audio3(c, (short *)outbuf, &amp;out_size, &amp;avpkt); returns -1 always.

    Cant figure out whats wrong.

    Any help appreciated.

  • Play MPEG-2 TS using MseStreamSource

    27 novembre 2022, par Nicolas Séveno

    I need to display a live video stream in a UWP application.

    &#xA;&#xA;

    The video stream comes from a GoPro. It is transported by UDP messages. It is a MPEG-2 TS stream. I can play it successfully using FFPlay with the following command line :

    &#xA;&#xA;

    ffplay -fflags nobuffer -f:v mpegts udp://:8554&#xA;

    &#xA;&#xA;

    I would like to play it with MediaPlayerElement without using a third party library.

    &#xA;&#xA;

    According to the following page :&#xA;https://learn.microsoft.com/en-us/windows/uwp/audio-video-camera/supported-codecs&#xA;UWP should be able to play it. (I installed the "Microsoft DVD" application in the Windows Store).

    &#xA;&#xA;

    I receive the MPEG-2 TS stream with a UdpClient. It works well.&#xA;I receive in each UdpReceiveResult a 12 bytes header, followed by 4, 5, 6, or 7 MPEGTS packets (each packet is 188 bytes, beginning with 0x47).

    &#xA;&#xA;

    I created a MseStreamSource :

    &#xA;&#xA;

    _mseStreamSource = new MseStreamSource();&#xA;_mseStreamSource.Opened &#x2B;= (_, __) =>&#xA;{&#xA;    _mseSourceBuffer = _mseStreamSource.AddSourceBuffer("video/mp2t");&#xA;    _mseSourceBuffer.Mode = MseAppendMode.Sequence;&#xA;};&#xA;_mediaPlayerElement.MediaSource = MediaSource.CreateFromMseStreamSource(_mseStreamSource);&#xA;

    &#xA;&#xA;

    This is how I send the messages to the MseStreamSource :

    &#xA;&#xA;

        UdpReceiveResult receiveResult = await _udpClient.ReceiveAsync();&#xA;    byte[] bytes = receiveResult.Buffer;&#xA;    mseSourceBuffer.AppendBuffer(bytes.AsBuffer());&#xA;

    &#xA;&#xA;

    The MediaPlayerElement displays the message "video not supported or incorrect file name". (not sure of the message, my Windows is in French).

    &#xA;&#xA;

    Is it a good idea to use the MseAppendMode.Sequence mode ?&#xA;What should I pass to the AppendBuffer method ? The raw udp message including the 12 bytes header or each MPEGTS 188 bytes packet ?

    &#xA;

  • Problem settingup a play command for my discord bot (music) ['Error : FFmpeg/avconv not found !']

    28 août 2023, par TitanFrex

    Im new to programing a discord bot, im more to the web developing enviroment, im trying to create by myself a play command song (only with one link) to try if the first join is working and actually play the song.

    &#xA;

    (Discord.js v14)

    &#xA;

    Unfortunately i was having a problem with FFMPEG.&#xA;This my actual module for the play.js command, where all the problem is happening.

    &#xA;

    const { joinVoiceChannel, createAudioPlayer, createAudioResource } = require(&#x27;@discordjs/voice&#x27;);&#xA;const ytdl = require(&#x27;ytdl-core&#x27;);&#xA;&#xA;module.exports = {&#xA;    devOnly: true,&#xA;    name: &#x27;play&#x27;,&#xA;    description: &#x27;Start to play a song!&#x27;,&#xA;    // options: Object[],&#xA;&#xA;    /**&#xA;     *&#xA;     * @param {Client} client&#xA;     * @param {Interaction} interaction&#xA;     */&#xA;    callback: async (client, interaction) => {&#xA;        const voiceChannel = interaction.member.voice.channel;&#xA;&#xA;        if (!voiceChannel) {&#xA;            return interaction.reply(&#x27;You must be in a voice channel to use this command.&#x27;);&#xA;        }&#xA;&#xA;        const connection = joinVoiceChannel({&#xA;            channelId: voiceChannel.id,&#xA;            guildId: interaction.guild.id,&#xA;            adapterCreator: interaction.guild.voiceAdapterCreator,&#xA;        });&#xA;&#xA;        const stream = ytdl(&#x27;URL_HERE&#x27;, { filter: &#x27;audioonly&#x27; });&#xA;        const resource = createAudioResource(stream);&#xA;&#xA;        const player = createAudioPlayer();&#xA;        connection.subscribe(player);&#xA;        player.play(resource);&#xA;&#xA;        interaction.reply({&#xA;            content: `Playing Song`,&#xA;            // ephemeral: true,&#xA;        });&#xA;    }&#xA;}&#xA;

    &#xA;

    The first error i was receving was 'Error : FFmpeg/avconv not found !', i tried to install it with some guides online. after couple of tries i get it right and the command 'ffmpeg -version' returns.

    &#xA;

    After that i tought it was workikng, but when i started my project, i receved the same error,. I tried to look up for a solution and i tried to get the process.env.PATH to see but i dont understand if its right or not.

    &#xA;

    After i removed the console.log(process.env.PATH), i get no errors in the terminal, but it will stil not play the song.

    &#xA;