FloorFileRT Class Reference
[IStage]

#include <Floor.h>

Inheritance diagram for FloorFileRT:

Inheritance graph
[legend]
Collaboration diagram for FloorFileRT:

Collaboration graph
[legend]
List of all members.

Detailed Description

Real time connection with the pressure sensitive floor.

Here is an example of creating your own floor client:

        class MyFloorHandler
        {
                public:
                // All we need is an operator() to receive the FloorInfo signal.
                void operator()(const FloorInfo &floorinfo)
                {
                        cout << "I just received a floor frame with " << floorinfo.sensels.size() << " sensels!" << endl;
                }
        };

        void main()
        {
                FloorFileRT floor;
                floor.Open("234.0.1.5");

                MyFloorHandler handler;
                floor >>= handler;

                // Just loop forever, the floor will be executing in its own thread.
                for ( ; ; )
        }


Public Types

typedef boost::signal< Signature > default_signal_t

Public Member Functions

virtual bool Open (string const &file)
 Opens a file or network connection containing floor pressure information.
virtual bool IsOpen () const
 Returns true if the file or network connection is open.
virtual FloorInfo GetFloorInfo ()
 Returns the FloorInfo structure containing the last received/loaded frame.
virtual vector< Point2GetMSCenters ()
const default_signal_t & default_signal () const
 Returns the default out signal.
template<typename T>
Descendant & operator>>= (T &link)
 Connects a sequence of components using signals.
template<typename T>
Descendant & operator>>= (slot_selector_t< T, Signature > link)
 Allows slot functions other than operator() to be used in a sequence of components.
template<typename T>
Descendant & operator>= (T &link)
 Allows branching in a component connection sequence.
template<typename T>
Descendant & operator>= (const slot_selector_t< T, Signature > &link)
 Allows slot functions other than operator() to be used with branching.
void disconnect_all_slots ()
 Disconnects all slots connected to the signal_link.
void Join ()
 Joins the thread (i.e., this function will not return until the thread finishes).
void Start ()
 Activates the thread.

Protected Member Functions

bool Terminating ()
 Returns true if the thread is being joined (the thread should finish).

Protected Attributes

default_signal_t out
boost::mutex mutex_
 Class mutex.
volatile bool terminating


Member Function Documentation

Descendant& operator>>= ( T &  link  )  [inline, inherited]

Connects a sequence of components using signals.

This operator is identical to signal_link::operator>= (it connects the left component to the right component, and returns a reference to the left component), except it is evaluated right to left. This makes it semantics more suitable for connecting a chain of connections.

Descendant& operator>>= ( slot_selector_t< T, Signature >  link  )  [inline, inherited]

Allows slot functions other than operator() to be used in a sequence of components.

See also:
slot_selector()

Descendant& operator>= ( T &  link  )  [inline, inherited]

Allows branching in a component connection sequence.

This operator is identical to signal_link::operator>>=, (it connects the left component to the right component, and returns a reference to the left component) except it is evaluated left to right. This makes its semantics more suitable for branching connections.

Descendant& operator>= ( const slot_selector_t< T, Signature > &  link  )  [inline, inherited]

Allows slot functions other than operator() to be used with branching.

See also:
slot_selector()


The documentation for this class was generated from the following file:
Generated on Tue Mar 6 17:57:15 2007 for AME Repository by  doxygen 1.5.1-p1