private void CheckBilevelImage ( IfdTags metadata , int n ) { // Compression long comp = metadata . get ( TiffTags . getTagId ( "Compression" ) ) . getFirstNumericValue ( ) ; // if (comp != 1 && comp != 2 && comp != 32773) if ( comp < 1 ) validation . addError ( "Invalid Compression" , "IFD" + n , comp ) ; }
Check Bilevel Image .