
Recherche avancée
Médias (91)
-
Collections - Formulaire de création rapide
19 février 2013, par
Mis à jour : Février 2013
Langue : français
Type : Image
-
Les Miserables
4 juin 2012, par
Mis à jour : Février 2013
Langue : English
Type : Texte
-
Ne pas afficher certaines informations : page d’accueil
23 novembre 2011, par
Mis à jour : Novembre 2011
Langue : français
Type : Image
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Richard Stallman et la révolution du logiciel libre - Une biographie autorisée (version epub)
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Rennes Emotion Map 2010-11
19 octobre 2011, par
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (16)
-
Gestion générale des documents
13 mai 2011, parMédiaSPIP ne modifie jamais le document original mis en ligne.
Pour chaque document mis en ligne il effectue deux opérations successives : la création d’une version supplémentaire qui peut être facilement consultée en ligne tout en laissant l’original téléchargeable dans le cas où le document original ne peut être lu dans un navigateur Internet ; la récupération des métadonnées du document original pour illustrer textuellement le fichier ;
Les tableaux ci-dessous expliquent ce que peut faire MédiaSPIP (...) -
Les vidéos
21 avril 2011, parComme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...) -
Les formats acceptés
28 janvier 2010, parLes commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
ffmpeg -codecs ffmpeg -formats
Les format videos acceptés en entrée
Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
Les formats vidéos de sortie possibles
Dans un premier temps on (...)
Sur d’autres sites (2700)
-
Android : mp4 file plays when downloaded but when choosing "Video" player gets "Cannot play video"
11 juillet 2019, par gviewI’ve converted the video to an mp4 with ffmpeg using the h264 codec and AAC, and used the baseline profile.
Videos are 540x360x250kbps
I then ran qt-faststart on the file to move the atoms into the right order.
I’ve stuck the file up on a wiki we use and created a link to it.
My test phone is a Samsung Galaxy S3.
When I browse to the page that has links to the mp4’s on it, and I click on them, I get a popup window with 2 options : Internet and Video.
If I download the videos using the "Internet" option, I can play them on the phone without issue.
I’ve done other encodings with the main profile as well, and these also play fine. I thought that a powerful phone like the s3 would be able to handle the more advanced compression schemes available in h264, however I’ve also browsed the Android docs in regards to supported video formats, and it seems to state that only the "baseline" compression profile is supported.
Regardless, what doesn’t work is trying to use the "Video" option which I assume tries to stream the video.
For the wiki in question, clicking on the link reveals that the content-type and content-length headers are being set :
Content-Length 6175996
Content-Type video/mp4;charset=UTF-8Clicking on the link with a browser invokes a player (Quicktime in most cases) that can play the mp4’s.
Is there more to having the file HTTP streamable beyond making a link to it ? Why won’t my Android 4 play these files ?
UPDATE :
I decided to make a quick HTML5 page using the video tag, and the videos do play on both my Galaxy S3 and the latest IOS. -
Android : mp4 file plays when downloaded but when choosing "Video" player gets "Cannot play video"
14 janvier 2014, par gviewI've converted the video to an mp4 with ffmpeg using the h264 codec and AAC, and used the baseline profile.
Videos are 540x360x250kbps
I then ran qt-faststart on the file to move the atoms into the right order.
I've stuck the file up on a wiki we use and created a link to it.
My test phone is a Samsung Galaxy S3.
When I browse to the page that has links to the mp4's on it, and I click on them, I get a popup window with 2 options : Internet and Video.
If I download the videos using the "Internet" option, I can play them on the phone without issue.
I've done other encodings with the main profile as well, and these also play fine. I thought that a powerful phone like the s3 would be able to handle the more advanced compression schemes available in h264, however I've also browsed the Android docs in regards to supported video formats, and it seems to state that only the "baseline" compression profile is supported.
Regardless, what doesn't work is trying to use the "Video" option which I assume tries to stream the video.
For the wiki in question, clicking on the link reveals that the content-type and content-length headers are being set :
Content-Length 6175996
Content-Type video/mp4;charset=UTF-8Clicking on the link with a browser invokes a player (Quicktime in most cases) that can play the mp4's.
Is there more to having the file HTTP streamable beyond making a link to it ? Why won't my Android 4 play these files ?
UPDATE :
I decided to make a quick HTML5 page using the video tag, and the videos do play on both my Galaxy S3 and the latest IOS. -
FFmpeg "movflags" > "faststart" causes av_write_trailer() to return -2
30 juin 2016, par williamtroupI’m setting up the format layout for the ideo as follows :
AVOutputFormat* outputFormat = ffmpeg.av_guess_format(null, "output.mp4", null);
AVCodec* videoCodec = ffmpeg.avcodec_find_encoder(outputFormat->video_codec);
AVFormatContext* formatContext = ffmpeg.avformat_alloc_context();
formatContext->oformat = outputFormat;
formatContext->video_codec_id = videoCodec->id;
ffmpeg.avformat_new_stream(formatContext, videoCodec);This is how I am setting up the Codec Context :
AVCodecContext* codecContext = ffmpeg.avcodec_alloc_context3(videoCodec);
codecContext->bit_rate = 400000;
codecContext->width = 1280;
codecContext->height = 720;
codecContext->gop_size = 12;
codecContext->max_b_frames = 1;
codecContext->pix_fmt = videoCodec->pix_fmts[0];
codecContext->codec_id = videoCodec->id;
codecContext->codec_type = videoCodec->type;
codecContext->time_base = new AVRational
{
num = 1,
den = 30
};I’m using the following code to setup the "movflags" > "faststart" option for the header of the video :
AVDictionary* options = null;
int result = ffmpeg.av_dict_set(&options, "movflags", "faststart", 0);
int writeHeaderResult = ffmpeg.avformat_write_header(formatContext, &options);The file is opened and the header is written as follows :
if ((formatContext->oformat->flags & ffmpeg.AVFMT_NOFILE) == 0)
{
int ioOptionResult = ffmpeg.avio_open(&formatContext->pb, "output.mp4", ffmpeg.AVIO_FLAG_WRITE);
}
int writeHeaderResult = ffmpeg.avformat_write_header(formatContext, &options);After this, I write each video frame as follows :
outputFrame->pts = frameIndex;
packet.flags |= ffmpeg.AV_PKT_FLAG_KEY;
packet.pts = frameIndex;
packet.dts = frameIndex;
int encodedFrame = 0;
int encodeVideoResult = ffmpeg.avcodec_encode_video2(codecContext, &packet, outputFrame, &encodedFrame);
if (encodedFrame != 0)
{
packet.pts = ffmpeg.av_rescale_q(packet.pts, codecContext->time_base, m_videoStream->time_base);
packet.dts = ffmpeg.av_rescale_q(packet.dts, codecContext->time_base, m_videoStream->time_base);
packet.stream_index = m_videoStream->index;
if (codecContext->coded_frame->key_frame > 0)
{
packet.flags |= ffmpeg.AV_PKT_FLAG_KEY;
}
int writeFrameResult = ffmpeg.av_interleaved_write_frame(formatContext, &packet);
}After that, I write the trailer :
int writeTrailerResult = ffmpeg.av_write_trailer(formatContext);
However, writeTrailerResult is always -2. I’m been looking into this problem for days and cannot figure out what the problem is.
The DLLs used for the AutoGen library are :
avcodec-56.dll
avdevice-56.dll
avfilter-5.dll
avformat-56.dll
avutil-54.dll
postproc-53.dll
swresample-1.dll
swscale-3.dll