
Recherche avancée
Médias (91)
-
Spoon - Revenge !
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
My Morning Jacket - One Big Holiday
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Zap Mama - Wadidyusay ?
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
David Byrne - My Fair Lady
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Beastie Boys - Now Get Busy
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Granite de l’Aber Ildut
9 septembre 2011, par
Mis à jour : Septembre 2011
Langue : français
Type : Texte
Autres articles (111)
-
Script d’installation automatique de MediaSPIP
25 avril 2011, parAfin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
La documentation de l’utilisation du script d’installation (...) -
Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs
12 avril 2011, parLa manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras. -
Librairies et binaires spécifiques au traitement vidéo et sonore
31 janvier 2010, parLes logiciels et librairies suivantes sont utilisées par SPIPmotion d’une manière ou d’une autre.
Binaires obligatoires FFMpeg : encodeur principal, permet de transcoder presque tous les types de fichiers vidéo et sonores dans les formats lisibles sur Internet. CF ce tutoriel pour son installation ; Oggz-tools : outils d’inspection de fichiers ogg ; Mediainfo : récupération d’informations depuis la plupart des formats vidéos et sonores ;
Binaires complémentaires et facultatifs flvtool2 : (...)
Sur d’autres sites (9460)
-
Encoding video for real time streaming
15 septembre 2019, par lilrooMiguel Grinberg’s article video streaming with flask, covers sending multiple JPG formatted images to a client through a multipart response to stream video to the browser.
After doing some reading, I quickly realized that MJPEG is not a real video format, JPEGs are not optimized for video streaming and MJPEG cannot be streamed to a HTML5 video element.
for my application (a screen sharing application written in python), I need to be able to encode and stream relatively smooth video (smoother than MJPEG anyway) in semi-realtime to the browser.
I think what I need to do is encode a video stream using a tool like FFmpeg and then send chunks of that output to a browser using a multipart response - however it doesn’t look like there is a way to get FFmpeg (using python bindings) to write to an in-memory buffer.
Is ffmpeg up to this task ?
I appreciate that this question may sound nieve, but I would be thankful for being pointed in the right direction.
-
hls playlist where the #EXTINF tag doesnt match actual segment duration ? [closed]
8 janvier, par tamirg"The EXTINF tag specifies the duration of a Media Segment."


But what should happen if the actual file duration does not match that tag ?


I tried to edit the m3u8 file of my playlist and change the EXTINF tags so it will be smaller than the actual file duration, and also sometimes changed it so it will be bigger than the duration. In both cases the result stayed the same and simply the actual segment duration was played, regardless of the EXTINF tag.


So what is the actual need of this tag ? seems that simply the file is being played.


-
JavaFXFrameConverter consuming insane amounts of memory
17 juillet 2023, par iexavThe JavaFXFrameConverter (from the wrapper of the ffmpeg C library in java) convert() method is consuming an outrageous amount of memory. To elaborate a bit more, it does not happen usually. If I just make an instance of the class in my main method, grab a frame via FFMpegFrameGrabber and give it to the convert() method the memory usage is pretty much none. However, when I attempt to do pretty much the exact same in a class I made using an ExecutorService my memory usage jumps up to 8 gigabytes when convert is called. The converter and executor service are declared as member variables of my class. Namely :


final JavaFXFrameConverter converter = new JavaFXFrameConverter();
 private ExecutorService videoExecutor;



(the videoExecutor is instantiated in the constructor of the class :


videoExecutor=Executors.newSingleThreadExecutor();



Now, the method I am using for processing of the video frames is this :


private void processVideo(){
 videoExecutor.submit(() -> {
 processingVideo.set(true);
 try{

 while(processingVideo.get() && (videoQueue.peek())!=null){

 final Frame cloneFrame = videoQueue.poll();
 final Image image = converter.convert(cloneFrame);
 final long timeStampDeltaMicros = cloneFrame.timestamp - timer.elapsedMicros();
 if (timeStampDeltaMicros > 0) {
 final long delayMillis = timeStampDeltaMicros / 1000L;
 try {
 Thread.sleep(delayMillis);
 } catch (InterruptedException e) {
 Thread.currentThread().interrupt();
 }
 }

 cloneFrame.close();
 System.out.println("submitted image");
 videoListener.submitData(image);
 }
 }catch (NullPointerException e){
 NullPointerException ex = new NullPointerException("Error while processing video frames.");
 videoListener.notifyFailure(ex);
 }

 processingVideo.set(false);

 });
 }



I sent the whole method for a bit more context but realistically speaking the only part that is of real significance is the converter.conver(cloneFrame) ; I used the intelliJ profiler and also the debugger and this is exactly where the problem occurs. When convert is called after doing some stuff it eventually ends up in this method :


public <t extends="extends" buffer="buffer"> void getPixels(int x, int y, int w, int h, WritablePixelFormat<t> pixelformat, T buffer, int scanlineStride) {
 int fss = this.frame.imageStride;
 if (this.frame.imageChannels != 3) {
 throw new UnsupportedOperationException("We only support frames with imageChannels = 3 (BGR)");
 } else if (!(buffer instanceof ByteBuffer)) {
 throw new UnsupportedOperationException("We only support bytebuffers at the moment");
 } else {
 ByteBuffer bb = (ByteBuffer)buffer;
 ByteBuffer b = (ByteBuffer)this.frame.image[0];

 for(int i = y; i < y + h; ++i) {
 for(int j = x; j < x + w; ++j) {
 int base = 3 * j;
 bb.put(b.get(fss * i + base));
 bb.put(b.get(fss * i + base + 1));
 bb.put(b.get(fss * i + base + 2));
 bb.put((byte)-1);
 }
 }

 }
 }
</t></t>


Now, everything up until this point is fine. The memory usage is at around 130mb but alas, when execution enters in these 2 for loops that's where the downright stupid memory usage occurs. Every single one of these bb.put calls is netting me around 3 more megabytes of memory usage. By the end of it you can probably guess what happens. Also all of these memory allocations do happen on the stack so I'm assuming that's why my memory usage stops at around 8-8.5 gigabytes otherwise the program would crash (that has also happened, out of memory exception thrown, but it doesn't usually happen, it kind of just lingers at those 8 gigabytes.) Frankly speaking I'm at a bit of a loss. I haven't seen virtually anyone anywhere mention this ever and I ran out of things to try to fix this so I am making this post.


By the way another thing I tried is make the ExecutorService in the same class as the main method and when I submitted there I also didn't have these memory problems.