Recherche avancée

Médias (1)

Mot : - Tags -/Christian Nold

Autres articles (77)

  • MediaSPIP version 0.1 Beta

    16 avril 2011, par

    MediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

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

  • Mise à jour de la version 0.1 vers 0.2

    24 juin 2013, par

    Explications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
    Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...)

Sur d’autres sites (14666)

  • AVCodecContex returns zero for width and height in android

    7 mars 2014, par Whoami

    Not sure what was my mistake in the below code. I m trying with ffmpeg 0.11 and SDL2.0 in android.

    QUESTION :
    Why Width and Height of the CodecContext gives me always zero ?..

    int main(int argc, char *argv[])
    {

       int flags;
       flags = SDL_INIT_VIDEO | SDL_INIT_TIMER;

       if (SDL_Init (flags)) {
           LOGD ("Could not intialize Video for SDL: %s \n", SDL_GetError());
       }
       else
           LOGD (" SUCCESS: SDL_Init ");

       // ffmpeg Register all services..
       ffmpeg_register_all ();


       pFrame = avcodec_alloc_frame ();
       context = avformat_alloc_context();

       err = avformat_open_input (&context, "rtsp:ip:port", NULL, NULL);
       if ( err < 0) {
           __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Unable to open rtsp... ");

           return -1;
       }

       for (i = 0; i < context->nb_streams; i++)
       {              
           // Find the Decoder.
           codec = avcodec_find_decoder(context->streams[i]->codec->codec_id);
           if (codec->type  == AVMEDIA_TYPE_VIDEO ) {
               __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Found Video Streaming..  ");
               videoStreamIndex = i;

           }
       }

       // Play RTSP
       av_read_play(context);

       // Get Codec Context.
       pCodecCtx = context->streams[videoStreamIndex]->codec;
       if ( pCodecCtx == NULL )
           __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "CodecCtx is NULL>>> ");
       else
           __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "CodecCtx is &lt;&lt;<ok>>> ");


       //Find the Decoder.
       pCodec = avcodec_find_decoder (pCodecCtx->codec_id);
       avcodec_open2 (pCodecCtx, pCodec, NULL);


       int w = pCodecCtx->width;  // Why me getting 0 ?
       int h = pCodecCtx->height;

       window = SDL_CreateWindow ("Test ffmpeg",SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, w, h, SDL_WINDOW_SHOWN|SDL_WINDOW_ALLOW_HIGHDPI);
       // What this HIGHDPI Means ??

       if ( window != NULL )
       {
           LOGD (" WINDOW CREATED.. , create Renderer ..");
           renderer = SDL_CreateRenderer (window, -1, 0);  
       }
       else
       {
           LOGD (" Invalid SDL Window ");  
       }
    __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Width and Height of PCodeccCtx.. %d .. %d " , w, h);
       return 0;
    }
    </ok>
  • AVCodecContex returns zero for width and height in android

    17 février 2023, par Whoami

    Not sure what was my mistake in the below code. I m trying with ffmpeg 0.11 and SDL2.0 in android.

    &#xA;&#xA;

    QUESTION :&#xA;Why Width and Height of the CodecContext gives me always zero ?..

    &#xA;&#xA;

    int main(int argc, char *argv[])&#xA;{&#xA;&#xA;    int flags;&#xA;    flags = SDL_INIT_VIDEO | SDL_INIT_TIMER;&#xA;&#xA;    if (SDL_Init (flags)) {&#xA;        LOGD ("Could not intialize Video for SDL: %s \n", SDL_GetError());&#xA;    }&#xA;    else &#xA;        LOGD (" SUCCESS: SDL_Init ");&#xA;&#xA;    // ffmpeg Register all services..&#xA;    ffmpeg_register_all (); &#xA;&#xA;&#xA;    pFrame = avcodec_alloc_frame ();&#xA;    context = avformat_alloc_context();&#xA;&#xA;    err = avformat_open_input (&amp;context, "rtsp:ip:port", NULL, NULL);&#xA;    if ( err &lt; 0) {&#xA;        __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Unable to open rtsp... ");&#xA;&#xA;        return -1;&#xA;    }&#xA;&#xA;    for (i = 0; i &lt; context->nb_streams; i&#x2B;&#x2B;)&#xA;    {               &#xA;        // Find the Decoder.&#xA;        codec = avcodec_find_decoder(context->streams[i]->codec->codec_id);&#xA;        if (codec->type  == AVMEDIA_TYPE_VIDEO ) {&#xA;            __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Found Video Streaming..  ");&#xA;            videoStreamIndex = i;&#xA;&#xA;        }&#xA;    }&#xA;&#xA;    // Play RTSP&#xA;    av_read_play(context);&#xA;&#xA;    // Get Codec Context.&#xA;    pCodecCtx = context->streams[videoStreamIndex]->codec;&#xA;    if ( pCodecCtx == NULL )&#xA;        __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "CodecCtx is NULL>>> ");&#xA;    else&#xA;        __android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "CodecCtx is &lt;&lt;<ok>>> ");&#xA;&#xA;&#xA;    //Find the Decoder.&#xA;    pCodec = avcodec_find_decoder (pCodecCtx->codec_id);&#xA;    avcodec_open2 (pCodecCtx, pCodec, NULL);&#xA;&#xA;&#xA;    int w = pCodecCtx->width;  // Why me getting 0 ? &#xA;    int h = pCodecCtx->height;&#xA;&#xA;    window = SDL_CreateWindow ("Test ffmpeg",SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, w, h, SDL_WINDOW_SHOWN|SDL_WINDOW_ALLOW_HIGHDPI);&#xA;    // What this HIGHDPI Means ??&#xA;&#xA;    if ( window != NULL ) &#xA;    {&#xA;        LOGD (" WINDOW CREATED.. , create Renderer ..");&#xA;        renderer = SDL_CreateRenderer (window, -1, 0);  &#xA;    }&#xA;    else&#xA;    {&#xA;        LOGD (" Invalid SDL Window ");  &#xA;    }&#xA;__android_log_print(ANDROID_LOG_DEBUG, "ffmpegguard", "Width and Height of PCodeccCtx.. %d .. %d " , w, h); &#xA;    return 0;&#xA;}&#xA;</ok>

    &#xA;

  • avcodec/error_resilience : avoid accessing previous or next frames tables beyond height

    14 novembre 2015, par Michael Niedermayer
    avcodec/error_resilience : avoid accessing previous or next frames tables beyond height
    

    The height of tables can be rounded up for MBAFF but this does not imply that is also true
    for the previous frames

    Fixes out of array reads
    Fixes : c106b36fa36db8ff8f3ed0c82be7bea2/asan_heap-oob_32699f0_6321_467b9a1d7e03d7cfd310b7e65dc53bcc.mov

    Found-by : Mateusz "j00ru" Jurczyk and Gynvael Coldwind
    Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>

    • [DH] libavcodec/error_resilience.c