
Recherche avancée
Autres articles (33)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
-
Ecrire une actualité
21 juin 2013, parPrésentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
Vous pouvez personnaliser le formulaire de création d’une actualité.
Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)
Sur d’autres sites (8265)
-
Turn image sequence into video with transparency
5 juillet 2020, par Cody HatchI've got what seems like it should be a really simple problem, but it's proving much harder than I expected. Here's the issue :



I've got a fairly large image sequence consisting of numbered frames (output from Maya, for what its worth). The images are currently in Targa (.tga) format, but I could convert them to PNGs or other arbitrary format if that matters. The important thing is, they've got an alpha channel.



What I want to do is programatically turn them into a video clip. The format doesn't really matter, but it needs to be lossless and have an alpha channel. Uncompressed video in a Quicktime container would probably be ideal.



My initial thought was ffmpeg, but after wasting most of a day on it it seems it's got no support at all for alpha channels. Either I'm missing something, or the underlying libavcodec just doesn't do it.



So, what's the right way here ? A command line tool like ffmpeg would be nice, but any solution that runs on Windows and could be called from a script would be fine.



Note : Having an alpha chanel in your video isn't actually all that uncommon, and it's really useful if you want to composite it on top of another video clip or a still image. As far as I know uncompressed video, the Quicktime Animation codec, and the Sorenson Video 3 codec all support tranparency, and I've heard H.264 does as well. All we're really talking about is 32-bit color depth, and that's pretty widely supported ; both Quicktime .mov files and Windowss .avi files can handle it, and probably a lot more too.



Quicktime Pro is more than happy to turn an image sequence into a 32-bit .mov file. Hit export, change color depth to "Millions of Colors+", select the Animation codec, crank the quality up to 100, and there you are - losslessly compressed video, with an alpha chanel, and it'll play back almost anywhere since the codec has been part of Quicktime since version 1.0. The problem is, Quicktime Pro doesn't have any sort of command-line interface (at least on Windows). ffmpeg supports encoding using the Quicktime Animation codec (which it calls qtrle), but it only supports a bit-depth of 24 bits.



The issue isn't finding a video format that supports an alpha channel. Quicktime Animation would be ideal, but even uncompressed video should work. The problem is finding a tool that supports it.


-
Can't link FFMPEG dynamically to VS 2019 project
10 février 2021, par Maya SelaI downloaded the source code of FFMPEG 3.4.8 and built with MSVC as such :

After unzipping, open x86_x64 Cross Tools Command Prompt for VS 2019 and runmsys2_shell.cmd
. From there, run

./configure --toolchain=msvc --arch=x86_64 --enable-yasm --enable-asm --enable-shared --disable-static

and
make



I then created a new project in VS 2019.

In Properties > C/C++ > General > Additional Include Directories :

(Where all the headers are)

E:\ffmpeg-3.4.8\libavutil
E:\ffmpeg-3.4.8\libavcodec
E:\ffmpeg-3.4.8\libavdevice
E:\ffmpeg-3.4.8\libavfilter
E:\ffmpeg-3.4.8\libavresample
E:\ffmpeg-3.4.8\libpostproc
E:\ffmpeg-3.4.8\libswscale
E:\ffmpeg-3.4.8\libswresample
E:\ffmpeg-3.4.8\libavformat



In Properties > Linker > General > Additional Library Directories :

(Where the .lib files are)

E:\ffmpeg-3.4.8\libavutil
E:\ffmpeg-3.4.8\libavcodec
E:\ffmpeg-3.4.8\libavdevice
E:\ffmpeg-3.4.8\libavfilter
E:\ffmpeg-3.4.8\libavresample
E:\ffmpeg-3.4.8\libpostproc
E:\ffmpeg-3.4.8\libswscale
E:\ffmpeg-3.4.8\libswresample
E:\ffmpeg-3.4.8\libavformat



In Properties > Linker > Input > Additional Dependencies :


avcodec.lib
avdevice.lib
avfilter.lib
avformat.lib
swresample.lib
swscale.lib



For good measure, I copied the .dll files of each library to the Release folder of the project. There is one source file I am trying to build and run :



extern "C" {
#include <libavformat></libavformat>avformat.h>
}

int main() {
 AVFormatContext* pFormatContext = avformat_alloc_context();
}



The result is as follows :


