CGEM BOSS 6.6.5.i
BESIII Offline Software System
Loading...
Searching...
No Matches
BesView Class Reference

#include <BesView.h>

+ Inheritance diagram for BesView:

Public Member Functions

 BesView ()
 
virtual ~BesView ()
 
virtual void SetViewType (EBESViewType ViewType, Bool_t resetview=kFALSE)
 
virtual void SetViewTypeBare (EBESViewType ViewType, Bool_t resetview=kFALSE)
 
virtual void DefaultRange ()
 
virtual void ClearPad ()
 
virtual void DrawLabel ()
 
virtual void ExecuteEvent (Int_t event, Int_t px, Int_t py)
 
virtual Int_t GetRSign (Float_t Phi)
 
virtual void UpdateView (Bool_t resetview=kFALSE)
 
virtual void WCtoNDC (const Float_t *pw, Float_t *pn)
 
virtual void WCtoNDC (const Double_t *pw, Double_t *pn)
 
virtual void NDCtoWC (const Float_t *pn, Float_t *pw)
 
virtual void NDCtoWC (const Double_t *pn, Double_t *pw)
 
virtual char * GetObjectInfo (Int_t px, Int_t py) const
 
void SetZoomRatio (Double_t ratio)
 
Double_t GetZoomRatio ()
 
EBESViewType GetViewType ()
 
Float_t GetMarkerSize ()
 
void View3D ()
 
void ViewXY ()
 
void ViewZR ()
 
void ViewCgemUF (int layer)
 
void ZoomIn ()
 
void ZoomOut ()
 
void Center ()
 
void Move (Int_t px, Int_t py)
 
void Front3D ()
 
void Side3D ()
 
void Top3D ()
 
void SetPhiRange (Float_t PhiMin=0, Float_t PhiMax=180)
 
void Reset ()
 
void Refresh ()
 
void SetMarkerSize (Float_t size)
 
Bool_t GetVisCgemGlobal ()
 
Bool_t GetVisCgemLayers ()
 
Bool_t GetVisCgemXStrips ()
 
Bool_t GetVisCgemVStrips ()
 
void SetVisCgemGlobal (Bool_t input)
 
void SetVisCgemLayers (Bool_t input)
 
void SetVisCgemXStrips (Bool_t input)
 
void SetVisCgemVStrips (Bool_t input)
 
Bool_t GetVisMdcGlobal ()
 
Bool_t GetVisMdcTubes ()
 
Bool_t GetVisMdcWires ()
 
void SetVisMdcGlobal (Bool_t input)
 
void SetVisMdcTubes (Bool_t input)
 
void SetVisMdcWires (Bool_t input)
 
Bool_t GetVisTofGlobal ()
 
Bool_t GetVisTofEast ()
 
Bool_t GetVisTofBarrel ()
 
Bool_t GetVisTofWest ()
 
Float_t GetVisZoom ()
 
void SetVisTofGlobal (Bool_t input)
 
void SetVisTofEast (Bool_t input)
 
void SetVisTofBarrel (Bool_t input)
 
void SetVisTofWest (Bool_t input)
 
void SetVisZoom (Float_t input)
 
Bool_t GetVisEmcGlobal ()
 
Bool_t GetVisEmcEast ()
 
Bool_t GetVisEmcBarrel ()
 
Bool_t GetVisEmcWest ()
 
Bool_t GetVisEmcSide ()
 
void SetVisEmcGlobal (Bool_t input)
 
void SetVisEmcEast (Bool_t input)
 
void SetVisEmcBarrel (Bool_t input)
 
void SetVisEmcWest (Bool_t input)
 
void SetVisEmcSide (Bool_t input)
 
Bool_t GetVisMucGlobal ()
 
Bool_t GetVisMucEast ()
 
Bool_t GetVisMucBarrel ()
 
Bool_t GetVisMucWest ()
 
Bool_t GetVisMucStrips ()
 
void SetVisMucGlobal (Bool_t input)
 
void SetVisMucEast (Bool_t input)
 
void SetVisMucBarrel (Bool_t input)
 
void SetVisMucWest (Bool_t input)
 
void SetVisMucStrips (Bool_t input)
 
Bool_t GetVisFull3DCgem ()
 
Bool_t GetVisFull3DMdc ()
 
Bool_t GetVisFull3DTof ()
 
Bool_t GetVisFull3DEmc ()
 
Bool_t GetVisFull3DMuc ()
 
void SetVisFull3DCgem (Bool_t input)
 
void SetVisFull3DMdc (Bool_t input)
 
void SetVisFull3DTof (Bool_t input)
 
void SetVisFull3DEmc (Bool_t input)
 
void SetVisFull3DMuc (Bool_t input)
 
Bool_t GetVisBeamPipe ()
 
Bool_t GetVisZRPlaneOnXY ()
 
Bool_t GetVisAxis ()
 
void SetVisBeamPipe (Bool_t input)
 
void SetVisZRPlaneOnXY (Bool_t input)
 
void SetVisAxis (Bool_t input)
 
Bool_t GetVisCgemHitsGlobal ()
 
Bool_t GetVisCgemHitsXStrip ()
 
Bool_t GetVisCgemHitsVStrip ()
 
Bool_t GetVisCgemHitsClusters ()
 
Bool_t GetVisCgemHitsFiredHL ()
 
void SetVisCgemHitsGlobal (Bool_t input)
 
void SetVisCgemHitsXStrip (Bool_t input)
 
void SetVisCgemHitsVStrip (Bool_t input)
 
void SetVisCgemHitsClusters (Bool_t input)
 
void SetVisCgemHitsFiredHL (Bool_t input)
 
Bool_t GetVisMdcHitsGlobal ()
 
Bool_t GetVisMdcHits ()
 
void SetVisMdcHitsGlobal (Bool_t input)
 
void SetVisMdcHits (Bool_t input)
 
Bool_t GetVisTofHitsGlobal ()
 
Bool_t GetVisTofHitsEast ()
 
Bool_t GetVisTofHitsBarrel ()
 
Bool_t GetVisTofHitsWest ()
 
void SetVisTofHitsGlobal (Bool_t input)
 
void SetVisTofHitsEast (Bool_t input)
 
void SetVisTofHitsBarrel (Bool_t input)
 
void SetVisTofHitsWest (Bool_t input)
 
Bool_t GetVisEmcHitsGlobal ()
 
Bool_t GetVisEmcHitsEast ()
 
Bool_t GetVisEmcHitsBarrel ()
 
Bool_t GetVisEmcHitsWest ()
 
Bool_t GetVisEmcHitsSide ()
 
void SetVisEmcHitsGlobal (Bool_t input)
 
void SetVisEmcHitsEast (Bool_t input)
 
void SetVisEmcHitsBarrel (Bool_t input)
 
void SetVisEmcHitsWest (Bool_t input)
 
void SetVisEmcHitsSide (Bool_t input)
 
Bool_t GetVisMucHitsGlobal ()
 
Bool_t GetVisMucHitsEast ()
 
Bool_t GetVisMucHitsBarrel ()
 
Bool_t GetVisMucHitsWest ()
 
void SetVisMucHitsGlobal (Bool_t input)
 
void SetVisMucHitsEast (Bool_t input)
 
void SetVisMucHitsBarrel (Bool_t input)
 
void SetVisMucHitsWest (Bool_t input)
 
Bool_t GetVisTracksGlobal ()
 
Bool_t GetVisTracksMdc ()
 
Bool_t GetVisTracksIdeal ()
 
Bool_t GetVisTracksTof ()
 
Bool_t GetVisTracksEmc ()
 
Bool_t GetVisTracksMuc ()
 
Bool_t GetVisTracksExt ()
 
Bool_t GetVisMCTruthTrack ()
 
void SetVisTracksGlobal (Bool_t input)
 
void SetVisTracksMdc (Bool_t input)
 
void SetVisTracksIdeal (Bool_t input)
 
void SetVisTracksTof (Bool_t input)
 
void SetVisTracksEmc (Bool_t input)
 
void SetVisTracksMuc (Bool_t input)
 
void SetVisTracksExt (Bool_t input)
 
void SetVisMCTruthTrack (Bool_t input)
 
Bool_t GetFishEyeStatus ()
 
Bool_t GetFishEye ()
 
void SetFishEye (Bool_t input=0)
 
void PrintCurrent ()
 
virtual void Centered ()
 
virtual void Front ()
 
virtual void Side ()
 
virtual void Top ()
 
virtual void ZoomMove ()
 
virtual void AdjustScales (TVirtualPad *pad=0)
 
virtual void Delete (Option_t *option)
 
virtual void DrawClass ()
 
virtual TObject * DrawClone (Option_t *option)
 
virtual void Dump ()
 
virtual void Inspect ()
 
virtual void SetDrawOption (Option_t *option)
 
virtual void SetLineAttributes ()
 
virtual void SetZoomFactor (Double_t factor)
 
virtual Double_t GetZoomFactor ()
 
BesStatusGetStatusCurrent ()
 
BesStatusGetStatus3D ()
 
BesStatusGetStatusXY ()
 
BesStatusGetStatusZR ()
 
BesStatusGetStatusCgemUF (int layer)
 
- Public Member Functions inherited from BesTView
 BesTView ()
 
 BesTView (Int_t system)
 
 BesTView (const Float_t *rmin, const Float_t *rmax, Int_t system=1)
 
 BesTView (const Double_t *rmin, const Double_t *rmax, Int_t system=1)
 
virtual ~BesTView ()
 
virtual void AxisVertex (Double_t ang, Double_t *av, Int_t &ix1, Int_t &ix2, Int_t &iy1, Int_t &iy2, Int_t &iz1, Int_t &iz2)
 
virtual void DefinePerspectiveView ()
 
virtual void DefineViewDirection (const Double_t *s, const Double_t *c, Double_t cosphi, Double_t sinphi, Double_t costhe, Double_t sinthe, Double_t cospsi, Double_t sinpsi, Double_t *tnorm, Double_t *tback)
 
virtual void DrawOutlineCube (TList *outline, Double_t *rmin, Double_t *rmax)
 
virtual void ExecuteRotateView (Int_t event, Int_t px, Int_t py)
 
virtual void FindScope (Double_t *scale, Double_t *center, Int_t &irep)
 
virtual Int_t GetDistancetoAxis (Int_t axis, Int_t px, Int_t py, Double_t &ratio)
 
Double_t GetDview () const
 
Double_t GetDproj () const
 
Double_t GetExtent () const
 
Bool_t GetAutoRange ()
 
Double_t GetLatitude ()
 
Double_t GetLongitude ()
 
Double_t GetPsi ()
 
virtual void GetRange (Float_t *min, Float_t *max)
 
virtual void GetRange (Double_t *min, Double_t *max)
 
Double_t * GetRmax ()
 
Double_t * GetRmin ()
 
TSeqCollection * GetOutline ()
 
Double_t * GetTback ()
 
Double_t * GetTN ()
 
Double_t * GetTnorm ()
 
Int_t GetSystem ()
 
void GetWindow (Double_t &u0, Double_t &v0, Double_t &du, Double_t &dv) const
 
Double_t GetWindowWidth () const
 
Double_t GetWindowHeight () const
 
virtual void FindNormal (Double_t x, Double_t y, Double_t z, Double_t &zn)
 
virtual void FindPhiSectors (Int_t iopt, Int_t &kphi, Double_t *aphi, Int_t &iphi1, Int_t &iphi2)
 
virtual void FindThetaSectors (Int_t iopt, Double_t phi, Int_t &kth, Double_t *ath, Int_t &ith1, Int_t &ith2)
 
Bool_t IsClippedNDC (Double_t *p) const
 
Bool_t IsPerspective () const
 
Bool_t IsViewChanged () const
 
virtual void NormalWCtoNDC (const Float_t *pw, Float_t *pn)
 
virtual void NormalWCtoNDC (const Double_t *pw, Double_t *pn)
 
virtual void PadRange (Int_t rback)
 
void ResizePad ()
 
virtual void SetAutoRange (Bool_t autorange=kTRUE)
 
virtual void SetAxisNDC (const Double_t *x1, const Double_t *x2, const Double_t *y1, const Double_t *y2, const Double_t *z1, const Double_t *z2)
 
void SetDefaultWindow ()
 
void SetDview (Double_t dview)
 
void SetDproj (Double_t dproj)
 
void SetLatitude (Double_t latitude)
 
void SetLongitude (Double_t longitude)
 
