question: protected void doSubLine ( byte [ ] curLine ) { int sub = ( int ) Math . ceil ( ( getBitsPerComponent ( ) * getColors ( ) ) / 8.0 ) ; for ( int i = 0 ; i < curLine . length ; i ++ ) { int prevIdx = i - sub ; if ( prevIdx >= 0 ) { curLine [ i ] += curLine [ prevIdx ] ; } } }
target:  Return the value of the Sub algorithm on the line (compare bytes to the previous byte of the same color on this line).