00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef COIN_SOLOCATEHIGHLIGHT_H
00021 #define COIN_SOLOCATEHIGHLIGHT_H
00022
00023 #include <Inventor/nodes/SoSubNode.h>
00024 #include <Inventor/nodes/SoSeparator.h>
00025 #include <Inventor/fields/SoSFColor.h>
00026 #include <Inventor/fields/SoSFEnum.h>
00027
00028 class SoFullPath;
00029
00030 class COIN_DLL_API SoLocateHighlight : public SoSeparator {
00031 typedef SoSeparator inherited;
00032
00033 SO_NODE_HEADER(SoLocateHighlight);
00034
00035 public:
00036 static void initClass(void);
00037 SoLocateHighlight(void);
00038
00039 enum Modes {
00040 AUTO, ON, OFF
00041 };
00042
00043 enum Styles {
00044 EMISSIVE, EMISSIVE_DIFFUSE
00045 };
00046
00047 SoSFColor color;
00048 SoSFEnum style;
00049 SoSFEnum mode;
00050
00051 virtual void handleEvent(SoHandleEventAction * action);
00052 virtual void GLRenderBelowPath(SoGLRenderAction * action);
00053 virtual void GLRenderInPath(SoGLRenderAction * action);
00054 static void turnOffCurrentHighlight(SoGLRenderAction * action);
00055
00056 protected:
00057 virtual ~SoLocateHighlight();
00058 virtual void redrawHighlighted(SoAction * act, SbBool flag);
00059
00060 private:
00061
00062 static void turnoffcurrent(SoAction * action);
00063 void setOverride(SoGLRenderAction * action);
00064 static SoFullPath * currenthighlight;
00065 SbBool highlighted;
00066 };
00067
00068 #endif // !COIN_SOLOCATEHIGHLIGHT_H