#
#
# -----------------------  checkmis ---------------------
# checks if all the frames of a sequence are present
# checkmis <name> <extension> <start> <end>
#
    if ( $#argv < 3 ) then
          echo ''
          echo '   ----------'
          echo '    This Cshell checks if all the frames of a'
          echo '    sequence are present.'
          echo '   ----------'
          echo ''
          echo '    Usage: <filename> <extension> <start> <end>'
          echo ''
          exit 0
          endif

     @ mis = 0
     @ count = $3
     
     while ( $count <= $4 )
     if ( -e $1.$count.$2 ) then
#           echo ---- $1.$count is present ----
     else
           @ mis = 1
           echo ---- $1.$count is missing ---- 
     endif 
     @ count += 1    
     end
     if ( $mis == 0 ) then
	echo
        echo ----  The sequence is complete  ----
     else
	echo
	echo --- The sequence is incomplete ---
     endif
     echo Done.
