Differences

This shows you the differences between two versions of the page.

Link to this comparison view

graphic:element:image_sequence [2017/10/14 15:59] (current)
ying created
Line 1: Line 1:
 +====== Image Sequence in general ======
 +
 +When working with animation and visual effects from 3D, Pro works with image sequence instead of video files.
 +
 +Because, ​
 +  * no compression for each frame
 +  * easy to edit each frame
 +
 +====== View image sequence ======
 +
 +  * (win,​mac,​linux) [[http://​djv.sourceforge.net/​|Djv]] is one of best free cross-platform image sequence viewer with highly configurable setting and view control, and it do give simple converting tools. ​
 +    * [Djv is one of the few free sequence viewer that I found most similar to the in-house sequence viewer used in Real Production Studios] both command line & UI mode
 +
 +a image sequence viewer should have features like
 +  * iff, sgi, exr and etc file format support
 +  * exr render layer display support
 +  * rgbaz channel display
 +  * a/b channel comparison
 +  * exposure adjustment
 +  * command line mode support
 +  * simple clean configurable UI
 +  * shortcut support
 +====== Convert image sequence ======
 +
 +  * all composting tool can convert "image sequence to video" and "video to image sequence"​
 +  * (win,​mac)[free] [[http://​www.squared5.com/​|StreamClip]] can handle most of file formats for convertion
 +  * (win,​mac,​linux) djv_convert - it comes with [[http://​djv.sourceforge.net/​|Djv]]
 +
 +===== general djv command =====
 +
 +<​code>​
 +# make sure you added the djv bin directory into PATH variable
 +# Convert an image:
 +djv_convert input.sgi output.tga
 +
 +# Convert sequence:
 +# (Note that only the first frame of the output is specified)
 +# (the conversion will count up from there)
 +djv_convert input.0001-0500.sgi output.0001.tga
 +
 +# Convert seq to mov (only 32bit djv can on window since qt is 32bit)
 +djv_convert input.0001-0100.iff output.mov
 +
 +# Convert mov to seq
 +djv_convert input.mov output.0001.tga
 +
 +# Convert pixel type
 +djv_convert input.sgi output.sgi -pixel rgb u16
 +
 +# Scale an image by half:
 +djv_convert input.tga output.tga -scale 0.5 0.5
 +
 +# Resize an image:
 +djv_convert input.tga output.tga -resize 2048 1556
 +
 +# for more info, just type djv_convert
 +</​code>​
 +
 +===== windows convert batch script =====
 +<code dos tom.bat>​REM usage - tom seqFile.0001.iff;​ then this script named as tom will handle job
 +@echo off
 +REM pass in the first file name
 +set fullname=%~1
 +set foldername=%~dp1
 +set filename=%~nx1
 +REM get seq directory and first file name
 +cd /D "​%foldername%"​
 +for /f "​tokens=1-3 delims=."​ %%A in ("​%filename%"​) do (
 +  set seqname=%%A
 +  set seqstart=%%B
 +  set seqext=%%C
 +  )
 +set seqpattern=%seqname%.*.%seqext%
 +REM now we have the sequence naming pattern name.#.ext
 +for /f "​tokens=1-3 delims=."​ %%A in ('dir /b "​%seqpattern%"'​) ​ do set seqend=%%B
 +REM now we have the sequence end number
 +set input=%seqname%.%seqstart%-%seqend%.%seqext%
 +set output=..\%seqname%.mov
 +"​c:​\App\djv-0.8.2_winxp-x86\bin\djv_convert.exe"​ "​%input%"​ "​%output%"​
 +REM i alias the djv_convert.exe to tom32 and tom64
 +REM as this batch will be alias as tom (to movie)
 +cd ..
 +pause
 +</​code>​
 +reference used:
 +  * http://​weblogs.asp.net/​jgalloway/​archive/​2006/​11/​20/​top-10-dos-batch-tips-yes-dos-batch.aspx
 +  * http://​www.computerhope.com/​forhlp.htm
 +  * http://​www.sprint.net.au/​~terbut/​usefulbox/​msdoscmds.htm
 +  * http://​weblogs.sqlteam.com/​robv/​articles/​4102.aspx
 +===== bash script version for mac and linux =====
 +<code bash tom.sh>
 +# to be added
 +</​code>​
 +
 +===== NConvert =====
 +
 +Linux default has "​convert"​ cmd installed, but only support common file format.
 +
 +Available to Win/​Mac/​Linux in commandline binary format.
 +  * download: http://​www.xnview.com/​en/​download_nc.html
 +
 +===== ImageMagick =====
 +
 +Another crossplatform image processing tool.
 +  * download: http://​www.imagemagick.org/​script/​convert.php
 +====== Rename image sequence ======
 +
 +General, (win) dos command or dos batch function, (mac,linux) bash shell script, will perfectly do the job if you know them well.
 +
 +There are also some GUI apps that helps renaming sequence images.
 +  * [[http://​www.creativecrash.com/​downloads/​applications/​rename-pad/​c/​sequence-911|Sequence 911]] (win)