void SetPsi (Double_t psi)
 
virtual void SetOutlineToCube ()
 
virtual void SetParallel ()
 
virtual void SetPerspective ()
 
virtual void SetRange (const Double_t *min, const Double_t *max)
 
virtual void SetRange (Double_t x0, Double_t y0, Double_t z0, Double_t x1, Double_t y1, Double_t z1, Int_t flag=0)
 
virtual void SetSystem (Int_t system)
 
virtual void SetView (Double_t longitude, Double_t latitude, Double_t psi, Int_t &irep)
 
void SetViewChanged (Bool_t flag=kTRUE)
 
void SetWindow (Double_t u0, Double_t v0, Double_t du, Double_t dv)
 
void MoveFocus (Double_t *center, Double_t dx, Double_t dy, Double_t dz, Int_t nsteps=10, Double_t dlong=0, Double_t dlat=0, Double_t dpsi=0)
 
virtual void MoveViewCommand (Char_t chCode, Int_t count=1)
 
void MoveWindow (Char_t option)
 
virtual void Centered3DImages (TVirtualPad *pad=0)
 
virtual void FrontView (TVirtualPad *pad=0)
 
virtual void ZoomView (TVirtualPad *pad=0, Double_t zoomFactor=1.25)
 
virtual void UnzoomView (TVirtualPad *pad=0, Double_t unZoomFactor=1.25)
 
virtual void RotateView (Double_t phi, Double_t theta, TVirtualPad *pad=0)
 
virtual void SideView (TVirtualPad *pad=0)
 
virtual void TopView (TVirtualPad *pad=0)
 
virtual void ToggleRulers (TVirtualPad *pad=0)
 
virtual void ShowAxis ()
 
virtual void ToggleZoom (TVirtualPad *pad=0)
 
virtual void Zoom ()
 
virtual void UnZoom ()
 
 ClassDef (BesTView, 2)
 

Additional Inherited Members

- Public Types inherited from BesTView
enum  { kPerspective = BIT(6) }
 
- Static Public Member Functions inherited from BesTView
static void AdjustPad (TVirtualPad *pad=0)
 
- Protected Member Functions inherited from BesTView
 BesTView (const BesTView &)
 Set to TRUE after ExecuteRotateView.
 
BesTViewoperator= (const BesTView &)
 
void ResetView (Double_t longitude, Double_t latitude, Double_t psi, Int_t &irep)
 
- Protected Attributes inherited from BesTView
Double_t fLatitude
 
Double_t fLongitude
 
Double_t fPsi
 
Double_t fDview
 
Double_t fDproj
 
Double_t fUpix
 
Double_t fVpix
 
Double_t fTN [16]
 
Double_t fTB [16]
 
Double_t fRmax [3]
 
Double_t fRmin [3]
 
Double_t fUVcoord [4]
 
Double_t fTnorm [16]
 
Double_t fTback [16]
 
Double_t fX1 [3]
 
Double_t fX2 [3]
 
Double_t fY1 [3]
 
Double_t fY2 [3]
 
Double_t fZ1 [3]
 
Double_t fZ2 [3]
 
Int_t fSystem
 
TSeqCollection * fOutline
 
Bool_t fDefaultOutline
 
Bool_t fAutoRange
 
Bool_t fChanged
 

Detailed Description

Definition at line 30 of file BesView.h.

Constructor & Destructor Documentation

◆ BesView()

BesView::BesView ( )

◆ ~BesView()

BesView::~BesView ( )
virtual

Definition at line 81 of file BesView.cxx.

81 {
82 //
83 // BesView default destructor
84 if ( gDebug ) cout << "BesView default dtor called" << endl;
85
86 delete fLabel;
87
88 delete fStatus3D;
89 delete fStatusXY;
90 delete fStatusZR;
91 delete fStatusCurrent;
92
93 //Long Peixun's update: for CGEM UF view
94 delete fStatusCgemUF[0];
95 delete fStatusCgemUF[1];
96 delete fStatusCgemUF[2];
97}

Member Function Documentation

◆ AdjustScales()

virtual void BesView::AdjustScales ( TVirtualPad * pad = 0)
inlinevirtual

Reimplemented from BesTView.

Definition at line 296 of file BesView.h.

virtual void AdjustScales(TVirtualPad *pad=0)

◆ Center()

void BesView::Center ( )

Definition at line 559 of file BesView.cxx.

559 {
560 //
561 // Center view
562 //if ( fViewType & k3DView ){
563 //this->Centered();
564 //} else {
565 Double_t xrange, yrange;
566 xrange = gPad->GetX2() - gPad->GetX1();
567 yrange = gPad->GetY2() - gPad->GetY1();
568 gPad->Range(-xrange/2, -yrange/2, xrange/2, yrange/2);
569 gPad->Modified();
570
571 //Long Peixun's update: Set view center
572 ViewCenter[0] = ViewCenter[1] = 0.0;
573 //}
574}

Referenced by BesClient::ExecuteEvent(), BesClient::HandleButtons(), and SetViewType().

◆ Centered()

virtual void BesView::Centered ( )
inlinevirtual

Reimplemented from BesTView.

Definition at line 290 of file BesView.h.

virtual void Centered()
Definition BesTView.h:176

◆ ClearPad()

void BesView::ClearPad ( )
virtual

Definition at line 439 of file BesView.cxx.

439 {
440 //
441 // Clear current without deleting this view
442 //
443 // Probably this doesn't work for the postscript output
444 // Look at TPad::Clear() for more details
445 if ( gDebug ) cout << "BesView::ClearPad called" << endl;
446 if ( gPad->GetListOfPrimitives() ) gPad->GetListOfPrimitives()->Clear();
447}

Referenced by SetViewType().

◆ DefaultRange()

void BesView::DefaultRange ( )
virtual

Definition at line 101 of file BesView.cxx.

102{
103 SetRange(-1.0*m_BesR, -1.0*m_BesR, -0.5*m_BesZ, m_BesR, m_BesR, 0.5*m_BesZ);
104 fMarkerSize = 0.1; //Long Peixun's update: Reset marker size here
105}
virtual void SetRange(const Double_t *min, const Double_t *max)

Referenced by SetViewType(), and SetZoomRatio().

◆ Delete()

virtual void BesView::Delete ( Option_t * option)
inlinevirtual

Definition at line 297 of file BesView.h.

297{ BesTView::Delete(option); }

◆ DrawClass()

virtual void BesView::DrawClass ( )
inlinevirtual

Definition at line 298 of file BesView.h.

298{ BesTView::DrawClass(); }

◆ DrawClone()

virtual TObject * BesView::DrawClone ( Option_t * option)
inlinevirtual

Definition at line 299 of file BesView.h.

299{ return BesTView::DrawClone(option); }

◆ DrawLabel()

void BesView::DrawLabel ( )
virtual

Definition at line 773 of file BesView.cxx.

773 {
774 //
775 // Draw label for current view
776
777 fLabel->SetX1(-0.9);
778 fLabel->SetX2(-0.6);
779 fLabel->SetY1(-0.9);
780 fLabel->SetY2(-0.78);
781
782 switch (fViewType) {
783 case k3DView:
784 fLabel->SetLabel("3D View");
785 break;
786 case kXYView:
787 fLabel->SetLabel("XY View");
788 break;
789 case kZRView:
790 fLabel->SetLabel("ZR View");
791 break;
792 //Long Peixun's update: CGEM Unfolded display for each layer
793 case kCgemUFView0:
794 fLabel->SetLabel("CGEM Layer0");
795 break;
796 case kCgemUFView1:
797 fLabel->SetLabel("CGEM Layer1");
798 break;
799 case kCgemUFView2:
800 fLabel->SetLabel("CGEM Layer2");
801 break;
802 }
803 fLabel->Draw("BR,NDC,SAME");
804
805
806 /*
807 switch (fViewType) {
808 case k3DView:
809 fLabel->DrawPaveLabel(0.02,0.02,0.17,0.09, "3D View", "BR,NDC,SAME");
810 break;
811 case kXYView:
812 //fLabel->SetLabel("XY View");
813 fLabel->DrawPaveLabel(0.02,0.02,0.17,0.09, "XY View", "BR,NDC,SAME");
814 break;
815 case kZRView:
816 fLabel->DrawPaveLabel(0.02,0.02,0.17,0.09, "ZR View", "BR,NDC,SAME");
817 break;
818 }
819 */
820}
@ kCgemUFView2
Definition BesStatus.h:20
@ kCgemUFView0
Definition BesStatus.h:18
@ kXYView
Definition BesStatus.h:15
@ k3DView
Definition BesStatus.h:14
@ kCgemUFView1
Definition BesStatus.h:19
@ kZRView
Definition BesStatus.h:16

Referenced by SetViewType().

◆ Dump()

virtual void BesView::Dump ( )
inlinevirtual

Definition at line 302 of file BesView.h.

302{ BesTView::Dump(); }

◆ ExecuteEvent()

void BesView::ExecuteEvent ( Int_t event,
Int_t px,
Int_t py )
virtual

Reimplemented from BesTView.

Definition at line 451 of file BesView.cxx.

451 {
452 //
453 // Execute mouse events
454 if ( gDebug ) cout << "BesView::ExecuteEvent called" << endl;
455
456 // Editor mode
457 if (gROOT->GetEditorMode()) {
458 gPad->ExecuteEvent(event,px,py);
459 return;
460 }
461
462 if (gBesCursor->GetType() == kBesHand) {
463
464 gPad->SetCursor(kMove);
465 static Double_t xmin, ymin, xmax, ymax, x0, y0;
466 Double_t dx, dy, x, y;
467 switch (event) {
468
469 case kButton1Down:
470 // Remember position of pointer
471 xmin = gPad->GetX1();
472 ymin = gPad->GetY1();
473 xmax = gPad->GetX2();
474 ymax = gPad->GetY2();
475 x0 = gPad->AbsPixeltoX(px);
476 y0 = gPad->AbsPixeltoY(py);
477 break;
478
479 case kButton1Motion:
480 gPad->SetCursor(kMove);
481
482 case kButton1Up:
483 // Set new pad range
484 x = gPad->AbsPixeltoX(px);
485 y = gPad->AbsPixeltoY(py);
486 dx = -(x - x0);
487 dy = -(y - y0);
488 //((ZPad*)gPad)->SetNoAspect(kTRUE);
489 gPad->Range(xmin+dx, ymin+dy, xmax+dx, ymax+dy);
490 //((ZPad*)gPad)->SetNoAspect(kFALSE);
491 gPad->Modified();
492 //Long Peixun's update: Set view center
493 ViewCenter[0] = (xmin + xmax) / 2 + dx;
494 ViewCenter[1] = (ymin + ymax) / 2 + dy;
495 break;
496
497 default:
498 gPad->SetCursor(kMove);
499 }
500 }
501 else if (gBesCursor->GetType() == kBesPick){
502
503 gPad->SetCursor(kPointer);
504
505 if ( fViewType & k3DView ) {
506 ExecuteRotateView(event, px, py);
507 }
508 }
509}
@ kBesHand
Definition BesCursor.h:15
@ kBesPick
Definition BesCursor.h:14
R__EXTERN BesCursor * gBesCursor
Definition BesCursor.h:40
Double_t x[10]
EBESCursorType GetType()
Definition BesCursor.h:32
virtual void ExecuteRotateView(Int_t event, Int_t px, Int_t py)
Definition BesTView.cxx:745

Referenced by BesCircle2D::ExecuteEvent(), BesGeoTrack::ExecuteEvent(), BesMcTrack::ExecuteEvent(), BesPolygon2D::ExecuteEvent(), Cgem2DVStrip::ExecuteEvent(), Cgem2DXStrip::ExecuteEvent(), Emc2DCrystal::ExecuteEvent(), Mdc2DWire::ExecuteEvent(), Muc2DStrip::ExecuteEvent(), and Tof2DScin::ExecuteEvent().

◆ Front()

virtual void BesView::Front ( )
inlinevirtual

Reimplemented from BesTView.

Definition at line 291 of file BesView.h.

291{ BesTView::Top(); }
virtual void Top()
Definition BesTView.h:180

Referenced by Front3D(), BesClient::HandleButtons(), and SetViewType().

◆ Front3D()

void BesView::Front3D ( )
inline

Definition at line 102 of file BesView.h.

102 {
103 this->View3D();
104 this->Front(); } // *MENU*
virtual void Front()
Definition BesView.h:291
void View3D()
Definition BesView.h:78

