edu.berkeley.guir.papier_mache.vision
Class MotionlessFilter

java.lang.Object
  extended by edu.berkeley.guir.papier_mache.event.EventFilter
      extended by edu.berkeley.guir.papier_mache.vision.MotionlessFilter
All Implemented Interfaces:
java.util.EventListener, PhobListener

public class MotionlessFilter
extends EventFilter

A filter for objects that stay in one place. It's a good way to distinguish inanimate objects from people and hands.

Author:
Scott Klemmer ( srk(AT)cs.berkeley.edu )

Constructor Summary
MotionlessFilter(PhobListener visionListener, int framesMotionless)
           
 
Method Summary
 void phobAdded(PhobEvent visEvent)
          Called when a PhobProducer has sensed a new object
 void phobRemoved(PhobEvent visEvent)
          Called when an object is removed from a PhobProducer's sensor
 void phobUpdated(PhobEvent visEvent)
          Called when new information is available about a previously found object
 
Methods inherited from class edu.berkeley.guir.papier_mache.event.EventFilter
addClassification, addListener
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MotionlessFilter

public MotionlessFilter(PhobListener visionListener,
                        int framesMotionless)
Parameters:
visionListener - the listener to forward events to
framesMotionless - the number of frames an object must be still before we begin forwarding events
Method Detail

phobAdded

public void phobAdded(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when a PhobProducer has sensed a new object

Specified by:
phobAdded in interface PhobListener
Overrides:
phobAdded in class EventFilter
Parameters:
visEvent - an event describing the found object

phobUpdated

public void phobUpdated(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when new information is available about a previously found object

Specified by:
phobUpdated in interface PhobListener
Overrides:
phobUpdated in class EventFilter
Parameters:
visEvent - an event with new information about the found object

phobRemoved

public void phobRemoved(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when an object is removed from a PhobProducer's sensor

Specified by:
phobRemoved in interface PhobListener
Overrides:
phobRemoved in class EventFilter
Parameters:
visEvent - an event referencing the removed object