CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Attributes
FWGeoTopNodeGL Class Reference

#include <FWGeoTopNodeGL.h>

Inheritance diagram for FWGeoTopNodeGL:

Public Member Functions

virtual Bool_t AlwaysSecondarySelect () const
 
 ClassDef (FWGeoTopNodeGL, 0)
 
virtual void DirectDraw (TGLRnrCtx &rnrCtx) const
 
 FWGeoTopNodeGL ()
 
virtual void ProcessSelection (TGLRnrCtx &rnrCtx, TGLSelectRecord &rec)
 
virtual void SetBBox ()
 
virtual Bool_t SetModel (TObject *obj, const Option_t *opt=0)
 
virtual Bool_t SupportsSecondarySelect () const
 
virtual ~FWGeoTopNodeGL ()
 

Protected Attributes

FWGeoTopNodefM
 

Detailed Description

Definition at line 7 of file FWGeoTopNodeGL.h.

Constructor & Destructor Documentation

FWGeoTopNodeGL::FWGeoTopNodeGL ( )

Definition at line 9 of file FWGeoTopNodeGL.cc.

9  :
10  TGLObject()
11 {
12  // Constructor.
13 }
virtual FWGeoTopNodeGL::~FWGeoTopNodeGL ( )
inlinevirtual

Definition at line 14 of file FWGeoTopNodeGL.h.

References DirectDraw(), MuonAssociatorByHits_cfi::obj, SetBBox(), and SetModel().

14 {}

Member Function Documentation

virtual Bool_t FWGeoTopNodeGL::AlwaysSecondarySelect ( ) const
inlinevirtual

Definition at line 24 of file FWGeoTopNodeGL.h.

References ClassDef(), and ProcessSelection().

24 { return kTRUE; }
FWGeoTopNodeGL::ClassDef ( FWGeoTopNodeGL  ,
 
)

Referenced by AlwaysSecondarySelect().

void FWGeoTopNodeGL::DirectDraw ( TGLRnrCtx &  rnrCtx) const
virtual

Definition at line 33 of file FWGeoTopNodeGL.cc.

Referenced by ~FWGeoTopNodeGL().

34 {
35  // Draw quad-set with GL.
36 
37  static const TEveException eH("TEveQuadSetGL::DirectDraw ");
38 
39  // printf("FWGeoTopNodeGL::DirectDraw\n");
40 
41  // glPushAttrib(GL_POINT_BIT);
42  // glPointSize(20);
43  // glBegin(GL_POINTS);
44  // glVertex3d(1,1,1);
45  // glEnd();
46  // glPopAttrib();
47 }
void FWGeoTopNodeGL::ProcessSelection ( TGLRnrCtx &  rnrCtx,
TGLSelectRecord &  rec 
)
virtual

Definition at line 50 of file FWGeoTopNodeGL.cc.

References FWGeoTopNode::fHted, fM, FWGeoTopNode::fSted, AlCaHLTBitMon_ParallelJobs::p, FWGeoTopNode::ProcessSelection(), and findQualityFiles::v.

Referenced by AlwaysSecondarySelect().

51 {
52  // Processes secondary selection from TGLViewer.
53  // Calls DigitSelected(Int_t) in the model object with index of
54  // selected point as the argument.
55 
56  // printf("FWGeoTopNodeGL::ProcessSelection who knows what we've got ...\n");
57  // rec.Print();
58 
59  TGLViewer *v = dynamic_cast<TGLViewer*>(rnrCtx.GetViewer());
60  /*
61  if (v)
62  {
63  printf(" but we know the first selection was what we actually want!\n");
64  printf(" and this is in rnrctx.viewer.selrec\n");
65  printf(" log=%p, this=%p\n", v->GetSelRec().GetLogShape(), this);
66  }
67  */
68  TGLPhysicalShape *p = v->GetSelRec().GetPhysShape();
69 
70  if (rec.GetHighlight())
71  {
72  fM->ProcessSelection(rec, fM->fHted, p);
73  }
74  else
75  {
76  fM->ProcessSelection(rec, fM->fSted, p);
77  }
78 
79  // Also, do something in UnSelected / UnHighlighted XXXXX
80 }
std::set< TGLPhysicalShape * > fSted
Definition: FWGeoTopNode.h:74
FWGeoTopNode * fM
std::set< TGLPhysicalShape * > fHted
Definition: FWGeoTopNode.h:73
void ProcessSelection(TGLSelectRecord &rec, std::set< TGLPhysicalShape * > &sset, TGLPhysicalShape *id)
void FWGeoTopNodeGL::SetBBox ( )
virtual

Definition at line 16 of file FWGeoTopNodeGL.cc.

Referenced by ~FWGeoTopNodeGL().

17 {
18  // Set bounding box.
19 
20  SetAxisAlignedBBox(((FWGeoTopNode*)fExternalObj)->AssertBBox());
21 }
Bool_t FWGeoTopNodeGL::SetModel ( TObject *  obj,
const Option_t *  opt = 0 
)
virtual

Definition at line 24 of file FWGeoTopNodeGL.cc.

References fM, and MuonAssociatorByHits_cfi::obj.

Referenced by ~FWGeoTopNodeGL().

25 {
26  // Set model object.
27 
28  fM = SetModelDynCast<FWGeoTopNode>(obj);
29  return kTRUE;
30 }
FWGeoTopNode * fM
virtual Bool_t FWGeoTopNodeGL::SupportsSecondarySelect ( ) const
inlinevirtual

Definition at line 23 of file FWGeoTopNodeGL.h.

23 { return kTRUE; }

Member Data Documentation

FWGeoTopNode* FWGeoTopNodeGL::fM
protected

Definition at line 10 of file FWGeoTopNodeGL.h.

Referenced by ProcessSelection(), and SetModel().