blobs
Class Searcher

java.lang.Object
  extended byblobs.Searcher
Direct Known Subclasses:
BlobFinder

public class Searcher
extends java.lang.Object


Constructor Summary
Searcher()
           
 
Method Summary
 void radiateFromSeed(Growable _blob, java.awt.Point _seed, int _increment, java.awt.Shape _limitedSearchArea, int _allowableGap, int _numAlternateRoutes)
          Routine radiates out in 8 directions from a given seed point.
 void scanAll(Growable _blob, java.awt.Shape _limitedSearchArea)
           
 void scanOutFromSeed(Growable _blob, java.awt.Point _seed, int _increment, java.awt.Shape _limitedSearchArea, int _allowableHGap, int _allowableVGap)
          Routine scans out from the center first to the left and up then to the right and down and finally to the left and up.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Searcher

public Searcher()
Method Detail

radiateFromSeed

public void radiateFromSeed(Growable _blob,
                            java.awt.Point _seed,
                            int _increment,
                            java.awt.Shape _limitedSearchArea,
                            int _allowableGap,
                            int _numAlternateRoutes)
Routine radiates out in 8 directions from a given seed point. At various key points in the search it shouts out function calls like newSeed, newPoint, newBorderPoint, finishedSeed etc.

Parameters:
_seed -
_increment - you can jump over pixels
_limitedSearchArea - specify a sub section of the area to search
_allowableGap - allow for gaps in the radiating out
_numAlternateRoutes - how many detours (max 3) around bad pixels that you find

scanOutFromSeed

public void scanOutFromSeed(Growable _blob,
                            java.awt.Point _seed,
                            int _increment,
                            java.awt.Shape _limitedSearchArea,
                            int _allowableHGap,
                            int _allowableVGap)
Routine scans out from the center first to the left and up then to the right and down and finally to the left and up. At various key points in the search it shouts out function calls like newSeed, newPoint, newBorderPoint, finishedSeed etc.

Parameters:
_seed -
_increment - you don't have to check every point
_limitedSearchArea - you can specify a limited area to searh
_allowableHGap - you can forgive a few horizontal pixel. don't give up searching outward until you have missed this many
_allowableVGap - you can forgive a few vertical pixel. don't give up searching up and down until you have missed this many

scanAll

public void scanAll(Growable _blob,
                    java.awt.Shape _limitedSearchArea)