Go to the documentation of this file.00001 #ifndef Fireworks_Core_FWGeoTopNode_h
00002 #define Fireworks_Core_FWGeoTopNode_h
00003
00004
00005
00006
00007
00016
00017
00018
00019
00020
00021
00022 #ifndef __CINT__
00023 #include "Fireworks/Core/interface/FWGeometryTableManagerBase.h"
00024 #endif
00025 #include "TEveElement.h"
00026 #include "TAttBBox.h"
00027 #include <set>
00028
00029 class TGeoHMatrix;
00030 class TGLPhysicalShape;
00031 class TGLSelectRecord;
00032
00033 class FWGeometryTableView;
00034 class FWOverlapTableView;
00035 class TBuffer3D;
00036 class TGeoNode;
00037 class FWGeoTopNodeGLScene;
00038
00039
00040 class FWGeoTopNode : public TEveElementList,
00041 public TAttBBox
00042 {
00043 friend class FWGeoTopNodeGL;
00044
00045 public:
00046 FWGeoTopNode(const char* n = "FWGeoTopNode", const char* t = "FWGeoTopNode"){}
00047 virtual ~FWGeoTopNode(){}
00048
00049 virtual void Paint(Option_t* option="");
00050 FWGeoTopNodeGLScene *fSceneJebo;
00051
00052 virtual FWGeometryTableManagerBase* tableManager() { return 0; }
00053 std::set<TGLPhysicalShape*> fHted;
00054 std::set<TGLPhysicalShape*> fSted;
00055
00056 int getFirstSelectedTableIndex();
00057 bool selectPhysicalFromTable(int);
00058 void clearSelection() {fHted.clear(); fSted.clear();}
00059
00060 void printSelected();
00061
00062 virtual void UnSelected();
00063 virtual void UnHighlighted();
00064 virtual void popupMenu(int x, int y){}
00065
00066 protected:
00067 static UInt_t phyID(int tableIdx);
00068 static int tableIdx(TGLPhysicalShape* ps);
00069
00070 void ProcessSelection(TGLSelectRecord& rec, std::set<TGLPhysicalShape*>& sset, TGLPhysicalShape* id);
00071
00072 void EraseFromSet(std::set<TGLPhysicalShape*>& sset, TGLPhysicalShape* id);
00073 void ClearSet(std::set<TGLPhysicalShape*>& sset);
00074
00075 void SetStateOf(TGLPhysicalShape* id);
00076
00077
00078 void setupBuffMtx(TBuffer3D& buff, const TGeoHMatrix& mat);
00079 #ifndef __CINT__
00080 void paintShape(FWGeometryTableManagerBase::NodeInfo& nodeInfo, Int_t idx, const TGeoHMatrix& nm, bool volumeColor);
00081 #endif
00082
00083 virtual void ComputeBBox();
00084 private:
00085 FWGeoTopNode(const FWGeoTopNode&);
00086 const FWGeoTopNode& operator=(const FWGeoTopNode&);
00087
00088 ClassDef(FWGeoTopNode, 0);
00089 };
00090
00091
00092 #endif