protected void setUpEdges ( GrayS32 input , GrayS32 output ) { if ( connectRule == ConnectRule . EIGHT ) { setUpEdges8 ( input , edgesIn ) ; setUpEdges8 ( output , edgesOut ) ; edges [ 0 ] . set ( 1 , 0 ) ; edges [ 1 ] . set ( 1 , 1 ) ; edges [ 2 ] . set ( 0 , 1 ) ; edges [ 3 ] . set ( - 1 , 0 ) ; } else { setUpEdges4 ( input , edgesIn ) ; setUpEdges4 ( output , edgesOut ) ; edges [ 0 ] . set ( 1 , 0 ) ; edges [ 1 ] . set ( 0 , 1 ) ; } }
Declares lookup tables for neighbors