Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

Visible2DComponent.h

Go to the documentation of this file.
00001 
00040 #ifndef _AMIRE_COMPONENT_VISIBLE_2D_COMPONENT_H
00041 #define _AMIRE_COMPONENT_VISIBLE_2D_COMPONENT_H
00042 
00043 #include <amire/common/Defines.h>
00044 #include <amire/common/Viewport.h>
00045 #include <amire/common/Alignment.h>
00046 #include <amire/component/Component.h>
00047 #include <amire/component/CallbackHandlers.h>
00048 
00049 namespace amire {
00050   namespace component {
00082     class AMIRE_EXPORT_API Visible2DComponent : public virtual Component, public virtual Position2DPickingHandler {
00083     public:
00091       static int getMinDepthLevel();
00092 
00100       static int getMaxDepthLevel();
00101 
00109       static double getMinDepthValue();
00110 
00118       static double getMaxDepthValue();
00119 
00127       static double getDepthDelta();
00128 
00129     private:
00130       bool initEmit;
00131 
00132     protected: 
00133       bool visible;
00134 
00135       amire::common::Position2D position;
00136       amire::common::Dimension2D dimension;
00137       amire::common::Alignment2D alignment;
00138       amire::common::Rectangle inAlignmentOffset;
00139       amire::common::Rectangle outAlignmentOffset;
00140       double depth;
00141 
00142       int visibleInSlotId;
00143       int visibleOutSlotId;
00144       int alignmentOffsetInSlotId;
00145       int alignmentOffsetOutSlotId;
00146 
00147     public:
00148       virtual ~Visible2DComponent();
00149       virtual void configurationPropertyModified();
00150       virtual void reinitializeEngine(MREngine *engine);
00151       virtual void functionalCallback(MREngine *engine);
00152       virtual osg::ref_ptr<const amire::property::Property> emitOutSlotProperty(int outSlotId);
00153       virtual void receiveInSlotProperty(int inSlotId, const osg::ref_ptr<const amire::property::Property> &property) ;
00154       virtual bool pickingCallback(MREngine *engine, double x, double y, long pickingMode, double &distance) const;
00155       virtual void actionPerformed(const osg::ref_ptr<Action> &action);
00156 
00157     protected:
00158       Visible2DComponent(ComponentManager *componentManager);
00159 
00166       void initConfigurationProperty();
00167 
00173       void updateOutAlignmentOffset();
00174 
00181       void beginDisplay(MREngine *engine);
00182 
00189       void endDisplay();
00190 
00194       double getDepth() const;
00195     };
00196   }
00197 }
00198 #endif

Generated on Tue May 20 17:23:54 2003 for AMIRE-Framework by doxygen1.3