◆ GetFishEye()

Bool_t BesView::GetFishEye ( )
inline

Definition at line 276 of file BesView.h.

276{ return fFishEye; }

Referenced by BesClient::HandleButtons(), and BesClient::UpdateStatus().

◆ GetFishEyeStatus()

Bool_t BesView::GetFishEyeStatus ( )
inline

Definition at line 275 of file BesView.h.

275{ return fStatusCurrent->fFishEye; }
Bool_t fFishEye
visibility flag for MC truth tracks
Definition BesStatus.h:132

Referenced by BesClient::UpdateStatus().

◆ GetMarkerSize()

Float_t BesView::GetMarkerSize ( )
inline

Definition at line 75 of file BesView.h.

75{ return fMarkerSize;}

Referenced by BesMarker2D::Paint().

◆ GetObjectInfo()

char * BesView::GetObjectInfo ( Int_t px,
Int_t py ) const
virtual

Definition at line 965 of file BesView.cxx.

965 {
966 //
967 // Returns string containing info about the object at position (px,py).
968 Double_t pw[3];
969 Double_t Pndc[3] = { gPad->AbsPixeltoX(px), gPad->AbsPixeltoY(py), 0};
970 BesView* view = dynamic_cast<BesView*>(gPad->GetView());
971 if (view) view->NDCtoWC(Pndc, pw); //Long Peixun's update: check view pointer before call function
972 //cout << gPad->GetName() << endl;
973
974 //
975 // Converts from pixel coordinates to world
976 // coordinates of according view
977
978 static char info[64];
979 if ( fViewType & kZRView ) {
980 sprintf(info, "z=%-.3fmm, r=%-.3fmm", pw[2], pw[1]);
981 return info;
982 } else {
983 sprintf(info, "x=%-.3fmm, y=%-.3fmm", pw[0], pw[1]);
984 return info;
985 }
986}
virtual void NDCtoWC(const Float_t *pn, Float_t *pw)
Definition BesView.cxx:890

Referenced by BesClient::ExecuteEvent(), BesCircle2D::GetObjectInfo(), BesGeoTrack::GetObjectInfo(), BesMarker2D::GetObjectInfo(), BesPolygon2D::GetObjectInfo(), Cgem2DStripBase::GetObjectInfo(), Emc2DCrystal::GetObjectInfo(), Mdc2DWire::GetObjectInfo(), Muc2DStrip::GetObjectInfo(), and Tof2DScin::GetObjectInfo().

◆ GetRSign()

Int_t BesView::GetRSign ( Float_t Phi)
virtual

Definition at line 717 of file BesView.cxx.

717 {
718 //
719 // Get sign of the R coordinate (ZR view)
720 // for a given phi (in radians)
721 Int_t Sign;
722
723 // Convert to deg, because phi range is given in degrees
724 Float_t Phi2 = (Phi - 2*TMath::Pi()*Int_t(Phi/(2*TMath::Pi())))
725 * 180./TMath::Pi();
726 if ( Phi2 < 0 ) Phi2 += 360;
727 if ( Phi2 >= fStatusCurrent->fPhiRangeMin && Phi2 < fStatusCurrent->fPhiRangeMax ) {
728 Sign = 1;
729 } else {
730 Sign = -1;
731 }
732 return Sign;
733}
double Phi(RecMdcKalTrack *trk)
float Float_t
Float_t fPhiRangeMin
flags for fish eye view
Definition BesStatus.h:136

Referenced by ZHelix::SetPoints().

◆ GetStatus3D()

BesStatus * BesView::GetStatus3D ( )
inline

Definition at line 312 of file BesView.h.

312{ return fStatus3D; };

Referenced by BesClient::SaveMyConfig().

◆ GetStatusCgemUF()

BesStatus * BesView::GetStatusCgemUF ( int layer)
inline

Definition at line 317 of file BesView.h.

317{ return fStatusCgemUF[layer]; }

Referenced by BesClient::SaveMyConfig().

◆ GetStatusCurrent()

BesStatus * BesView::GetStatusCurrent ( )
inline

Definition at line 311 of file BesView.h.

311{ return fStatusCurrent; };

Referenced by BesClient::LoadMyConfig(), and BesClient::UpdateStatus().

◆ GetStatusXY()

BesStatus * BesView::GetStatusXY ( )
inline

Definition at line 313 of file BesView.h.

313{ return fStatusXY; };

Referenced by BesClient::SaveMyConfig().

◆ GetStatusZR()

BesStatus * BesView::GetStatusZR ( )
inline

Definition at line 314 of file BesView.h.

314{ return fStatusZR; };

Referenced by BesClient::SaveMyConfig().

◆ GetViewType()

◆ GetVisAxis()

Bool_t BesView::GetVisAxis ( )
inline

Definition at line 194 of file BesView.h.

194{ return fStatusCurrent->fAxis; }
Bool_t fAxis
visibility flag for ZRPlaneOnXY
Definition BesStatus.h:81

Referenced by BesGeometry::Draw2DXY(), BesGeometry::Draw2DZR(), BesClient::HandleButtons(), and BesClient::UpdateStatus().

◆ GetVisBeamPipe()

Bool_t BesView::GetVisBeamPipe ( )
inline

Definition at line 192 of file BesView.h.

192{ return fStatusCurrent->fBeamPipe; }
Bool_t fBeamPipe
visivility flag for full 3D Muc
Definition BesStatus.h:79

Referenced by BesGeometry::Draw2DXY(), BesGeometry::Draw2DZR(), BesGeometry::Draw3D(), and BesClient::UpdateStatus().

◆ GetVisCgemGlobal()

Bool_t BesView::GetVisCgemGlobal ( )
inline

Definition at line 120 of file BesView.h.

120{ return fStatusCurrent->fCgemGlobal; }
Bool_t fCgemGlobal
Definition BesStatus.h:35

Referenced by CgemROOTGeo::Draw(), CgemROOTGeo::DrawUF(), and BesClient::UpdateStatus().

◆ GetVisCgemHitsClusters()

Bool_t BesView::GetVisCgemHitsClusters ( )
inline

Definition at line 204 of file BesView.h.

204{ return fStatusCurrent->fCgemHitsClusters; }
Bool_t fCgemHitsClusters
Definition BesStatus.h:87

Referenced by BesEvent::DrawCgemClusters(), BesEvent::DrawCgemUFClusters(), BesGeoTrack::ExecuteEvent(), and BesClient::UpdateStatus().

◆ GetVisCgemHitsFiredHL()

Bool_t BesView::GetVisCgemHitsFiredHL ( )
inline

Definition at line 205 of file BesView.h.

205{ return fStatusCurrent->fCgemHitsFiredHL; }
Bool_t fCgemHitsFiredHL
Definition BesStatus.h:88

Referenced by Cgem2DXStrip::DistancetoPrimitive(), Cgem2DXStrip::Paint(), and BesClient::UpdateStatus().

◆ GetVisCgemHitsGlobal()

Bool_t BesView::GetVisCgemHitsGlobal ( )
inline

Definition at line 201 of file BesView.h.

201{ return fStatusCurrent->fCgemHitsGlobal; }
Bool_t fCgemHitsGlobal
visibility flag for axis
Definition BesStatus.h:84

Referenced by CgemROOTGeo::Draw3DHits(), BesEvent::DrawCgemClusters(), BesEvent::DrawCgemUFClusters(), CgemROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), and BesClient::UpdateStatus().

◆ GetVisCgemHitsVStrip()

Bool_t BesView::GetVisCgemHitsVStrip ( )
inline

Definition at line 203 of file BesView.h.

203{ return fStatusCurrent->fCgemHitsVStrip; }
Bool_t fCgemHitsVStrip
Definition BesStatus.h:86

Referenced by CgemROOTGeo::Draw3DHits(), CgemROOTGeo::DrawHits(), and BesClient::UpdateStatus().

◆ GetVisCgemHitsXStrip()

Bool_t BesView::GetVisCgemHitsXStrip ( )
inline

Definition at line 202 of file BesView.h.

202{ return fStatusCurrent->fCgemHitsXStrip; }
Bool_t fCgemHitsXStrip
Definition BesStatus.h:85

Referenced by CgemROOTGeo::Draw3DHits(), CgemROOTGeo::DrawHits(), and BesClient::UpdateStatus().

◆ GetVisCgemLayers()

Bool_t BesView::GetVisCgemLayers ( )
inline

Definition at line 121 of file BesView.h.

121{ return fStatusCurrent->fCgemLayers; }
Bool_t fCgemLayers
Definition BesStatus.h:36

Referenced by CgemROOTGeo::Draw(), CgemROOTGeo::DrawUF(), and BesClient::UpdateStatus().

◆ GetVisCgemVStrips()

Bool_t BesView::GetVisCgemVStrips ( )
inline

Definition at line 123 of file BesView.h.

123{ return fStatusCurrent->fCgemVStrips; }
Bool_t fCgemVStrips
Definition BesStatus.h:38

Referenced by Cgem2DVStrip::DistancetoPrimitive(), CgemROOTGeo::Draw(), CgemROOTGeo::DrawUF(), and BesClient::UpdateStatus().

◆ GetVisCgemXStrips()

Bool_t BesView::GetVisCgemXStrips ( )
inline

Definition at line 122 of file BesView.h.

122{ return fStatusCurrent->fCgemXStrips; }
Bool_t fCgemXStrips
Definition BesStatus.h:37

Referenced by Cgem2DXStrip::DistancetoPrimitive(), CgemROOTGeo::Draw(), CgemROOTGeo::DrawUF(), and BesClient::UpdateStatus().

◆ GetVisEmcBarrel()

Bool_t BesView::GetVisEmcBarrel ( )
inline

Definition at line 155 of file BesView.h.

155{ return fStatusCurrent->fEmcBarrel; }
Bool_t fEmcBarrel
visivility flag for Emc east EC
Definition BesStatus.h:57

Referenced by EmcROOTGeo::Draw(), EmcROOTGeo::SetVisEmcDetector(), and BesClient::UpdateStatus().

◆ GetVisEmcEast()

Bool_t BesView::GetVisEmcEast ( )
inline

Definition at line 154 of file BesView.h.

154{ return fStatusCurrent->fEmcEast; }
Bool_t fEmcEast
visivility flag for global Emc
Definition BesStatus.h:56

Referenced by EmcROOTGeo::Draw(), EmcROOTGeo::SetVisEmcDetector(), and BesClient::UpdateStatus().

◆ GetVisEmcGlobal()

Bool_t BesView::GetVisEmcGlobal ( )
inline

Definition at line 153 of file BesView.h.

153{ return fStatusCurrent->fEmcGlobal; }
Bool_t fEmcGlobal
visibility flag for Tof west EC
Definition BesStatus.h:55

Referenced by EmcROOTGeo::Draw(), EmcROOTGeo::SetVisEmcDetector(), and BesClient::UpdateStatus().

◆ GetVisEmcHitsBarrel()

Bool_t BesView::GetVisEmcHitsBarrel ( )
inline

Definition at line 234 of file BesView.h.

234{ return fStatusCurrent->fEmcHitsBarrel; }
Bool_t fEmcHitsBarrel
visibility flag for Emc Hits East
Definition BesStatus.h:105

Referenced by EmcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Emc2DCrystal::Paint(), EmcROOTGeo::SetVisEmcHits(), and BesClient::UpdateStatus().

◆ GetVisEmcHitsEast()

Bool_t BesView::GetVisEmcHitsEast ( )
inline

Definition at line 233 of file BesView.h.

233{ return fStatusCurrent->fEmcHitsEast; }
Bool_t fEmcHitsEast
visibility flag for global Emc Hits
Definition BesStatus.h:104

Referenced by EmcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Emc2DCrystal::Paint(), EmcROOTGeo::SetVisEmcHits(), and BesClient::UpdateStatus().

◆ GetVisEmcHitsGlobal()

Bool_t BesView::GetVisEmcHitsGlobal ( )
inline

Definition at line 232 of file BesView.h.

232{ return fStatusCurrent->fEmcHitsGlobal; }
Bool_t fEmcHitsGlobal
visibility flag for Tof Hits West
Definition BesStatus.h:103

Referenced by EmcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Emc2DCrystal::Paint(), EmcROOTGeo::SetVisEmcHits(), and BesClient::UpdateStatus().

◆ GetVisEmcHitsSide()

Bool_t BesView::GetVisEmcHitsSide ( )
inline

