Skip to content

Instantly share code, notes, and snippets.

@FaySmash
FaySmash / Create-GridVideo.ps1
Last active December 21, 2025 19:04
A PowerShell script which can create 1 second video collage aka animated mosiac, a video file made out of a lot of smaller video files. It takes a folder of source videos and a CSV like text file to position all the videos in a grid. Made to use in conjunction with my fork of image-collage-maker which creates such a CSV file. Code mostly generat…
<#================================================================================================================
Create‑GridVideo.ps1
--------------------
• Takes a text file that lists image‑files + X/Y coordinates.
• Swaps the .jpg extension to .mp4 (the video must already exist next to the image).
• Groups the videos by X‑coordinate → one *column* video per X value.
• Each column video is a black canvas (width = final‑width / columns, height = final‑height)
onto which every clip of that column is over‑laid at its Y‑position.
• All column videos are exactly the same length as the source clips (1 s in the example).
• Afterwards the column videos are stacked side‑by‑side (hstack) to produce the final grid.