From: Charles McGarvey Date: Wed, 1 Dec 2021 19:00:57 +0000 (-0700) Subject: make animate script work for modern luas X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;ds=sidebyside;p=chaz%2Frasterize make animate script work for modern luas --- diff --git a/animate.lua b/animate.lua index 616c717..ae3ff24 100755 --- a/animate.lua +++ b/animate.lua @@ -109,7 +109,7 @@ X i = coroutine.yield() out:close() if 1 < supersample and - run("convert %s -scale %dx%d %s", filename, size.w, size.h, filename) ~= 0 then + not run("convert %s -scale %dx%d %s", filename, size.w, size.h, filename) then print() os.exit(1) end @@ -140,7 +140,7 @@ for render,frame in renderings() do render(frame) end print() -if run("ffmpeg -i frames/anim%%04d.bmp %s -y -an scene.avi", ffmpeg_opts) == 0 then +if run("ffmpeg -i frames/anim%%04d.bmp %s -y -an scene.avi", ffmpeg_opts) then print("Animation written to scene.avi.") else print("The animation could not be created. Is ffmpeg installed?")