
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 (63)
-
Le profil des utilisateurs
12 avril 2011, parChaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...) -
Configurer la prise en compte des langues
15 novembre 2010, parAccéder à la configuration et ajouter des langues prises en compte
Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...) -
Sélection de projets utilisant MediaSPIP
29 avril 2011, parLes exemples cités ci-dessous sont des éléments représentatifs d’usages spécifiques de MediaSPIP pour certains projets.
Vous pensez avoir un site "remarquable" réalisé avec MediaSPIP ? Faites le nous savoir ici.
Ferme MediaSPIP @ Infini
L’Association Infini développe des activités d’accueil, de point d’accès internet, de formation, de conduite de projets innovants dans le domaine des Technologies de l’Information et de la Communication, et l’hébergement de sites. Elle joue en la matière un rôle unique (...)
Sur d’autres sites (5846)
-
Continously read file in Ruby and save into pipe
7 juillet 2016, par stiller_leserI am trying to continously read a file and save the output into a
IO.pipe
. The motivation being that ffmpeg which has been spawned before and given the r-end of the pipe as STDIN will then convert the video.
This is what I have so far :r,w = IO.pipe
ffmpeg_args = ' -i pipe:0 "test.mp4"'
pid = Process.spawn('ffmpeg'+ffmpeg_args, {STDIN => r, STDERR => STDOUT})
Process.detach pid
File.open(@options['filename'], 'rb') do |file|
while line = file.gets
w.write line.read
end
endI had success with declaring the input file directly as STDIN for the process, but this lead to an early termination of ffmpeg since it had reached the end of the file. With the code above ffmpeg complains about invalid data.
Is there any way this could be achieved ?
-
Read the audio file while it's being written in NodeJS
21 novembre 2017, par user3170450I am capturing audio through alsa using ffmpeg and writing it to a wav file. But as it’s being written I need to send the captured audio to some 3rd party. I have tried few methods including node-growing-file but not able to succeed.
Is there a way I can read the file as a stream as long as it’s being written and process it as required.
-
Can I know which byte range to read from a remote mp4 file for FFMpeg to decode a keyframe ?
12 octobre 2023, par db9117I need to decode a of keyframe of a video file (mp4, h264 encoded). I know the timestamp of the keyframe I want to extract/decode. I want to minimize amount of data being read in memory. For this, I need to know beforehand exactly the minimal byte range I would require that encompasses this keyframe. How do I know what is the minimal byte range in the whole mp4 byte stream I need to read in order to be able to decode the keyframe ?


I currently find the appropriate keyframe in the
index_entries
contained in the header. I get its byte position (pos
attribute) and timestamp (timestamp
attribute). I calculate the range as follows :

startBytes
: minimum of :

- 

- the
pos
of the keyframe - the
pos
of the nearest index entry in the audio stream happening at or before the keyframe's timestamp.






This way when it's decoding the frame, if it also needs the audio content for demuxing, it would have it.


endBytes
: maximum of :

- 

- the
pos
of the next frame in the video stream's index, after the keyframe - the
pos
of the next frame in the audio stream's index after the timestamp of the wished keyframe.






This way I know that I have everything up until the next frame in the index, which theoretically should be enough to decode the keyframe only.


I then read the appropriate byte range.


When I try to decode the frame, I run in a loop until I succeed :


- 

avcodec_read_frame
avcodec_send_packet
avcodec_receive_frame








I ignore
AVERROR(EAGAIN)
errors.

avcodec_receive_frame
fails multiple times with errorAVERROR(EAGAIN)
which I ignore, until it fails saying that the memory it wants to read isn't available (wants to read afterendBytes
). I explicitly tell it to fail if it wants to read more than it has already read.

Note : for other keyframes at other positions in other videos, it sometimes succeeds (probably because the range is big enough by chance), but it fails more often than not.


My question is : Why is the end of the range not enough to be able to decode only the one keyframe ? Is there any way to more precisely calculate the exact range in bytes I would need in order to decode a particular keyframe ?


- the