
Recherche avancée
Médias (39)
-
Stereo master soundtrack
17 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
ED-ME-5 1-DVD
11 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
1,000,000
27 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Demon Seed
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
The Four of Us are Dying
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Corona Radiata
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (71)
-
Des sites réalisés avec MediaSPIP
2 mai 2011, parCette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page. -
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 est la première version de MediaSPIP stable.
Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Comme pour la version précédente, 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 (...) -
Mise à disposition des fichiers
14 avril 2011, parPar défaut, lors de son initialisation, MediaSPIP ne permet pas aux visiteurs de télécharger les fichiers qu’ils soient originaux ou le résultat de leur transformation ou encodage. Il permet uniquement de les visualiser.
Cependant, il est possible et facile d’autoriser les visiteurs à avoir accès à ces documents et ce sous différentes formes.
Tout cela se passe dans la page de configuration du squelette. Il vous faut aller dans l’espace d’administration du canal, et choisir dans la navigation (...)
Sur d’autres sites (6895)
-
ffmpeg/libav - how to wirte video files with valid pts
9 mai 2017, par Kai RohmerI’m currently trying the write out a real time rendered video into a h264 encoded file. After reading a lot of (mostly) old samples and the few class references they call a documentation, I manager to write my video file and I’m also able to read it. Unfortunately, I need some metadata for each frame but I’m not having a constant frame rate. So my intension was to start with the presentation timestamps to "frametime" during recoding. But after all I tried I get no pts while reading the the file (pts stays -9223372036854775808). Before wring a lot of code, here are the basics steps I’m doing. I’m probably using the wrong container or I’m missing to set a flag and you will notice it right away.
// open a AVFormatContext
avformat_alloc_output_context2(&m_FormatContext, nullptr, "avi", m_FileName.c_str());
// open a stream
m_VideoStream = avformat_new_stream(m_FormatContext, avcodec_find_encoder(AV_CODEC_ID_H264));
// setup the codec context (including bitrate, frame size, ...)
m_CodecContext = m_VideoStream ->codec;
m_CodecContext->coder_type = FF_CODER_TYPE_VLC;
m_CodecContext->time_base = AVRational{1, 120}; // I expect 20-60 Hz
m_CodecContext->pix_fmt = AV_PIX_FMT_YUV420P;
m_CodecContext->color_range = AVCOL_RANGE_JPEG;
...
av_opt_set(m_CodecContext->priv_data, "preset", "ultrafast", 0);
av_opt_set(m_CodecContext->priv_data, "tune", "zerolatency,fastdecode", 0);
// set the same time_base to the stream
m_VideoStream ->time_base = m_CodecContext->time_base;
// open the codec
avcodec_open2(m_CodecContext, m_CodecContext->codec, nullptr);
// open file and write header
avio_open(&m_FormatContext->pb, m_FileName.c_str(), AVIO_FLAG_WRITE);
avformat_write_header(m_FormatContext, nullptr);
// then in a loop:
// render frame, convert RGBA to YUV frame, set the frames pts (timestamp is double application time in seconds)
frameToEncode.pts = int64_t(timestamp / av_q2d(m_VideoStream->time_base));
av_init_packet(m_EncodedPacket);
avcodec_encode_video2(m_CodecContext, m_EncodedPacket, frameToEncode, &got_output);
// check packet infos
//m_EncodedPacket->pts equals frameToEncode.pts
m_EncodedPacket->dts = AV_NOPTS_VALUE; // also tried incrementing numbers, or zero
m_EncodedPacket->stream_index = m_Stream->index;
m_EncodedPacket->duration = 0;
m_EncodedPacket->pos = -1;
m_EncodedPacket->flags = 0;
m_EncodedPacket->flags |= AV_PKT_FLAG_KEY; // read that somewhere
// write the packet to stream
av_interleaved_write_frame(m_FormatContext, m_EncodedPacket);
// after the loop
// I encode delayed frames and write the trailer
av_write_trailer(m_FormatContext);Thats pretty much it. I’m not getting what is missing. Since I have some meta data per frame I tried to add side data to each package but this data also disapered after reading from file. If decode the packets directly (instead of writing them to file, the data is there)
I’m quite sure the problem is with the encoding. I managed to decode the big buck bunny movie in which case i got valid pts values.
Thanks a lot for your help !
-
Web Analytics Reports : 10 Key Types and How to Use Them
29 janvier 2024, par Erin -
What is Funnel Analysis ? A Complete Guide for Quick Results
25 janvier 2024, par Erin