Definition at line 236 of file BesView.h.

236{ return fStatusCurrent->fEmcHitsSide; }
Bool_t fEmcHitsSide
visibility flag for Emc Hits West
Definition BesStatus.h:107

Referenced by Emc2DCrystal::DistancetoPrimitive(), Emc2DCrystal::Paint(), and BesClient::UpdateStatus().

◆ GetVisEmcHitsWest()

Bool_t BesView::GetVisEmcHitsWest ( )
inline

Definition at line 235 of file BesView.h.

235{ return fStatusCurrent->fEmcHitsWest; }
Bool_t fEmcHitsWest
visibility flag for Emc Hits Barrel
Definition BesStatus.h:106

Referenced by EmcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Emc2DCrystal::Paint(), EmcROOTGeo::SetVisEmcHits(), and BesClient::UpdateStatus().

◆ GetVisEmcSide()

Bool_t BesView::GetVisEmcSide ( )
inline

Definition at line 157 of file BesView.h.

157{ return fStatusCurrent->fEmcSide; }
Bool_t fEmcSide
visivility flag for Emc west EC
Definition BesStatus.h:59

Referenced by Emc2DCrystal::DistancetoPrimitive(), Emc2DCrystal::Paint(), and BesClient::UpdateStatus().

◆ GetVisEmcWest()

Bool_t BesView::GetVisEmcWest ( )
inline

Definition at line 156 of file BesView.h.

156{ return fStatusCurrent->fEmcWest; }
Bool_t fEmcWest
visivility flag for Emc barrel
Definition BesStatus.h:58

Referenced by EmcROOTGeo::Draw(), EmcROOTGeo::SetVisEmcDetector(), and BesClient::UpdateStatus().

◆ GetVisFull3DCgem()

Bool_t BesView::GetVisFull3DCgem ( )
inline

Definition at line 179 of file BesView.h.

179{ return fStatusCurrent->fFull3DCgem; }
Bool_t fFull3DCgem
visivility flag for Muc strips
Definition BesStatus.h:71

◆ GetVisFull3DEmc()

Bool_t BesView::GetVisFull3DEmc ( )
inline

Definition at line 182 of file BesView.h.

182{ return fStatusCurrent->fFull3DEmc; }
Bool_t fFull3DEmc
visivility flag for full 3D Tof
Definition BesStatus.h:74

Referenced by EmcROOTGeo::SetDetector(), and BesClient::UpdateStatus().

◆ GetVisFull3DMdc()

Bool_t BesView::GetVisFull3DMdc ( )
inline

Definition at line 180 of file BesView.h.

180{ return fStatusCurrent->fFull3DMdc; }
Bool_t fFull3DMdc
Definition BesStatus.h:72

Referenced by MdcROOTGeo::SetDetector(), and BesClient::UpdateStatus().

◆ GetVisFull3DMuc()

Bool_t BesView::GetVisFull3DMuc ( )
inline

Definition at line 183 of file BesView.h.

183{ return fStatusCurrent->fFull3DMuc; }
Bool_t fFull3DMuc
visivility flag for full 3D Emc
Definition BesStatus.h:75

Referenced by MucROOTGeo::SetDetector(), and BesClient::UpdateStatus().

◆ GetVisFull3DTof()

Bool_t BesView::GetVisFull3DTof ( )
inline

Definition at line 181 of file BesView.h.

181{ return fStatusCurrent->fFull3DTof; }
Bool_t fFull3DTof
visivility flag for full 3D Mdc
Definition BesStatus.h:73

Referenced by BesClient::UpdateStatus().

◆ GetVisMCTruthTrack()

Bool_t BesView::GetVisMCTruthTrack ( )
inline

Definition at line 263 of file BesView.h.

263{ return fStatusCurrent->fMCTruthTrack; }
Bool_t fMCTruthTrack
visibility flag for Ext Tracks
Definition BesStatus.h:128

Referenced by BesEvent::DrawMcParticles(), and BesClient::UpdateStatus().

◆ GetVisMdcGlobal()

Bool_t BesView::GetVisMdcGlobal ( )
inline

Definition at line 131 of file BesView.h.

131{ return fStatusCurrent->fMdcGlobal; }
Bool_t fMdcGlobal
Definition BesStatus.h:42

Referenced by MdcROOTGeo::Draw(), MdcROOTGeo::SetVisMdcDetector(), and BesClient::UpdateStatus().

◆ GetVisMdcHits()

Bool_t BesView::GetVisMdcHits ( )
inline

Definition at line 215 of file BesView.h.

215{ return fStatusCurrent->fMdcHits; }
Bool_t fMdcHits
visibility flag for global Mdc Hits
Definition BesStatus.h:92

Referenced by MdcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), and BesClient::UpdateStatus().

◆ GetVisMdcHitsGlobal()

Bool_t BesView::GetVisMdcHitsGlobal ( )
inline

Definition at line 214 of file BesView.h.

214{ return fStatusCurrent->fMdcHitsGlobal; }
Bool_t fMdcHitsGlobal
Definition BesStatus.h:91

Referenced by MdcROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), MdcROOTGeo::SetVisMdcHits(), and BesClient::UpdateStatus().

◆ GetVisMdcTubes()

Bool_t BesView::GetVisMdcTubes ( )
inline

Definition at line 132 of file BesView.h.

132{ return fStatusCurrent->fMdcTubes; }
Bool_t fMdcTubes
visibility flag for global Mdc
Definition BesStatus.h:43

Referenced by MdcROOTGeo::Draw(), MdcROOTGeo::DrawHits(), and BesClient::UpdateStatus().

◆ GetVisMdcWires()

Bool_t BesView::GetVisMdcWires ( )
inline

Definition at line 133 of file BesView.h.

133{ return fStatusCurrent->fMdcWires; }
Bool_t fMdcWires
visibility flag for Mdc main tubes
Definition BesStatus.h:44

Referenced by MdcROOTGeo::Draw(), Mdc2DWire::ExecuteEvent(), and BesClient::UpdateStatus().

◆ GetVisMucBarrel()

Bool_t BesView::GetVisMucBarrel ( )
inline

Definition at line 168 of file BesView.h.

168{ return fStatusCurrent->fMucBarrel; }
Bool_t fMucBarrel
visivility flag for Muc east EC
Definition BesStatus.h:65

Referenced by MucROOTGeo::Draw(), MucROOTGeo::SetVisMucDetector(), and BesClient::UpdateStatus().

◆ GetVisMucEast()

Bool_t BesView::GetVisMucEast ( )
inline

Definition at line 167 of file BesView.h.

167{ return fStatusCurrent->fMucEast; }
Bool_t fMucEast
visivility flag for global Muc
Definition BesStatus.h:64

Referenced by MucROOTGeo::Draw(), MucROOTGeo::SetVisMucDetector(), and BesClient::UpdateStatus().

◆ GetVisMucGlobal()

Bool_t BesView::GetVisMucGlobal ( )
inline

Definition at line 166 of file BesView.h.

166{ return fStatusCurrent->fMucGlobal; }
Bool_t fMucGlobal
visivility flag for Emc side
Definition BesStatus.h:63

Referenced by MucROOTGeo::Draw(), MucROOTGeo::SetVisMucDetector(), and BesClient::UpdateStatus().

◆ GetVisMucHitsBarrel()

Bool_t BesView::GetVisMucHitsBarrel ( )
inline

Definition at line 247 of file BesView.h.

247{ return fStatusCurrent->fMucHitsBarrel; }
Bool_t fMucHitsBarrel
visibility flag for Muc Hits East
Definition BesStatus.h:113

Referenced by MucROOTGeo::DrawHits(), Muc2DStrip::Paint(), MucROOTGeo::SetVisMucHits(), and BesClient::UpdateStatus().

◆ GetVisMucHitsEast()

Bool_t BesView::GetVisMucHitsEast ( )
inline

Definition at line 246 of file BesView.h.

246{ return fStatusCurrent->fMucHitsEast; }
Bool_t fMucHitsEast
visibility flag for global Muc Hits
Definition BesStatus.h:112

Referenced by MucROOTGeo::DrawHits(), Muc2DStrip::Paint(), MucROOTGeo::SetVisMucHits(), and BesClient::UpdateStatus().

◆ GetVisMucHitsGlobal()

Bool_t BesView::GetVisMucHitsGlobal ( )
inline

Definition at line 245 of file BesView.h.

245{ return fStatusCurrent->fMucHitsGlobal; }
Bool_t fMucHitsGlobal
visibility flag for Emc Hits Side
Definition BesStatus.h:111

Referenced by Muc2DStrip::DistancetoPrimitive(), MucROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Muc2DStrip::Paint(), MucROOTGeo::SetVisMucHits(), and BesClient::UpdateStatus().

◆ GetVisMucHitsWest()

Bool_t BesView::GetVisMucHitsWest ( )
inline

Definition at line 248 of file BesView.h.

248{ return fStatusCurrent->fMucHitsWest; }
Bool_t fMucHitsWest
visibility flag for Muc Hits Barrel
Definition BesStatus.h:114

Referenced by MucROOTGeo::DrawHits(), Muc2DStrip::Paint(), MucROOTGeo::SetVisMucHits(), and BesClient::UpdateStatus().

◆ GetVisMucStrips()

Bool_t BesView::GetVisMucStrips ( )
inline

Definition at line 170 of file BesView.h.

170{ return fStatusCurrent->fMucStrips; }
Bool_t fMucStrips
visivility flag for Muc west EC
Definition BesStatus.h:67

Referenced by Muc2DStrip::DistancetoPrimitive(), Muc2DStrip::Paint(), and BesClient::UpdateStatus().

◆ GetVisMucWest()

Bool_t BesView::GetVisMucWest ( )
inline

Definition at line 169 of file BesView.h.

169{ return fStatusCurrent->fMucWest; }
Bool_t fMucWest
visivility flag for Muc barrel
Definition BesStatus.h:66

Referenced by MucROOTGeo::Draw(), MucROOTGeo::SetVisMucDetector(), and BesClient::UpdateStatus().

◆ GetVisTofBarrel()

Bool_t BesView::GetVisTofBarrel ( )
inline

Definition at line 142 of file BesView.h.

142{ return fStatusCurrent->fTofBarrel; }
Bool_t fTofBarrel
visibility flag for Tof east EC
Definition BesStatus.h:50

Referenced by TofROOTGeo::Draw(), TofROOTGeo::SetVisTofDetector(), and BesClient::UpdateStatus().

◆ GetVisTofEast()

Bool_t BesView::GetVisTofEast ( )
inline

Definition at line 141 of file BesView.h.

141{ return fStatusCurrent->fTofEast; }
Bool_t fTofEast
visibility flag for global Tof
Definition BesStatus.h:49

Referenced by TofROOTGeo::Draw(), TofROOTGeo::SetVisTofDetector(), and BesClient::UpdateStatus().

◆ GetVisTofGlobal()

Bool_t BesView::GetVisTofGlobal ( )
inline

Definition at line 140 of file BesView.h.

140{ return fStatusCurrent->fTofGlobal; }
Bool_t fTofGlobal
visibility flag for Mdc wires
Definition BesStatus.h:48

Referenced by TofROOTGeo::Draw(), TofROOTGeo::SetVisTofDetector(), and BesClient::UpdateStatus().

◆ GetVisTofHitsBarrel()

Bool_t BesView::GetVisTofHitsBarrel ( )
inline

Definition at line 223 of file BesView.h.

223{ return fStatusCurrent->fTofHitsBarrel; }
Bool_t fTofHitsBarrel
visibility flag for Tof Hits East
Definition BesStatus.h:98

Referenced by TofROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Tof2DScin::Paint(), TofROOTGeo::SetVisTofHits(), and BesClient::UpdateStatus().

◆ GetVisTofHitsEast()

Bool_t BesView::GetVisTofHitsEast ( )
inline

Definition at line 222 of file BesView.h.

222{ return fStatusCurrent->fTofHitsEast; }
Bool_t fTofHitsEast
visibility flag for global Tof Hits
Definition BesStatus.h:97

Referenced by TofROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Tof2DScin::Paint(), TofROOTGeo::SetVisTofHits(), and BesClient::UpdateStatus().

◆ GetVisTofHitsGlobal()

Bool_t BesView::GetVisTofHitsGlobal ( )
inline

Definition at line 221 of file BesView.h.

221{ return fStatusCurrent->fTofHitsGlobal; }
Bool_t fTofHitsGlobal
visibility flag for Mdc Hits
Definition BesStatus.h:96

