INTRODUCTION
Overview
Download and Install
Quick Start
Documentation
Publications

NONFRAMEWORK CODE
Driver Interfaces
Drivers
Libraries
Utilities

FRAMEWORK CODE
Interfaces
Components
Libraries
Utilities

Full Software Listings

DEVELOPER
Tutorials
Examples
Dev Guide
Dashboard

PEOPLE
Contributors
Users

SourceForge.net Logo
Project
Download
Mailing lists

 

         

position3delement.h

00001 #if 0
00002 /*
00003  * Orca-Robotics Project: Components for robotics 
00004  *               http://orca-robotics.sf.net/
00005  * Copyright (c) 2004-2009 Alex Brooks
00006  *
00007  * This copy of Orca is licensed to you under the terms described in
00008  * the LICENSE file included in this distribution.
00009  *
00010  */
00011 
00012 #ifndef ORCAGUI3D_POSITION3D_ELEMENT_H
00013 #define ORCAGUI3D_POSITION3D_ELEMENT_H
00014 
00015 #include <orcaqgui3d/icestormelement3d.h>
00016 #include <orcaqgui3dfactory/position3dpainter.h>
00017 #include <orcaqgui3d/iknowsplatformposition.h>
00018 
00019 namespace orcaqgui3d {
00020 
00024 class Position3dElement
00025     : public IceStormElement3d<Position3dPainter,
00026                                orca::Position3dData,
00027                                orca::Position3dPrx,
00028                                orca::Position3dConsumer,
00029                                orca::Position3dConsumerPrx>,
00030     public IKnowsPlatformPosition
00031 {
00032 
00033 public: 
00034 
00035     Position3dElement( const orcaice::Context  &context,
00036                        const std::string       &proxyString,
00037                        int                      timeoutMs=5000 )
00038         : IceStormElement3d<Position3dPainter,
00039                             orca::Position3dData,
00040                             orca::Position3dPrx,
00041                             orca::Position3dConsumer,
00042                             orca::Position3dConsumerPrx>(context, proxyString, painter_, timeoutMs ),
00043           painter_("3dmodels/jeep.3ds")
00044         {}
00045 
00046     virtual bool isInGlobalCS() { return false; }
00047     // virtual QStringList contextMenu();
00048     // virtual void execute( int action ) { painter_.execute( action ); };
00049     // virtual GuiElementType type() { return orcaqgui::LaserType; };
00050     // virtual void setColor( QColor color ) { painter_.setColor(color); }
00051     // virtual void setFocus( bool inFocus ) { painter_.setFocus( inFocus ); };
00052     virtual void iceStormConnectedEvent() {}
00053 
00054     // Access to platform location estimate.
00055     virtual float x() const { return painter_.pose().p.x; }
00056     virtual float y() const { return painter_.pose().p.y; }
00057     virtual float z() const { return painter_.pose().p.z; }
00058     virtual float roll()  const { return painter_.pose().o.r; }
00059     virtual float pitch() const { return painter_.pose().o.p; }
00060     virtual float yaw()   const { return painter_.pose().o.y; }
00061 
00062     virtual int platformKnowledgeReliability() const { return 2; }
00063     // virtual QPointF pos() const { return QPointF(x_,y_); };
00064 
00065 private: 
00066 
00067     Position3dPainter painter_;
00068 
00069 };
00070 
00071 }
00072 
00073 #endif
00074 #endif
 

Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)


Generated for Orca Robotics by  doxygen 1.4.5