1>------ Build started: Project: FFMPEG_example, Configuration: Release x64 ------
1>Source.cpp
1>Source.obj : error LNK2001: unresolved external symbol avformat_alloc_context
1>C:\Users\maya.s\source\repos\FFMPEG_example\x64\Release\FFMPEG_example.exe : fatal error LNK1120: 1 unresolved externals
1>Done building project "FFMPEG_example.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========



Does anyone have an idea ?

Thanks !

-
The Mystery of the No such file or directory exception
22 avril 2022, par JohnWickNo idea what's going on here. Set a breakpoint after the for of loop in the following function. temp/concat.txt exists but the following exception is thrown :




Uncaught Error Error : ffmpeg exited with code 1 : temp/concat.txt : No
such file or directory




Outputting stderr gives a bit more info :




[concat @ 000001e2e30124c0] Impossible to open
'temp/concat.txt#voiceover #funny #fall #lol.mp4' index.js:19
temp/concat.txt : No such file or directory




And here is the contents of concat.txt, standard ffmpeg concat demuxer format :


file '#voiceover #funny #fall #lol.mp4'
file 'part 2 repost 🙄 #fyp #funny @jordond262 @princemoonjq add my snap heroicdw333.mp4'
file 'This is my hair wet wet WOAHHH #GrowUpWithMe #fyp #foryoupage #love #funny #puppy #goldenretriever #cute #dog #wetwet.mp4'
file 'POV calling your friends when your 90#FootlongShuffle #GhostMode #funny #grandma #fyp #halloween #collegegotmelike #tiktok #foryoupage.mp4'
file 'Sam Ki Singing Kaisi Lgi 😂😜 insta-samayranarula #foryou #trending #lockdown #queen_samayra #tiktokindia #funny #gharbaithoindia 🏠 #comedyindia.mp4'
file 'Reply to @juswa646 #fyp#funny #relatable.mp4'
file 'RaNdOm ViDeOs! #fy #fypシ #viral #meme #funny #xyzbca #funnyvideos #randomvideo.mp4'
file 'Reply to @bratzdoll.maya what should I do next 🙄 #fyp #foryoupage #leethe4th #memes #tall #funny #lol.mp4'
file 'Part 2 #fyp #foryou #viral #foryoupageofficiall #funny #trending.mp4'
file 'Lmfao 😂 (via @danibreezy01) #lmao #lmfao #funny #cousins #family #fyp #foryou #foryoupage.mp4'
file 'When you are a clumsy kitty #trend #joke #Khaleesi #funny #kittensoftiktok #foryou #fyp #foryoupage #cute #catsoftiktok.mp4'
file 'Tag That Friend That Always Be Falling Asleep 😂 #foryou #funny #fail #nap #sleep #pennsylvania #SHEINcares #viral #trending #meme #memes #foryoupage.mp4'
file '#funny #funnyvideos #girlfriend #crzy #Birdshit.mp4'
file 'He forgot he was a dog. #dog #fyp #talkingdog #cute #pet #funny.mp4'
file 'Bad Day #part1 #badday #falling #funny #memes #viral #jokes #comedy #trending #fyp #foryou #share #likes #us #uk #xyzbca #epic #pourtoi #fail #wee.mp4'
file 'I think he got offended ( #catsoftiktok #fyp #funny #catlover #MyJob #yellow #foryoupage.mp4'
file 'They took OFF today 🐶🤠🐶 #joshbutlertv #roxyandremi #funny #comedy #dogs #viral #memes.mp4'
file 'Had to make sure momma was there #funny #fyp #raccoons #love #bff #foryoupage #ThisorThatSBLV.mp4'
file 'That\'s not how you get out... #mysterymakers #escaperoom #foryou #fyp #crazystory #friends #funny #crazy #teammate.mp4'



The function throwing the exception.


async function makeCompilation(paths, outPath) {
 for (const filePath of paths) {
 await fs.appendFile(
 "temp/concat.txt",
 `file '${path.basename(filePath).replace("'", "\\'")}'${os.EOL}`
 );
 }
 return new Promise((resolve, reject) => {
 ffmpeg("temp/concat.txt")
 .inputOptions(["-f concat", "-safe 0"])
 .outputOption("-c copy")
 .on("stderr", (line) => console.log(line))
 .on("end", async () => {
 await fs.rm("temp/concat.txt");
 resolve();
 })
 .save(outPath);
 });
}