Referenced by TofROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Tof2DScin::Paint(), TofROOTGeo::SetVisTofHits(), and BesClient::UpdateStatus().

◆ GetVisTofHitsWest()

Bool_t BesView::GetVisTofHitsWest ( )
inline

Definition at line 224 of file BesView.h.

224{ return fStatusCurrent->fTofHitsWest; }
Bool_t fTofHitsWest
visibility flag for Tof Hits Barrel
Definition BesStatus.h:99

Referenced by TofROOTGeo::DrawHits(), BesGeoTrack::ExecuteEvent(), Tof2DScin::Paint(), TofROOTGeo::SetVisTofHits(), and BesClient::UpdateStatus().

◆ GetVisTofWest()

Bool_t BesView::GetVisTofWest ( )
inline

Definition at line 143 of file BesView.h.

143{ return fStatusCurrent->fTofWest; }
Bool_t fTofWest
visibility flag for Tof barrel
Definition BesStatus.h:51

Referenced by TofROOTGeo::Draw(), TofROOTGeo::SetVisTofDetector(), and BesClient::UpdateStatus().

◆ GetVisTracksEmc()

Bool_t BesView::GetVisTracksEmc ( )
inline

Definition at line 260 of file BesView.h.

260{ return fStatusCurrent->fTracksEmc; }
Bool_t fTracksEmc
visibility flag for Tof Tracks
Definition BesStatus.h:122

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksExt()

Bool_t BesView::GetVisTracksExt ( )
inline

Definition at line 262 of file BesView.h.

262{ return fStatusCurrent->fTracksExt; }
Bool_t fTracksExt
visibility flag for Muc Tracks
Definition BesStatus.h:124

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksGlobal()

Bool_t BesView::GetVisTracksGlobal ( )
inline

Definition at line 256 of file BesView.h.

256{ return fStatusCurrent->fTracksGlobal; }
Bool_t fTracksGlobal
visibility flag for Muc Hits West
Definition BesStatus.h:118

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksIdeal()

Bool_t BesView::GetVisTracksIdeal ( )
inline

Definition at line 258 of file BesView.h.

258{ return fStatusCurrent->fTracksIdeal; }
Bool_t fTracksIdeal
visibility flag for Mdc Tracks
Definition BesStatus.h:120

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksMdc()

Bool_t BesView::GetVisTracksMdc ( )
inline

Definition at line 257 of file BesView.h.

257{ return fStatusCurrent->fTracksMdc; }
Bool_t fTracksMdc
visibility flag for global Tracks
Definition BesStatus.h:119

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksMuc()

Bool_t BesView::GetVisTracksMuc ( )
inline

Definition at line 261 of file BesView.h.

261{ return fStatusCurrent->fTracksMuc; }
Bool_t fTracksMuc
visibility flag for Emc Tracks
Definition BesStatus.h:123

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisTracksTof()

Bool_t BesView::GetVisTracksTof ( )
inline

Definition at line 259 of file BesView.h.

259{ return fStatusCurrent->fTracksTof; }
Bool_t fTracksTof
visibility flag for Ideal Tracks, added by wangll
Definition BesStatus.h:121

Referenced by BesEvent::DrawTracks(), and BesClient::UpdateStatus().

◆ GetVisZoom()

Float_t BesView::GetVisZoom ( )
inline

Definition at line 144 of file BesView.h.

144{ return fStatusCurrent->fZoom; }
Float_t fZoom
Definition BesStatus.h:140

◆ GetVisZRPlaneOnXY()

Bool_t BesView::GetVisZRPlaneOnXY ( )
inline

Definition at line 193 of file BesView.h.

193{ return fStatusCurrent->fZRPlaneOnXY; }
Bool_t fZRPlaneOnXY
visibility flag for beam pipe
Definition BesStatus.h:80

Referenced by BesGeometry::Draw2DXY(), and BesClient::UpdateStatus().

◆ GetZoomFactor()

virtual Double_t BesView::GetZoomFactor ( )
inlinevirtual

Definition at line 310 of file BesView.h.

310{ return fZoomFactor; }

◆ GetZoomRatio()

Double_t BesView::GetZoomRatio ( )
inline

Definition at line 73 of file BesView.h.

73{ return fExtentDefault/GetExtent(); }
Double_t GetExtent() const

Referenced by SetZoomRatio(), BesClient::UpdateBesInputFields(), ZoomIn(), and ZoomOut().

◆ Inspect()

virtual void BesView::Inspect ( )
inlinevirtual

Definition at line 303 of file BesView.h.

303{ BesTView::Inspect(); }

◆ Move()

void BesView::Move ( Int_t px,
Int_t py )

Definition at line 513 of file BesView.cxx.

513 {
514
515 /*
516 Double_t p[3], pw[3];
517 for (Int_t i = 0; i < 3; i++) {
518 pw[i] = 0.5*(fRmin[i]+fRmax[i]);
519 }
520 cout << "pw " << pw[0] << " " << pw[1] << " " << pw[2] << endl;
521 WCtoNDC(pw, p);
522 cout << "p " << p[0] << " " << p[1] << " " << p[2] << endl;
523
524 p[0] += (gPad->PixeltoX(0) - gPad->PixeltoX(px));
525 p[1] += (gPad->PixeltoY(0) - gPad->PixeltoY(py));
526 cout << "p " << p[0] << " " << p[1] << " " << p[2] << endl;
527 NDCtoWC(p, pw);
528 cout << "pw " << pw[0] << " " << pw[1] << " " << pw[2] << endl;
529
530 MoveFocus(&pw[0], fRmax[0]-fRmin[0], fRmax[1]-fRmin[1], fRmax[2]-fRmin[2]);
531 gPad->Modified();
532 gPad->Update();
533 */
534
535 //
536 // Move (px, py in pixel coordinates)
537 Double_t x1, y1, x2, y2, dx, dy, x, y, x0, y0;
538 x1 = gPad->GetX1();
539 y1 = gPad->GetY1();
540 x2 = gPad->GetX2();
541 y2 = gPad->GetY2();
542 x0 = gPad->PixeltoX(0);
543 y0 = gPad->PixeltoY(0);
544 x = gPad->PixeltoX(px);
545 y = gPad->PixeltoY(py);
546 dx = -(x - x0);
547 dy = -(y - y0);
548
549 gPad->Range(x1+dx, y1+dy, x2+dx, y2+dy);
550 gPad->Modified();
551
552 //Long Peixun's update: Set view center
553 ViewCenter[0] = (x1 + x2) / 2 + dx;
554 ViewCenter[1] = (y1 + y2) / 2 + dy;
555}

Referenced by BesClient::ExecuteEvent(), and BesClient::HandleButtons().

◆ NDCtoWC() [1/2]

void BesView::NDCtoWC ( const Double_t * pn,
Double_t * pw )
virtual

Reimplemented from BesTView.

Definition at line 922 of file BesView.cxx.

922 {
923 //
924 // Transform back from NDCs
925 Double_t p[3];
926 p[0] = pn[0];
927 p[1] = pn[1];
928 p[2] = pn[2];
929
930 if ( fStatusCurrent->fFishEye == kTRUE ) {
931 Double_t r;
932 if ( fViewType & kZRView ) {
933 Double_t pvWC[3], pvNDC[3];
934 pvWC[0] = +4;
935 pvWC[1] = 0;
936 pvWC[2] = 0;
937 BesTView::WCtoNDC(pvWC, pvNDC);
938 p[0] = TMath::Sign((pn[0] - pvNDC[0])*(pn[0] - pvNDC[0]),
939 pn[0] - pvNDC[0]) + pvNDC[0];
940 p[1] = TMath::Sign((pn[1] - pvNDC[1])*(pn[1] - pvNDC[1]),
941 pn[1] - pvNDC[1]) + pvNDC[1];
942 } else {
943 r = TMath::Sqrt(TMath::Power(p[0],2)
944 +TMath::Power(p[1],2));
945 p[0] *= r;
946 p[1] *= r;
947 }
948 }
949 BesTView::NDCtoWC(p, pw);
950}
virtual void WCtoNDC(const Float_t *pw, Float_t *pn)
virtual void NDCtoWC(const Float_t *pn, Float_t *pw)

◆ NDCtoWC() [2/2]

void BesView::NDCtoWC ( const Float_t * pn,
Float_t * pw )
virtual

Reimplemented from BesTView.

Definition at line 890 of file BesView.cxx.

890 {
891 //
892 // Transform back from NDCs
893 Float_t p[3];
894 p[0] = pn[0];
895 p[1] = pn[1];
896 p[2] = pn[2];
897
898 if ( fStatusCurrent->fFishEye == kTRUE ) {
899 Float_t r;
900 if ( fViewType & kZRView ) {
901 Float_t pvWC[3], pvNDC[3];
902 pvWC[0] = +4;
903 pvWC[1] = 0;
904 pvWC[2] = 0;
905 BesTView::WCtoNDC(pvWC, pvNDC);
906 p[0] = TMath::Sign((pn[0] - pvNDC[0])*(pn[0] - pvNDC[0]),
907 pn[0] - pvNDC[0]) + pvNDC[0];
908 p[1] = TMath::Sign((pn[1] - pvNDC[1])*(pn[1] - pvNDC[1]),
909 pn[1] - pvNDC[1]) + pvNDC[1];
910 } else {
911 r = TMath::Sqrt(TMath::Power(p[0],2)
912 +TMath::Power(p[1],2));
913 p[0] *= r;
914 p[1] *= r;
915 }
916 }
917 BesTView::NDCtoWC(p, pw);
918}

Referenced by BesCircle2D::DistancetoPrimitive(), and GetObjectInfo().

◆ PrintCurrent()

void BesView::PrintCurrent ( )
inline

Definition at line 287 of file BesView.h.

287{ fStatusCurrent->Print(); }

◆ Refresh()

void BesView::Refresh ( )

Definition at line 1015 of file BesView.cxx.

1016{
1017 //Reset status instances of views
1018 fStatus3D->Default(k3DView);
1019 fStatusXY->Default(kXYView);
1020 fStatusZR->Default(kZRView);
1021 fStatusCgemUF[0]->Default(kCgemUFView0);
1022 fStatusCgemUF[1]->Default(kCgemUFView1);
1023 fStatusCgemUF[2]->Default(kCgemUFView2);
1024
1025 //Refresh status instances of views
1026 switch (fViewType)
1027 {
1028 case k3DView:
1029 fStatus3D->Transfer(fStatusCurrent, 1);
1030 break;
1031 case kXYView:
1032 fStatusXY->Transfer(fStatusCurrent, 1);
1033 break;
1034 case kZRView:
1035 fStatusZR->Transfer(fStatusCurrent, 1);
1036 break;
1037 case kCgemUFView0:
1038 fStatusCgemUF[0]->Transfer(fStatusCurrent, 1);
1039 break;
1040 case kCgemUFView1:
1041 fStatusCgemUF[1]->Transfer(fStatusCurrent, 1);
1042 break;
1043 case kCgemUFView2:
1044 fStatusCgemUF[2]->Transfer(fStatusCurrent, 1);
1045 break;
1046 }
1047
1048 this->UpdateView(1);
1049 gPad->Update();
1050}
void Transfer(BesStatus *right, Bool_t set)
void Default(EBESViewType type)
Definition BesStatus.cxx:39
virtual void UpdateView(Bool_t resetview=kFALSE)
Definition BesView.cxx:753

Referenced by EmcROOTGeo::Align(), and BesVisDisplay::Refresh().

◆ Reset()

void BesView::Reset ( )

Definition at line 990 of file BesView.cxx.

990 {
991 //
992 // reset view to default values
993
994 // reset status instances of views
995 fStatus3D->Default(k3DView);
996 fStatusXY->Default(kXYView);
997 fStatusZR->Default(kZRView);
998 //Long Peixun's update: Add CGEM unfolded view
999 fStatusCgemUF[0]->Default(kCgemUFView0);
1000 fStatusCgemUF[1]->Default(kCgemUFView1);
1001 fStatusCgemUF[2]->Default(kCgemUFView2);
1002 fZoomFactor = 1.2;
1003
1004 // reset current status instance tp fViewType
1005 fStatusCurrent->Default(fViewType);
1006
1007 // reset phirange
1008 // this->SetPhiRange(0,180);
1009 this->UpdateView(1);
1010 gPad->Update();
1011}

