Crop 10000x10000 image sequence to video
I have an unusually large PNG image sequence (about 10000x10000, each file is about 50MB). I want to crop a region of this (about 3000x3000) and encode it into a video. The format is not important, as long as it has decent quality and well compressed, and obviously supports that resolution.
I tried After Effect's demo, but it doesn't seem to handle well that kind of resolution on my computer. I'm open to any software, better if free. Command line is fine.
41 Answer
You can do batch cropping/editing images with ImageMagick. It is included in almost every Linux distro and has tons of options for you. It has versions for other platforms, too. Below is some examples that may help you
To simply resize all images to 3000x3000 in-place you can use
mogrify -resize 3000x3000 *.pngThis will overwrite your files. If you want to write outputs to another folder use
mogrify -resize 3000x3000 *.png -path /path/to/output/folderIf mogrify is too slow or takes too much memory you could use this way
for f in *.png
do convert $f'[3000x3000]' $outputdir/$f.resized.png
doneIf you also want to convert them to another format like jpg for reducing stress on the video encoder later:
mogrify -resize 3000x3000 -format jpg *.pngIf you just want to crop a 3000x3000 region from offset 1000x2000 then use this
mogrify -crop 3000x3000+1000+2000 *.pngAfter all just encode the images with ffmpeg