Recherche avancée

Médias (91)

Autres articles (72)

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

  • Pas question de marché, de cloud etc...

    10 avril 2011

    Le vocabulaire utilisé sur ce site essaie d’éviter toute référence à la mode qui fleurit allègrement
    sur le web 2.0 et dans les entreprises qui en vivent.
    Vous êtes donc invité à bannir l’utilisation des termes "Brand", "Cloud", "Marché" etc...
    Notre motivation est avant tout de créer un outil simple, accessible à pour tout le monde, favorisant
    le partage de créations sur Internet et permettant aux auteurs de garder une autonomie optimale.
    Aucun "contrat Gold ou Premium" n’est donc prévu, aucun (...)

  • Dépôt de média et thèmes par FTP

    31 mai 2013, par

    L’outil MédiaSPIP traite aussi les média transférés par la voie FTP. Si vous préférez déposer par cette voie, récupérez les identifiants d’accès vers votre site MédiaSPIP et utilisez votre client FTP favori.
    Vous trouverez dès le départ les dossiers suivants dans votre espace FTP : config/ : dossier de configuration du site IMG/ : dossier des média déjà traités et en ligne sur le site local/ : répertoire cache du site web themes/ : les thèmes ou les feuilles de style personnalisées tmp/ : dossier de travail (...)

Sur d’autres sites (10785)

  • Use ffmpeg to assess media quality recursively and output to a file

    6 septembre 2021, par JD71

    Would anyone mind telling me how to use ffmpeg recursively to scan my collection, assess the video quality and export all of the output data to a file ? I've searched quite a bit on the web and there have been some close to what I'm looking for but not exactly. If I should be using something else, I'm open to suggestions as well.

    


    Thank you in advance for any assistance you can provide !

    


    J

    


  • libavcodec on media entirely in memory

    11 janvier 2019, par Nick

    I’m dealing with small micro videos that exist entirely in memory (as a string). So far, I haven’t been able to get avcodec to properly decode h264 in this way.

    I tried a custom AVIOContext that operates on containerized media :

    struct Stream { char* str; size_t pos; size_t size; };

    static int ReadStream(void* opaque, uint8* buf, int buf_size) {
     Stream* strm = reinterpret_cast(opaque);
     int read = strm->size-strm->pos;
     read = read < buf_size ? read : buf_size;
     memcpy(buf, strm->str+sto-æ>pos, read);
     memset(buf+read, 0, buf_size-read);
     strm->pos += read;
     return read;
    }

    static int64_t SeekStream(void *opaque, int64_t offset, int whence) {
     Stream* strm = reinterpret_cast(opaque);
     if (whence == AVSEEK_SIZE) {
       return strm->size;
     } else if (whence == SEEK_END) {
       strm->pos = strm->size;
     } else if (whence == SEEK_SET) {
       strm->pos = 0;
     }
     strm->pos += offset;
     return strm->pos;
    }

    int main(int argc, char *argv[]) {
     string content;
     GetContents("test.mp4", &content);

     avcodec_register_all();

     uint8* buff = (uint8*)malloc(4096 + AV_INPUT_BUFFER_PADDING_SIZE);
     Stream strm = { const_cast(content.data()), 0, content.size() };
     void* opaque = reinterpret_cast(&strm);

     AVFormatContext* fmtctx = avformat_alloc_context();
     AVIOContext* avctx = avio_alloc_context(buff, 4096, 0, opaque, &ReadStream, nullptr, &SeekStream);
     AVInputFormat* ifmt = av_find_input_format("mp4");
     AVDictionary* opts = nullptr;

     fmtctx->pb = avctx;
     avformat_open_input(&fmtctx, "", ifmt, &opts);
     avformat_find_stream_info(fmtctx, &opts);
    }

    But that always segfaults at find_stream_info.

    I also tried pre-demuxing the video stream into raw h264 and just sending the stream packets (e.g.) :

    int main(int argc, char *argv[]) {
     string content;
     GetContents("test.h264", &content);
     uint8* data = reinterpret_cast(const_cast(content.c_str()));

     avcodec_register_all();

     AVCodec* codec = avcodec_find_decoder(AV_CODEC_ID_H264);
     AVCodecContext* ctx = avcodec_alloc_context3(codec);

     ctx->width = 1080;
     ctx->height = 1920;
     avcodec_open2(ctx, codec, nullptr);

     AVPacket* pkt = av_packet_alloc();    
     AVFrame* frame = av_frame_alloc();

     pkt->data = data;
     pkt->size = 4096;
     avcodec_send_packet(ctx, pkt);
     data += 4096;
    }

    But that just gives a nondescript "error while decoding MB # #, bytestream #". Note that I’ve removed the error checking from the allocs, etc. to simplify the code, but I am checking to make sure everything is allocated and instantiated correctly.

    Any suggestions for where my misunderstanding or misuse of avcodec is ?

  • Unable to play webM file on chromium with Media Source Extensions. Works in firefox and vlc

    23 octobre 2018, par raul

    I’m currently trying to implement a video player using Media Source Extensions. Currently just a very simple proof of concept, following a tutorial I found here.

    I cloned their repo with all source code from github here and am testing the implementation on Chromium and Firefox with various video files.

    Everything worked well with the example webm files in the repo for both browsers.

    Next I tried to convert a video I downloaded from some random site using ffmpeg and mse-tools to "align the clusters" of the webm file using the following commands :

    ffmpeg -i randomvideo.mp4 -c:v libvpx -c:a libvorbis output.webm
    mse_webm_remuxer output.webm aligned.webm

    Again, all was well on both browsers.

    Finally, I wanted to convert a very simple animation I created in blender (rendered with h264 in mp4).

    I tried converting the resulting file using the same process as above and the file played normally on firefox, but did not load on chromium.

    I assume I am commiting some error when converting the file, but inspecting the attributes of the final file with vlc and ffprobe, I could not find any obvious problems.

    Any ideas as to what I am doing wrong ?

    One final test I did was to go to this site to get some sample webm files.

    I downloaded the "Big Buck Bunny Trailer in WebM" and "Elephants Dream as WebM File".

    Both files worked in firefox, but the "Elephants Dream" file would not play in chromium.

    I am on a linux machine (Arch Linux distro) with the following versions of the browsers :

    Chromium Version 69.0.3497.100 (Official Build) Arch Linux (64-bit)

    Firefox 62.0.3 (64-bit)

    I have shared the file I created from the blender animation (very small - only 36 KB) on google drive here in case anyone wants to check it out.