Referenced by BesClient::HandleButtons(), and BesVisDisplay::Reset().

◆ SetDrawOption()

virtual void BesView::SetDrawOption ( Option_t * option)
inlinevirtual

Definition at line 306 of file BesView.h.

306{ BesTView::SetDrawOption(option); }

◆ SetFishEye()

void BesView::SetFishEye ( Bool_t input = 0)
inline

Definition at line 277 of file BesView.h.

277 {
278 if ( fViewType & k3DView ) {
279 fFishEye = 0;
280 fStatusCurrent->fFishEye = 0;
281 } else {
282 fFishEye = input;
283 fStatusCurrent->fFishEye = input;
284 }
285 } // *TOGGLE*

Referenced by BesClient::HandleButtons(), and BesClient::UpdateStatus().

◆ SetLineAttributes()

virtual void BesView::SetLineAttributes ( )
inlinevirtual

Definition at line 307 of file BesView.h.

307{ BesTView::SetLineAttributes(); }

◆ SetMarkerSize()

void BesView::SetMarkerSize ( Float_t size)
inline

Definition at line 117 of file BesView.h.

117{ fMarkerSize = size; }

◆ SetPhiRange()

void BesView::SetPhiRange ( Float_t PhiMin = 0,
Float_t PhiMax = 180 )

Definition at line 737 of file BesView.cxx.

737 {
738 //
739 // Set phi range for ZR view
740 if ( gDebug ) cout << "BesView::SetPhiRange called" << endl;
741
742 fStatusCurrent->fPhiRangeMin = PhiMin;
743 fStatusCurrent->fPhiRangeMax = PhiMax;
744
745 // Update view
746 if ( !gBesGeometry ) return;
747 //gEvent->AddBACPadTowerZR();
748 UpdateView(0);
749}
R__EXTERN BesGeometry * gBesGeometry
#define PhiMax
#define PhiMin
Float_t fPhiRangeMax
Definition BesStatus.h:137

◆ SetViewType()

void BesView::SetViewType ( EBESViewType ViewType,
Bool_t resetview = kFALSE )
virtual

Definition at line 109 of file BesView.cxx.

109 {
110 //
111 // Set type of view
112
113 // check the state of the component before change and copy current status to respective status
114 if (fViewType & k3DView) { fStatus3D->Transfer(fStatusCurrent, 0); }
115 else if (fViewType & kXYView) { fStatusXY->Transfer(fStatusCurrent, 0); }
116 else if (fViewType & kZRView) { fStatusZR->Transfer(fStatusCurrent, 0); }
117 //Long Peixun's update: for CGEM UF view
118 else if (fViewType & kCgemUFView0) { fStatusCgemUF[0]->Transfer(fStatusCurrent, 0); }
119 else if (fViewType & kCgemUFView1) { fStatusCgemUF[1]->Transfer(fStatusCurrent, 0); }
120 else if (fViewType & kCgemUFView2) { fStatusCgemUF[2]->Transfer(fStatusCurrent, 0); }
121
122 fViewType = ViewType;
123 ClearPad();
124
125 // Set view direction properly
126 Int_t iret;
127 if ( fViewType & k3DView ) {
128 //cout << "SetViewType 3D" << endl;
129 //
130 // 3D view
131
132 // remember my previous state, set parallel first anyway, then choose perspective or not
133 Int_t iPerspective = 0;
134
135 if (IsPerspective()) iPerspective = 1;
136
137 // copy 3D status to current status
138 fStatusCurrent->Transfer(fStatus3D,1);
139
140 // Geometry exist ?
141 if ( !gBesGeometry ) return;
142
143 // set view
144 if ( resetview ) {
145 //SetView(0, 90, 270, iret);
146 this->Front();
147 this->Center();
148
149 DefaultRange();
150 //for (int i = 0; i < 2; i++) this->ZoomView(gPad, fZoomFactor);
151 //Long Peixun's update: Using SetZoomRatio instead of ZoomView
152 SetZoomRatio(fStatus3D->fZoom);
153
154 //Long Peixun's update: don't reset marker size
155 //fMarkerSize = 0.1;
156 }
157
158 // Draw geometry
159
160 //cout << "is there any problem after update from root's version 4.03 to 4.04" << endl; //Long Peixun remove
161 gBesGeometry->Draw("3D,SAME");
162 //this->SetParralel(); //comment out 2007.5.1 try to use ROOT-5.10.00
163 this->SetParallel();
164 //old version 4.0.3 have a spell mistake BesTView::SetParralel()=>SetParallel()
165 //changed by tianhl at Mon Aug 20 2007
166 if (iPerspective == 1) this->SetPerspective();
167
168 // Draw tracks
169 if ( gEvent )
170 {
171 gEvent->DrawCgem3DHits(""); //Long Peixun's update: CGEM hits should be drawn here
172 gEvent->DrawTracks("");
174 }
175 //else cout << "3D gEvent does not exist " << endl;
176
177 } else if ( fViewType & kXYView ) {
178 //cout << "SetViewType XY" << endl;
179 //
180 // XY view
181 // =======
182
183 // copy XY status to current status
184 fStatusCurrent->Transfer(fStatusXY,1);
185
186 // Geometry exist ?
187 if ( !gBesGeometry ) return;
188
189 // set view
190 if ( resetview ) {
191 SetView(0, 0, 270, iret);
192 this->Center();
193
194 DefaultRange();
195 //DefaultRange(); //Long Peixun's update: Remove redundant DefaultRange()
196 //for (int i = 0; i < 2; i++) this->ZoomView(gPad, fZoomFactor);
197 //Long Peixun's update: Using SetZoomRatio instead of ZoomView
198 SetZoomRatio(fStatusXY->fZoom);
199
200 //Long Peixun's update: don't reset marker size
201 //fMarkerSize = 0.1;
202
203 }
204
205 /*
206 // Draw event
207 if ( gEvent ) gEvent->SetHits("XY");
208 else cout << "XY : gEvent does not exist " << endl;
209 */
210
211 // Draw geometry
212 gBesGeometry->Draw("XY,SAME");
213
214 // Draw 2D hits and tracks
215 if ( gEvent ) {
216 gEvent->DrawHits("");
217 gEvent->DrawTracks("");
220 }
221 //else cout << "XY : gEvent does not exist " << endl;
222
223 } else if ( fViewType & kZRView ) {
224 //cout << "SetViewType ZR" << endl;
225 //
226 // ZR view
227 // =======
228
229 // copy ZR status to current status
230 fStatusCurrent->Transfer(fStatusZR,1);
231
232 // Geometry exist ?
233 if ( !gBesGeometry ) return;
234
235 // set view
236 if ( resetview ) {
237 SetView(180,90,90,iret);
238 this->Center();
239
240 DefaultRange();
241 //DefaultRange(); //Long Peixun's update: Remove redundant DefaultRange()
242 //for (int i = 0; i < 2; i++) this->ZoomView(gPad, fZoomFactor);
243 //Long Peixun's update: Using SetZoomRatio instead of ZoomView
244 SetZoomRatio(fStatusZR->fZoom);
245
246 //Long Peixun's update: don't reset marker size
247 //fMarkerSize = 0.1;
248
249 }
250
251 /*
252 // Draw event
253 if ( gEvent ) gEvent->SetHits("ZR");
254 else cout << "ZR : gEvent does not exist " << endl;
255 */
256
257 // Draw geometry
258 gBesGeometry->Draw("ZR,SAME");
259
260 // Draw hits and tracks
261 if ( gEvent ) {
262 gEvent->DrawHits("");
263 gEvent->DrawTracks("");
266 }
267 //else cout << "ZR : gEvent does not exist " << endl;
268
269 }
270
271 //Long Peixun's update: Cgem UF view for each layer
272 else if (fViewType & kCgemUFView0)
273 {
274 fStatusCurrent->Transfer(fStatusCgemUF[0], 1);
275 if ( !gBesGeometry ) return;
276 if ( resetview )
277 {
278 SetView(90, 0, 270, iret);
279 Center();
280 DefaultRange();
281 SetZoomRatio(fStatusCgemUF[0]->fZoom);
282 }
283
284 //Draw hits function
286 if (gEvent)
287 {
290 }
291 }
292 else if (fViewType & kCgemUFView1)
293 {
294 fStatusCurrent->Transfer(fStatusCgemUF[1], 1);
295 if ( !gBesGeometry ) return;
296 if ( resetview )
297 {
298 SetView(90, 0, 270, iret);
299 Center();
300 DefaultRange();
301 SetZoomRatio(fStatusCgemUF[1]->fZoom);
302 }
303
304 //Draw hits function
306 if (gEvent)
307 {
310 }
311 }
312 else if (fViewType & kCgemUFView2)
313 {
314 fStatusCurrent->Transfer(fStatusCgemUF[2], 1);
315 if ( !gBesGeometry ) return;
316 if ( resetview )
317 {
318 SetView(90, 0, 270, iret);
319 Center();
320 DefaultRange();
321 SetZoomRatio(fStatusCgemUF[2]->fZoom);
322 }
323
324 //Draw hits function
326 if (gEvent)
327 {
330 }
331 }
332
333 // Draw label
334 DrawLabel();
335}
R__EXTERN BesEvent * gEvent
Definition BesEvent.h:318
virtual void DrawCgem3DHits(Option_t *option)
virtual void DrawCgemUFHits(Option_t *option)
virtual void DrawCgemUFClusters(int layer, Option_t *option)
virtual void DrawCgemClusters(Option_t *option)
virtual void DrawMcParticles(Option_t *option)
virtual void DrawHits(Option_t *option)
virtual void DrawTracks(Option_t *option)
virtual void DrawCgemUF(int layer)
virtual void Draw(Option_t *option="3D")
Bool_t IsPerspective() const
Definition BesTView.h:113
virtual void SetParallel()
virtual void SetView(Double_t longitude, Double_t latitude, Double_t psi, Int_t &irep)
virtual void SetPerspective()
virtual void ClearPad()
Definition BesView.cxx:439
void Center()
Definition BesView.cxx:559
virtual void DefaultRange()
Definition BesView.cxx:101
void SetZoomRatio(Double_t ratio)
Definition BesView.cxx:578
virtual void DrawLabel()
Definition BesView.cxx:773

Referenced by Side3D(), UpdateView(), View3D(), ViewCgemUF(), ViewXY(), and ViewZR().

◆ SetViewTypeBare()

void BesView::SetViewTypeBare ( EBESViewType ViewType,
Bool_t resetview = kFALSE )
virtual

Definition at line 337 of file BesView.cxx.

337 {
338 /*
339 //
340 // Set type of view
341
342 cout << "setviewtypeBare: start..." << endl;
343 // check the state of the component before change and copy current status to respective status
344 if ( fViewType & k3DView ){
345
346 fStatus3D->Transfer(fStatusCurrent,0);
347
348 } else if ( fViewType & kXYView ) {
349
350 fStatusXY->Transfer(fStatusCurrent,0);
351
352 } else if ( fViewType & kZRView ) {
353
354
355 fStatusZR->Transfer(fStatusCurrent,0);
356
357 }
358
359 fViewType = ViewType;
360 ClearPad();
361
362 // Set view direction properly
363 Int_t iret;
364 cout << "fViewType=" << fViewType << endl;
365 if ( fViewType & k3DView ) {
366 //
367 // 3D view
368
369 // copy 3D status to current status
370 fStatusCurrent->Transfer(fStatus3D,1);
371 // Geometry exist ?
372 if ( !gGeometry ) return;
373
374 // set view
375 if ( resetview ) {
376 SetView(0, 90, 270, iret);
377 SetRange(-600,-600,-400,600,600,800);
378
379 // reset marker size
380 fMarkerSize = 0.1;
381
382 }
383
384 } else if ( fViewType & kXYView ) {
385 //
386 // XY view
387 // =======
388
389 // copy XY status to current status
390 fStatusCurrent->Transfer(fStatusXY,1);
391
392 // Geometry exist ?
393 if ( !gGeometry ) return;
394
395 // set view
396 if ( resetview ) {
397 SetView(270, 0, 0, iret);
398 // SetRange(-200,-200,-200,200,200,200);
399 SetRange(-310,-310,-310,310,310,310);
400 // reset marker size
401 fMarkerSize = 0.1;
402
403 }
404
405 } else if ( fViewType & kZRView ) {
406
407 //
408 // ZR view
409 // =======
410
411 // copy ZR status to current status
412 cout << "fViewType & kZRView: before transfer..." << endl;
413 fStatusCurrent->Transfer(fStatusZR,1);
414 cout << "fViewType & kZRView: after transfer..." << endl;
415
416 // Geometry exist ?
417 if ( !gGeometry ) return;
418
419 // set view
420 if ( resetview ) {
421 SetView(90, 180, 0, iret);
422 // SetRange(-130,-200,-200,270,200,200);
423 SetRange(-160,-400,-400,740,400,400);
424 // reset marker size
425 fMarkerSize = 0.1;
426
427 }
428
429 }
430
431 // Draw label
432 cout << "SetViewTypeBare: no drawlabel" << endl;
433 //DrawLabel();
434 */
435}

