// Image Sequence Viewer. // // March 1998 : // // Thomas Albech thomas@PROVIDEO.DK // Soren Birk Jacobsen kurgan@ns-media.dk // // http://www.awug.dk/ // Alias|Wavefront UserGroup Denmark // // Notes: // -The viewer defaults to the current image directory // -It tries to identify zero padding by checking // the first character in the extension // // // Program starts here. // global proc viewSequence() { string $workspace = `workspace -q -fn`; // get the project's image directory // string $fileRules[] = `workspace -q -rt`; int $i; string $imageDir = ""; // default is current dir for ( $i = 0; $i < size($fileRules); $i += 2 ) { if ( $fileRules[$i] == "images" ) { $imageDir = $fileRules[$i+1]; break; } } $imageDir = $workspace + $imageDir + "/*"; // Please verify that fcheck is living here on your harddrive. // string $fcheck_location ="/usr/aw/COM/bin/fcheck -f "; string $Cmd; string $Rtn; string $Padded = " -p "; string $Rtn = `fileDialog -dm $imageDir`; if ($Rtn != "Cancel") { $imageDir = $Rtn; for ( $i = size($Rtn); $i > 0 ; $i -= 1 ) { if ( "." == `substring $Rtn $i $i` ) { $imageDir = `substring $Rtn 1 $i`; break; } } $i++; if ( "0" != `substring $Rtn $i $i`) { $Padded = " "; } if ($Rtn != "") { $Cmd = $fcheck_location + $Padded + $imageDir; system $Cmd; } } } // Program ends here //