
Recherche avancée
Autres articles (11)
-
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Supporting all media types
13 avril 2011, parUnlike 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 (...)
-
Participer à sa traduction
10 avril 2011Vous pouvez nous aider à améliorer les locutions utilisées dans le logiciel ou à traduire celui-ci dans n’importe qu’elle nouvelle langue permettant sa diffusion à de nouvelles communautés linguistiques.
Pour ce faire, on utilise l’interface de traduction de SPIP où l’ensemble des modules de langue de MediaSPIP sont à disposition. ll vous suffit de vous inscrire sur la liste de discussion des traducteurs pour demander plus d’informations.
Actuellement MediaSPIP n’est disponible qu’en français et (...)
Sur d’autres sites (2949)
-
Remove Static Pixels from a Video to Mimic a Green Screen Effect [closed]
2 août 2021, par nKrkanI have a video that's 50 seconds in length, resolution of 480x480 and 16 frames per second.


There is a person talking in it, with the background being static I thought if there's a way

to remove those static pixels (background) and just extract the moving pixels (foreground)

and possibly mimic a green screen effect ?

I was thinking on writing a picture-by-picture comparison tool to do such thing but I don't

believe I'm up to the task, or maybe It's laziness.

And now I know, some of you will point out that the video has compression artifacts and that

might cause some problems but It doesn't have to be Studio quality stuff.

I tried the ffmpeg command from this question : Remove random background from video using ffmpeg or Python

And it does mask the person, but... I couldn't quite get it to work, apparently putting the

reference image in the input makes that image burned into the video, thus having no way to

remove it, but it did mask the background as black and the person as greenish, so still not a

viable way to do it.

Have also tried some Python projects I've found on the GitHub but none of them worked as

I expected.

So, what I thought to do is simply compare the first and the second frame of the video, check

all the pixels by comparing them with the two sources, and change those that stay within a

certain range of the initial pixel value.

I should point out I'm not very knowledgeable with mathematics and the majority of the

methods used in these type of things, but perhaps someone could point me to an interesting

source to read and learn, or by providing an alternative to the methods aforementioned above.

-
"Automatic" switchable graphics on desktop, is there a way to disable them ?
14 août 2021, par Hab-Land0Recently, I've updated my graphic drivers for a new system I built, a mix between an amd apu and an nvidia quadro. But I stumbled upon a rare problem, every time I tried to use OpenCL acceleration on ffmpeg for libx264 encoding, ffmpeg notifies me with the next line :


[libx264 @ 0000028149222780] OpenCL acceleration disabled, switchable graphics detected



When searching this line on ffmpeg's code, apparently occurs when the "main OpenCL driver" (if you can call it that) is redirected in such a way that tries to use both devices (Code).


My obvious next step was to search everything I could around this "switchable graphics", but almost all the tutorials on websites told me that I should search around the driver's settings, but literally either Radeon Software or Nvidia's control panel don't display any option about it (It is worth to say that almost all of the tutorials refer to laptops with dedicated graphics and were very outdated).


Another way I use OpenCL is for vapoursynth's filters, such as KNLMeansCL. And, when I make use of this filter, task manager detects that both AMD's APU and Nvidia's gpu are being used simultaneously (I guess that's how the switchable graphics actually works, and partially complementing why x264 OpenCL doesn't work).


My main complain with this is that I attempt to use AMD as a display driver and let Nvidia do the hard work, and I actually was able to do that before updating my drivers. And, talking about the "updates" more in-depth, I updated nvidia's from "462.59" to "471.11" and, unfortunately, I can't remember what versions were my AMD drivers.


Edit : the only way I can make full use of NVIDIA's card is by using it as my main display, but that also apparently disables AMD's igpu, I am not sure if its even able to be used on small tasks (like those that were previously mentioned)


-
How correctly show video with transparency in Qt with OpenCV + FFMpeg
11 avril 2022, par TheEnigmistI'm trying to show a video with transparency in a Qt6 application using OpenCV + FFMPEG.
Actually those are tool versions :


- 

- Win 11
- Qt 6.3.0
- OpenCV 4.5.5 (built with CMake)
- FFMPEG 2022-04-03-git-1291568c98-full_build-www.gyan.dev










I've used a base .mov video with transparency as test (link provided below).
First of all I've converted .mov video to .webm video (VP9) and I see in output text that alpha channel remains




ffmpeg -i '.\Retro Bars.mov' -c:v libvpx-vp9 -crf 30 -b:v 0 output.webm




Input #0, mov,mp4,m4a,3gp,3g2,mj2,
 ...
 Stream #0:0[0x1](eng): Video: qtrle (rle / 0x20656C72), argb(progressive),
 ...

Output #0, webm, 
 ...
 Stream #0:0(eng): Video: vp9, yuva420p(tv, progressive),
 ...



But when I show info of output file with ffmpeg it loses alpha channel :




ffmpeg -i .\output.webm




Input #0, matroska,webm,
 ...
 Stream #0:0(eng): Video: vp9 (Profile 0), yuv420p(tv, progressive),
 ...



If I open output.webm with OBS it is shown correctly without a background, as shown in picture :



If I try to open it with OpenCV + FFMPEG it shows a black background under bars, as shown in picture :



This is how I load video in Qt :


cv::VideoCapture capture;
capture.open(filename, cv::CAP_FFMPEG);
capture.set(cv::CAP_PROP_CONVERT_RGB, false); // try forcing load alpha channel
... //in a thread
while (capture.read(frame)) {
 qDebug() << "c" << frame.channels() << "t" << frame.type() << "d" << frame.depth(); // output: c 3 t 16 d 0
 cv::cvtColor(frame, frame, cv::COLOR_BGR2RGBA); //useless since no alpha channel is detected
 img = QImage(frame.data, frame.cols, frame.rows, QImage::Format_RGBA8888);
 emit processedImage(img); // to show image in a QLabel with QPixmap::fromImage(img)
}



I think the problem is when I load the video with OpenCV, it doens't detect alpha channel, since I can load correctly in other player (obs, html5, etc.)


What I'm wrong with all process to show this video in Qt with transparency ?


EDIT : Added dropbox link with test video + ffmpeg outputs :
sample items