◆ SetVisAxis()

void BesView::SetVisAxis ( Bool_t input)
inline

Definition at line 198 of file BesView.h.

198{ fStatusCurrent->fAxis = input; }

Referenced by BesClient::HandleButtons(), BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisBeamPipe()

void BesView::SetVisBeamPipe ( Bool_t input)
inline

Definition at line 196 of file BesView.h.

196{ fStatusCurrent->fBeamPipe = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemGlobal()

void BesView::SetVisCgemGlobal ( Bool_t input)
inline

Definition at line 125 of file BesView.h.

125{ fStatusCurrent->fCgemGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemHitsClusters()

void BesView::SetVisCgemHitsClusters ( Bool_t input)
inline

Definition at line 210 of file BesView.h.

210{ fStatusCurrent->fCgemHitsClusters = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemHitsFiredHL()

void BesView::SetVisCgemHitsFiredHL ( Bool_t input)
inline

Definition at line 211 of file BesView.h.

211{ fStatusCurrent->fCgemHitsFiredHL = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemHitsGlobal()

void BesView::SetVisCgemHitsGlobal ( Bool_t input)
inline

Definition at line 207 of file BesView.h.

207{ fStatusCurrent->fCgemHitsGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemHitsVStrip()

void BesView::SetVisCgemHitsVStrip ( Bool_t input)
inline

Definition at line 209 of file BesView.h.

209{ fStatusCurrent->fCgemHitsVStrip = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemHitsXStrip()

void BesView::SetVisCgemHitsXStrip ( Bool_t input)
inline

Definition at line 208 of file BesView.h.

208{ fStatusCurrent->fCgemHitsXStrip = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemLayers()

void BesView::SetVisCgemLayers ( Bool_t input)
inline

Definition at line 126 of file BesView.h.

126{ fStatusCurrent->fCgemLayers = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemVStrips()

void BesView::SetVisCgemVStrips ( Bool_t input)
inline

Definition at line 128 of file BesView.h.

128{ fStatusCurrent->fCgemVStrips = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisCgemXStrips()

void BesView::SetVisCgemXStrips ( Bool_t input)
inline

Definition at line 127 of file BesView.h.

127{ fStatusCurrent->fCgemXStrips = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcBarrel()

void BesView::SetVisEmcBarrel ( Bool_t input)
inline

Definition at line 161 of file BesView.h.

161{ fStatusCurrent->fEmcBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcEast()

void BesView::SetVisEmcEast ( Bool_t input)
inline

Definition at line 160 of file BesView.h.

160{ fStatusCurrent->fEmcEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcGlobal()

void BesView::SetVisEmcGlobal ( Bool_t input)
inline

Definition at line 159 of file BesView.h.

159{ fStatusCurrent->fEmcGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcHitsBarrel()

void BesView::SetVisEmcHitsBarrel ( Bool_t input)
inline

Definition at line 240 of file BesView.h.

240{ fStatusCurrent->fEmcHitsBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcHitsEast()

void BesView::SetVisEmcHitsEast ( Bool_t input)
inline

Definition at line 239 of file BesView.h.

239{ fStatusCurrent->fEmcHitsEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcHitsGlobal()

void BesView::SetVisEmcHitsGlobal ( Bool_t input)
inline

Definition at line 238 of file BesView.h.

238{ fStatusCurrent->fEmcHitsGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcHitsSide()

void BesView::SetVisEmcHitsSide ( Bool_t input)
inline

Definition at line 242 of file BesView.h.

242{ fStatusCurrent->fEmcHitsSide = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcHitsWest()

void BesView::SetVisEmcHitsWest ( Bool_t input)
inline

Definition at line 241 of file BesView.h.

241{ fStatusCurrent->fEmcHitsWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcSide()

void BesView::SetVisEmcSide ( Bool_t input)
inline

Definition at line 163 of file BesView.h.

163{ fStatusCurrent->fEmcSide = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisEmcWest()

void BesView::SetVisEmcWest ( Bool_t input)
inline

Definition at line 162 of file BesView.h.

162{ fStatusCurrent->fEmcWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisFull3DCgem()

void BesView::SetVisFull3DCgem ( Bool_t input)
inline

Definition at line 185 of file BesView.h.

185{ fStatusCurrent->fFull3DCgem = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisFull3DEmc()

void BesView::SetVisFull3DEmc ( Bool_t input)
inline

Definition at line 188 of file BesView.h.

188{ fStatusCurrent->fFull3DEmc = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisFull3DMdc()

void BesView::SetVisFull3DMdc ( Bool_t input)
inline

Definition at line 186 of file BesView.h.

186{ fStatusCurrent->fFull3DMdc = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisFull3DMuc()

void BesView::SetVisFull3DMuc ( Bool_t input)
inline

Definition at line 189 of file BesView.h.

189{ fStatusCurrent->fFull3DMuc = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisFull3DTof()

void BesView::SetVisFull3DTof ( Bool_t input)
inline

Definition at line 187 of file BesView.h.

187{ fStatusCurrent->fFull3DTof = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisMCTruthTrack()

void BesView::SetVisMCTruthTrack ( Bool_t input)
inline

Definition at line 272 of file BesView.h.

272{ fStatusCurrent->fMCTruthTrack = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMdcGlobal()

void BesView::SetVisMdcGlobal ( Bool_t input)
inline

Definition at line 135 of file BesView.h.

135{ fStatusCurrent->fMdcGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMdcHits()

void BesView::SetVisMdcHits ( Bool_t input)
inline

Definition at line 218 of file BesView.h.

218{ fStatusCurrent->fMdcHits = input; }

Referenced by BesClient::HandleViewOptionMenu().

◆ SetVisMdcHitsGlobal()

void BesView::SetVisMdcHitsGlobal ( Bool_t input)
inline

Definition at line 217 of file BesView.h.

217{ fStatusCurrent->fMdcHitsGlobal = input; }

Referenced by BesClient::SetState().

◆ SetVisMdcTubes()

void BesView::SetVisMdcTubes ( Bool_t input)
inline

Definition at line 136 of file BesView.h.

136{ fStatusCurrent->fMdcTubes = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMdcWires()

void BesView::SetVisMdcWires ( Bool_t input)
inline

Definition at line 137 of file BesView.h.

137{ fStatusCurrent->fMdcWires = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucBarrel()

void BesView::SetVisMucBarrel ( Bool_t input)
inline

Definition at line 174 of file BesView.h.

174{ fStatusCurrent->fMucBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucEast()

void BesView::SetVisMucEast ( Bool_t input)
inline

Definition at line 173 of file BesView.h.

173{ fStatusCurrent->fMucEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucGlobal()

void BesView::SetVisMucGlobal ( Bool_t input)
inline

Definition at line 172 of file BesView.h.

172{ fStatusCurrent->fMucGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucHitsBarrel()

void BesView::SetVisMucHitsBarrel ( Bool_t input)
inline

Definition at line 252 of file BesView.h.

252{ fStatusCurrent->fMucHitsBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucHitsEast()

void BesView::SetVisMucHitsEast ( Bool_t input)
inline

Definition at line 251 of file BesView.h.

251{ fStatusCurrent->fMucHitsEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucHitsGlobal()

void BesView::SetVisMucHitsGlobal ( Bool_t input)
inline

Definition at line 250 of file BesView.h.

250{ fStatusCurrent->fMucHitsGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucHitsWest()

void BesView::SetVisMucHitsWest ( Bool_t input)
inline

Definition at line 253 of file BesView.h.

253{ fStatusCurrent->fMucHitsWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucStrips()

void BesView::SetVisMucStrips ( Bool_t input)
inline

Definition at line 176 of file BesView.h.

176{ fStatusCurrent->fMucStrips = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisMucWest()

void BesView::SetVisMucWest ( Bool_t input)
inline

Definition at line 175 of file BesView.h.

175{ fStatusCurrent->fMucWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofBarrel()

void BesView::SetVisTofBarrel ( Bool_t input)
inline

Definition at line 148 of file BesView.h.

148{ fStatusCurrent->fTofBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofEast()

void BesView::SetVisTofEast ( Bool_t input)
inline

Definition at line 147 of file BesView.h.

147{ fStatusCurrent->fTofEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofGlobal()

void BesView::SetVisTofGlobal ( Bool_t input)
inline

Definition at line 146 of file BesView.h.

146{ fStatusCurrent->fTofGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofHitsBarrel()

void BesView::SetVisTofHitsBarrel ( Bool_t input)
inline

Definition at line 228 of file BesView.h.

228{ fStatusCurrent->fTofHitsBarrel = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofHitsEast()

void BesView::SetVisTofHitsEast ( Bool_t input)
inline

Definition at line 227 of file BesView.h.

227{ fStatusCurrent->fTofHitsEast = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofHitsGlobal()

void BesView::SetVisTofHitsGlobal ( Bool_t input)
inline

Definition at line 226 of file BesView.h.

226{ fStatusCurrent->fTofHitsGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofHitsWest()

void BesView::SetVisTofHitsWest ( Bool_t input)
inline

Definition at line 229 of file BesView.h.

229{ fStatusCurrent->fTofHitsWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTofWest()

void BesView::SetVisTofWest ( Bool_t input)
inline

Definition at line 149 of file BesView.h.

149{ fStatusCurrent->fTofWest = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksEmc()

void BesView::SetVisTracksEmc ( Bool_t input)
inline

Definition at line 269 of file BesView.h.

269{ fStatusCurrent->fTracksEmc = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksExt()

void BesView::SetVisTracksExt ( Bool_t input)
inline

Definition at line 271 of file BesView.h.

271{ fStatusCurrent->fTracksExt = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksGlobal()

void BesView::SetVisTracksGlobal ( Bool_t input)
inline

Definition at line 265 of file BesView.h.

265{ fStatusCurrent->fTracksGlobal = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksIdeal()

void BesView::SetVisTracksIdeal ( Bool_t input)
inline

Definition at line 267 of file BesView.h.

267{ fStatusCurrent->fTracksIdeal = input; }

Referenced by BesClient::SetState().

◆ SetVisTracksMdc()

void BesView::SetVisTracksMdc ( Bool_t input)
inline

Definition at line 266 of file BesView.h.

266{ fStatusCurrent->fTracksMdc = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksMuc()

void BesView::SetVisTracksMuc ( Bool_t input)
inline

Definition at line 270 of file BesView.h.

270{ fStatusCurrent->fTracksMuc = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisTracksTof()

void BesView::SetVisTracksTof ( Bool_t input)
inline

Definition at line 268 of file BesView.h.

268{ fStatusCurrent->fTracksTof = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetVisZoom()

void BesView::SetVisZoom ( Float_t input)
inline

Definition at line 150 of file BesView.h.

150{ fStatusCurrent->fZoom = input; }

◆ SetVisZRPlaneOnXY()

void BesView::SetVisZRPlaneOnXY ( Bool_t input)
inline

Definition at line 197 of file BesView.h.

197{ fStatusCurrent->fZRPlaneOnXY = input; }

Referenced by BesClient::HandleViewOptionMenu(), and BesClient::SetState().

◆ SetZoomFactor()

virtual void BesView::SetZoomFactor ( Double_t factor)
inlinevirtual

Definition at line 309 of file BesView.h.

309{ fZoomFactor = factor; };

◆ SetZoomRatio()

void BesView::SetZoomRatio ( Double_t ratio)

Definition at line 578 of file BesView.cxx.

579{
580 //Long Peixun's update: Move pad and let Pad center be ViewCenter
581 Double_t dx = (ratio / GetZoomRatio() - 1) * ViewCenter[0];
582 Double_t dy = (ratio / GetZoomRatio() - 1) * ViewCenter[1];
583
584 DefaultRange();
585 fMarkerSize *= ratio; //Long Peixun's update: Should set marker size
586 ZoomView(gPad, ratio);
587
588 //Long Peixun's update: Move pad and let Pad center be ViewCenter
589 Double_t newx1 = gPad->GetX1() + dx;
590 Double_t newy1 = gPad->GetY1() + dy;
591 Double_t newx2 = gPad->GetX2() + dx;
592 Double_t newy2 = gPad->GetY2() + dy;
593 gPad->Range(newx1, newy1, newx2, newy2);
594 gPad->Modified();
595 ViewCenter[0] = (newx1 + newx2) / 2;
596 ViewCenter[1] = (newy1 + newy2) / 2;
597
598 //yzhang TEMP FIXME
599 fStatusCurrent->fZoom = ratio;
600 fStatusXY->fZoom = ratio;
601 fStatusZR->fZoom = ratio;
602 //Long Peixun's update: for CGEM unfolded view and 3D view
603 fStatus3D->fZoom = ratio;
604 fStatusCgemUF[0]->fZoom = ratio;
605 fStatusCgemUF[1]->fZoom = ratio;
606 fStatusCgemUF[2]->fZoom = ratio;
607}
virtual void ZoomView(TVirtualPad *pad=0, Double_t zoomFactor=1.25)
Double_t GetZoomRatio()
Definition BesView.h:73

Referenced by BesClient::ExecuteReturn(), SetViewType(), and BesClient::UpdateStatus().

◆ Side()

virtual void BesView::Side ( )
inlinevirtual

Reimplemented from BesTView.

Definition at line 292 of file BesView.h.

292{ BesTView::Side(); }
virtual void Side()
Definition BesTView.h:179

◆ Side3D()

void BesView::Side3D ( )

Definition at line 954 of file BesView.cxx.

954 {
955 //
956 // set side view for 3D
957
958 this->SetViewType(k3DView,1);
959 Int_t iret;
960 this->SetView(0,90,270,iret);
961}
virtual void SetViewType(EBESViewType ViewType, Bool_t resetview=kFALSE)
Definition BesView.cxx:109

◆ Top()

virtual void BesView::Top ( )
inlinevirtual

Reimplemented from BesTView.

Definition at line 293 of file BesView.h.

293{ BesTView::Front(); }
virtual void Front()
Definition BesTView.h:177

◆ Top3D()

void BesView::Top3D ( )
inline

Definition at line 106 of file BesView.h.

106 {
107 this->View3D();
108 Int_t iret;
109 this->SetView(-90,90,270,iret);
110
111 // this->Top();
112 } // *MENU*

◆ UpdateView()

◆ View3D()

void BesView::View3D ( )
inline

Definition at line 78 of file BesView.h.

78{ SetViewType(k3DView,1); } // *MENU*

Referenced by BesVisDisplay::Draw3D(), Front3D(), and Top3D().

◆ ViewCgemUF()

void BesView::ViewCgemUF ( int layer)
inline

Definition at line 82 of file BesView.h.

83 {
84 switch (layer)
85 {
86 case 0:
88 break;
89 case 1:
91 break;
92 case 2:
94 break;
95 }
96 }

Referenced by BesVisDisplay::DrawCgemUFLayer().

◆ ViewXY()

void BesView::ViewXY ( )
inline

Definition at line 79 of file BesView.h.

79{ SetViewType(kXYView,1); } // *MENU*

Referenced by BesVisDisplay::Draw2DXY().

◆ ViewZR()

void BesView::ViewZR ( )
inline

Definition at line 80 of file BesView.h.

80{ SetViewType(kZRView,1); } // *MENU*

Referenced by BesVisDisplay::Draw2DZR().

◆ WCtoNDC() [1/2]

void BesView::WCtoNDC ( const Double_t * pw,
Double_t * pn )
virtual

Reimplemented from BesTView.

Definition at line 857 of file BesView.cxx.

857 {
858 //
859 // Transform world coordinates to
860 // normalised device coordinates.
861 // This method was taken from BesTView
862 // and extended by FishEye view
863 BesTView::WCtoNDC(pw, pn);
864
865 if ( fStatusCurrent->fFishEye == kTRUE ) {
866 Double_t r, s;
867 if ( fViewType & kZRView ) {
868 Double_t pvWC[3], pvNDC[3];
869 pvWC[0] = +4;
870 pvWC[1] = 0;
871 pvWC[2] = 0;
872 BesTView::WCtoNDC(pvWC, pvNDC);
873 pn[0] = TMath::Sign(TMath::Sqrt(TMath::Abs(pn[0] - pvNDC[0])),
874 pn[0] - pvNDC[0]) + pvNDC[0];
875 pn[1] = TMath::Sign(TMath::Sqrt(TMath::Abs(pn[1] - pvNDC[1])),
876 pn[1] - pvNDC[1]) + pvNDC[1];
877 } else {
878
879 r = TMath::Sqrt(TMath::Power(pn[0],2)
880 +TMath::Power(pn[1],2));
881 s = TMath::Sqrt(r)/r;
882 pn[0] *= s;
883 pn[1] *= s;
884 }
885 }
886}
XmlRpcServer s

◆ WCtoNDC() [2/2]

void BesView::WCtoNDC ( const Float_t * pw,
Float_t * pn )
virtual

Reimplemented from BesTView.

Definition at line 824 of file BesView.cxx.

824 {
825 //
826 // Transform world coordinates to
827 // normalised device coordinates.
828 // This method was taken from BesTView
829 // and extended by FishEye view
830 BesTView::WCtoNDC(pw, pn);
831 //cout << "fFishEye " << fFishEye << endl;
832
833 if ( fStatusCurrent->fFishEye == kTRUE ) {
834 Float_t r, s;
835 if ( fViewType & kZRView ) {
836 Float_t pvWC[3], pvNDC[3];
837 pvWC[0] = +4;
838 pvWC[1] = 0;
839 pvWC[2] = 0;
840 BesTView::WCtoNDC(pvWC, pvNDC);
841 pn[0] = TMath::Sign(Double_t(TMath::Sqrt(TMath::Abs(pn[0] - pvNDC[0]))),
842 Double_t(pn[0] - pvNDC[0])) + pvNDC[0];
843 pn[1] = TMath::Sign(Double_t(TMath::Sqrt(TMath::Abs(pn[1] - pvNDC[1]))),
844 Double_t(pn[1] - pvNDC[1])) + pvNDC[1];
845 } else {
846 r = TMath::Sqrt(TMath::Power(pn[0],2)
847 +TMath::Power(pn[1],2));
848 s = TMath::Sqrt(r)/r;
849 pn[0] *= s;
850 pn[1] *= s;
851 }
852 }
853}

Referenced by BesPolygon2D::DistancetoPrimitive(), BesCircle2D::Paint(), BesMarker2D::Paint(), BesPolygon2D::Paint(), and Mdc2DWire::Paint().

◆ ZoomIn()

void BesView::ZoomIn ( )
virtual

Reimplemented from BesTView.

Definition at line 611 of file BesView.cxx.

611 {
612 //
613 // Magnify
614 //Long Peixun's update: Move pad and let Pad center be ViewCenter
615 Double_t dx = (fZoomFactor - 1) * ViewCenter[0];
616 Double_t dy = (fZoomFactor - 1) * ViewCenter[1];
617
618 fMarkerSize = fMarkerSize * fZoomFactor;
619 ZoomView(gPad, fZoomFactor); // dont use ZoomView as it is not base on center
620
621 fStatusCurrent->fZoom = GetZoomRatio();
622 fStatusXY->fZoom = GetZoomRatio();
623 fStatusZR->fZoom = GetZoomRatio();
624 //Long Peixun's update: for CGEM unfolded view and 3D view
625 fStatus3D->fZoom = GetZoomRatio();
626 fStatusCgemUF[0]->fZoom = GetZoomRatio();
627 fStatusCgemUF[1]->fZoom = GetZoomRatio();
628 fStatusCgemUF[2]->fZoom = GetZoomRatio();
629
630 //Long Peixun's update: Move pad and let Pad center be ViewCenter
631 Double_t newx1 = gPad->GetX1() + dx;
632 Double_t newy1 = gPad->GetY1() + dy;
633 Double_t newx2 = gPad->GetX2() + dx;
634 Double_t newy2 = gPad->GetY2() + dy;
635 gPad->Range(newx1, newy1, newx2, newy2);
636 gPad->Modified();
637 ViewCenter[0] = (newx1 + newx2) / 2;
638 ViewCenter[1] = (newy1 + newy2) / 2;
639
640 //Double_t scale[3], center[3];
641 //Int_t irep;
642 //FindScope(&scale[0], &center[0], irep);
643 //cout << "scale " << scale[0] << " " << scale[1] << " " << scale[2] << endl;
644 //cout << "center " << center[0] << " " << center[1] << " " << center[2] << endl;
645
646 //Double_t extent = GetExtent();
647 //cout << extent << endl;
648 //cout << GetZoomRatio() << endl;
649
650 /*
651 Double_t x1, y1, x2, y2;
652 x1 = gPad->GetX1();
653 y1 = gPad->GetY1();
654 x2 = gPad->GetX2();
655 y2 = gPad->GetY2();
656
657 Double_t dx = (gPad->GetX2() - gPad->GetX1())*(1-1/fZoomFactor);
658 Double_t dy = (gPad->GetY2() - gPad->GetY1())*(1-1/fZoomFactor);
659
660 gPad->Range(x1+dx/2, y1+dy/2, x2-dx/2, y2-dy/2);
661 gPad->Modified();
662 */
663}

Referenced by BesClient::ExecuteEvent(), and BesClient::HandleButtons().

◆ ZoomMove()

virtual void BesView::ZoomMove ( )
inlinevirtual

Reimplemented from BesTView.

Definition at line 295 of file BesView.h.

virtual void ZoomMove()
Definition BesTView.h:181

◆ ZoomOut()

void BesView::ZoomOut ( )
virtual

Reimplemented from BesTView.

Definition at line 667 of file BesView.cxx.

667 {
668 //
669 // Demagnify
670 //Long Peixun's update: Move pad and let Pad center be ViewCenter
671 Double_t dx = (1 / fZoomFactor - 1) * ViewCenter[0];
672 Double_t dy = (1 / fZoomFactor - 1) * ViewCenter[1];
673
674 fMarkerSize = fMarkerSize / fZoomFactor;
675 UnzoomView(gPad, fZoomFactor); // dont use ZoomView as it is not base on center
676
677 fStatusCurrent->fZoom = GetZoomRatio();
678 fStatusXY->fZoom = GetZoomRatio();
679 fStatusZR->fZoom = GetZoomRatio();
680 //Long Peixun's update: for CGEM unfolded view and 3D view
681 fStatus3D->fZoom = GetZoomRatio();
682 fStatusCgemUF[0]->fZoom = GetZoomRatio();
683 fStatusCgemUF[1]->fZoom = GetZoomRatio();
684 fStatusCgemUF[2]->fZoom = GetZoomRatio();
685
686 //Long Peixun's update: Move pad and let Pad center be ViewCenter
687 Double_t newx1 = gPad->GetX1() + dx;
688 Double_t newy1 = gPad->GetY1() + dy;
689 Double_t newx2 = gPad->GetX2() + dx;
690 Double_t newy2 = gPad->GetY2() + dy;
691 gPad->Range(newx1, newy1, newx2, newy2);
692 gPad->Modified();
693 ViewCenter[0] = (newx1 + newx2) / 2;
694 ViewCenter[1] = (newy1 + newy2) / 2;
695
696 //Double_t extent = GetExtent();
697 //cout << extent << endl;
698 //cout << GetZoomRatio() << endl;
699
700 /*
701 Double_t x1, y1, x2, y2;
702 x1 = gPad->GetX1();
703 y1 = gPad->GetY1();
704 x2 = gPad->GetX2();
705 y2 = gPad->GetY2();
706
707 Double_t dx = (gPad->GetX2() - gPad->GetX1())*(fZoomFactor-1);
708 Double_t dy = (gPad->GetY2() - gPad->GetY1())*(fZoomFactor-1);
709
710 gPad->Range(x1-dx/2, y1-dy/2, x2+dx/2, y2+dy/2);
711 gPad->Modified();
712 */
713}
virtual void UnzoomView(TVirtualPad *pad=0, Double_t unZoomFactor=1.25)

Referenced by BesClient::ExecuteEvent(), and BesClient::HandleButtons().


The documentation for this class was generated from the following files: