Recherche avancée

Médias (1)

Mot : - Tags -/biographie

Autres articles (76)

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

  • De l’upload à la vidéo finale [version standalone]

    31 janvier 2010, par

    Le chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
    Upload et récupération d’informations de la vidéo source
    Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
    Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)

Sur d’autres sites (9146)

  • libavutils : Add parse_r helper for MIPS

    18 juillet 2020, par Jiaxun Yang
    libavutils : Add parse_r helper for MIPS
    

    That helper grab from kernel code can allow us to inline
    newer instructions (not implemented by the assembler) in
    a elegant manner.

    Signed-off-by : Jiaxun Yang <jiaxun.yang@flygoat.com>
    Reviewed-by : Shiyou Yin <yinshiyou-hf@loongson.cn>
    Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>

    • [DH] libavutil/mips/asmdefs.h
  • When using libva* (ffmpeg) encoded GIF images, an error is reported when compiling the demo

    10 août 2023, par yangjinhui2936

    issuse : I need to use the GIF encoding feature in FFMPEG to encode argb images as gifs.Because the encoding effect of using GIF library is not as good as the effect of FFMPEG.&#xA;However, several libraries like avcodec were too bulky, so I did some cropping.I just want to keep the functionality of GIF encoding.&#xA;Below is my makefile for cropping ffmpeg :

    &#xA;

    #!/bin/sh&#xA;# ./configure --prefix=$(pwd)/output --arch=arm --target-os=linux --enable-cross-compile --disable-asm --cross-prefix=arm-linux-gnueabihf- &#xA;./configure --prefix=$(pwd)/output --target-os=linux --disable-asm \&#xA;--disable-gpl --enable-nonfree --enable-error-resilience --enable-debug --enable-shared --enable-small --enable-zlib \&#xA;--disable-ffmpeg --disable-ffprobe --disable-ffplay --disable-programs --disable-symver\&#xA; --disable-doc --disable-htmlpages --disable-manpages --disable-podpages --disable-decoder=h264 --enable-avformat \&#xA; --disable-txtpages --enable-avcodec --enable-avutil \&#xA; --disable-avresample --disable-avfilter --disable-avdevice --disable-postproc \&#xA; --disable-swscale --enable-decoder=gif --enable-demuxer=gif --enable-muxer=gif --disable-iconv \&#xA; --disable-v4l2-m2m --disable-indevs --disable-outdevs&#xA;&#xA;make clean&#xA;make -j8&#xA;&#xA;make install&#xA;

    &#xA;

    Then link the compiled so to the gif demo.&#xA;Blew is gif demo code(He was automatically generated by chatgpt, and I want to verify it) :

    &#xA;

    #include &#xA;// #include "output/include/imgutils.h"&#xA;#include "libavcodec/avcodec.h"&#xA;#include "libavformat/avformat.h"&#xA;#include "libavutil/avutil.h"&#xA;&#xA;int main() {&#xA;    AVCodec *enc_codec;&#xA;    AVCodecContext *enc_ctx = NULL;&#xA;    AVStream *stream = NULL;&#xA;    int ret;&#xA;&#xA;    AVFormatContext *fmt_ctx = avformat_alloc_context();&#xA;    if (!fmt_ctx) {&#xA;        fprintf(stderr, "Could not allocate format context\n");&#xA;        return 1;&#xA;    }&#xA;    &#xA;    AVInputFormat *input_fmt = av_find_input_format("image2");&#xA;    if ((ret = avformat_open_input(&amp;fmt_ctx, "input.bmp", input_fmt, NULL)) &lt; 0) {&#xA;        fprintf(stderr, "Could not open input file %d\n", ret);&#xA;        return ret;&#xA;    }&#xA;&#xA;    AVCodec *dec_codec = avcodec_find_decoder(AV_CODEC_ID_BMP);&#xA;    if (!dec_codec) {&#xA;        fprintf(stderr, "Decoder not found\n");&#xA;        return 1;&#xA;    }&#xA;    &#xA;    AVCodecContext *dec_ctx = avcodec_alloc_context3(dec_codec);&#xA;    if (!dec_ctx) {&#xA;        fprintf(stderr, "Could not allocate decoder context\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    if ((ret = avcodec_open2(dec_ctx, dec_codec, NULL)) &lt; 0) {&#xA;        fprintf(stderr, "Could not open decoder\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    AVOutputFormat *out_fmt = av_guess_format("gif", NULL, NULL);&#xA;    if (!out_fmt) {&#xA;        fprintf(stderr, "Could not find output format\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    AVFormatContext *out_ctx = NULL;&#xA;    if ((ret = avformat_alloc_output_context2(&amp;out_ctx, out_fmt, NULL, NULL)) &lt; 0) {&#xA;        fprintf(stderr, "Could not allocate output context\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    stream = avformat_new_stream(out_ctx, NULL);&#xA;    if (!stream) {&#xA;        fprintf(stderr, "Could not create new stream\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    enc_codec = avcodec_find_encoder(AV_CODEC_ID_GIF);&#xA;    if (!enc_codec) {&#xA;        fprintf(stderr, "Encoder not found\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    enc_ctx = avcodec_alloc_context3(enc_codec);&#xA;    if (!enc_ctx) {&#xA;        fprintf(stderr, "Could not allocate encoder context\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    if ((ret = avcodec_parameters_from_context(stream->codecpar, dec_ctx)) &lt; 0) {&#xA;        fprintf(stderr, "Could not copy decoder parameters\n");&#xA;        return 1;&#xA;    }&#xA;&#xA;    if ((ret = avcodec_open2(enc_ctx, enc_codec, NULL)) &lt; 0) {&#xA;        fprintf(stderr, "Could not open encoder\n");&#xA;        return 1;&#xA;    }&#xA;    &#xA;    enc_ctx->pix_fmt = AV_PIX_FMT_RGB8; &#xA;    enc_ctx->width = dec_ctx->width; &#xA;    enc_ctx->height = dec_ctx->height; &#xA;    enc_ctx->time_base = (AVRational){1, 25}; &#xA;&#xA;    avformat_init_output(out_ctx, NULL);&#xA;&#xA;    if (!(out_fmt->flags &amp; AVFMT_NOFILE)) {&#xA;        if ((ret = avio_open(&amp;out_ctx->pb, "output.gif", AVIO_FLAG_WRITE)) &lt; 0) {&#xA;            fprintf(stderr, "Could not open output file\n");&#xA;            return ret;&#xA;        }&#xA;    }&#xA;&#xA;    avformat_write_header(out_ctx, NULL);&#xA;&#xA;    AVFrame *frame = av_frame_alloc();&#xA;    AVPacket pkt;&#xA;    int frame_count = 0;&#xA;&#xA;    while (av_read_frame(fmt_ctx, &amp;pkt) >= 0) {&#xA;        avcodec_send_packet(dec_ctx, &amp;pkt);&#xA;        while (avcodec_receive_frame(dec_ctx, frame) == 0) {&#xA;            avcodec_send_frame(enc_ctx, frame);&#xA;            while (avcodec_receive_packet(enc_ctx, &amp;pkt) == 0) {&#xA;                pkt.stream_index = stream->index;&#xA;                av_interleaved_write_frame(out_ctx, &amp;pkt);&#xA;                av_packet_unref(&amp;pkt);&#xA;            }&#xA;&#xA;            frame_count&#x2B;&#x2B;;&#xA;            printf("Encoded frame %d\n", frame_count);&#xA;        }&#xA;        av_packet_unref(&amp;pkt);&#xA;    }&#xA;&#xA;    av_write_trailer(out_ctx);&#xA;&#xA;    avcodec_close(enc_ctx);&#xA;    avcodec_free_context(&amp;enc_ctx);&#xA;    avcodec_close(dec_ctx);&#xA;    avcodec_free_context(&amp;dec_ctx);&#xA;    av_frame_free(&amp;frame);&#xA;&#xA;    avformat_close_input(&amp;fmt_ctx);&#xA;    avformat_free_context(fmt_ctx);&#xA;    avio_close(out_ctx->pb);&#xA;    avformat_free_context(out_ctx);&#xA;&#xA;    return 0;&#xA;}&#xA;&#xA;

    &#xA;

    Belw is shell of compile script for gif :

    &#xA;

    #!/bin/sh&#xA;gcc -o x2gif x2gif.c -L ./output/lib/ -l:libavformat.a -l:libavcodec.a -l:libavutil.a -lz -I ./output/include/&#xA;

    &#xA;

    Unfortunately, the compilation did not pass.&#xA;How can I troubleshoot and resolve this issue ?

    &#xA;

    ./output/lib/libavutil.a(lfg.o): In function `av_bmg_get&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/lfg.c:59: undefined reference to `log&#x27;&#xA;./output/lib/libavutil.a(hwcontext_cuda.o): In function `cuda_free_functions&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:175: undefined reference to `dlclose&#x27;&#xA;./output/lib/libavutil.a(hwcontext_cuda.o): In function `cuda_load_functions&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:192: undefined reference to `dlopen&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:194: undefined reference to `dlsym&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:195: undefined reference to `dlsym&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:196: undefined reference to `dlsym&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:197: undefined reference to `dlsym&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:198: undefined reference to `dlsym&#x27;&#xA;./output/lib/libavutil.a(hwcontext_cuda.o):/data1/yang/tool/ffmpeg-3.4.4/./compat/cuda/dynlink_loader.h:199: more undefined references to `dlsym&#x27; follow&#xA;./output/lib/libavutil.a(rational.o): In function `av_d2q&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/rational.c:120: undefined reference to `floor&#x27;&#xA;./output/lib/libavutil.a(eval.o): In function `eval_expr&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:184: undefined reference to `exp&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:185: undefined reference to `exp&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:189: undefined reference to `floor&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:190: undefined reference to `ceil&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:191: undefined reference to `trunc&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:192: undefined reference to `round&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:263: undefined reference to `pow&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:300: undefined reference to `floor&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:309: undefined reference to `pow&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:315: undefined reference to `hypot&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:316: undefined reference to `atan2&#x27;&#xA;./output/lib/libavutil.a(eval.o): In function `ff_exp10&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/ffmath.h:44: undefined reference to `exp2&#x27;&#xA;./output/lib/libavutil.a(eval.o): In function `parse_primary&#x27;:&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:417: undefined reference to `sinh&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:418: undefined reference to `cosh&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:419: undefined reference to `tanh&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:420: undefined reference to `sin&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:421: undefined reference to `cos&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:422: undefined reference to `tan&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:423: undefined reference to `atan&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:424: undefined reference to `asin&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:425: undefined reference to `acos&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:426: undefined reference to `exp&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:427: undefined reference to `log&#x27;&#xA;/data1/yang/tool/ffmpeg-3.4.4/libavutil/eval.c:428: undefined reference to `fabs&#x27;&#xA;

    &#xA;

  • Anomalie #3436 (Nouveau) : Forum : id_thread = 0

    5 mai 2015, par Debondt Didier

    Si j’utilise l’API objet pour créer des éléments de forum, sans spécifier explicitement un id_thread :

    $id_forum = objet_inserer(’forum’, null, $c) ;
    

    Il est possible que le champ id_thread soit égale à 0. Hors cela ne devrait jamais être le cas, il devrait à minima être égale à id_forum.