Logo ROOT  
Reference Guide
REveBox.hxx
Go to the documentation of this file.
1 // @(#)root/eve:$Id$
2 // Author: Matevz Tadel, 2010
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_REveBox
13 #define ROOT_REveBox
14 
15 #include "ROOT/REveShape.hxx"
16 
17 namespace ROOT {
18 namespace Experimental {
19 
20 //------------------------------------------------------------------------------
21 // REveBox
22 //------------------------------------------------------------------------------
23 
24 class REveBox : public REveShape,
25  public REveProjectable
26 {
27 private:
28  REveBox(const REveBox&) = delete;
29  REveBox& operator=(const REveBox&) = delete;
30 
31 protected:
33 
34 public:
35  REveBox(const char* n="REveBox", const char* t="");
36  virtual ~REveBox();
37 
38  void SetVertex(Int_t i, Float_t x, Float_t y, Float_t z);
39  void SetVertex(Int_t i, const Float_t* v);
40  void SetVertices(const Float_t* vs);
41 
42  const Float_t* GetVertex(Int_t i) const { return fVertices[i]; }
43 
44  // For TAttBBox:
45  virtual void ComputeBBox() override;
46 
47  Int_t WriteCoreJson(nlohmann::json &j, Int_t rnr_offset) override;
48  void BuildRenderData() override;
49  // Projectable:
50  virtual TClass* ProjectedClass(const REveProjection* p) const override;
51 };
52 
53 
54 //------------------------------------------------------------------------------
55 // REveBoxProjected
56 //------------------------------------------------------------------------------
57 
58 class REveBoxProjected : public REveShape,
59  public REveProjected
60 {
61 private:
64 
65 protected:
69 
71 
72  virtual void SetDepthLocal(Float_t d) override;
73 
74 public:
75  REveBoxProjected(const char* n="REveBoxProjected", const char* t="");
76  virtual ~REveBoxProjected();
77 
78  void BuildRenderData() override;
79  Int_t WriteCoreJson(nlohmann::json &j, Int_t rnr_offset) override;
80 
81  // For TAttBBox:
82  void ComputeBBox() override;
83 
86 
87  // Projected:
89  void UpdateProjection() override;
90 
91  REveElement* GetProjectedAsElement() override { return this; }
92 };
93 
94 } // namespace Experimental
95 } // namespace ROOT
96 #endif
ROOT::Experimental::REveProjected
Definition: REveProjectionBases.hxx:81
n
const Int_t n
Definition: legend1.C:16
ROOT::Experimental::REveBoxProjected::fDebugCornerPoints
Bool_t fDebugCornerPoints
Definition: REveBox.hxx:70
ROOT::Experimental::REveBoxProjected::fPoints
vVector2_t fPoints
Definition: REveBox.hxx:66
REveShape.hxx
nlohmann::json
basic_json<> json
Definition: REveElement.hxx:58
ROOT::Experimental::REveBoxProjected::SetDepthLocal
virtual void SetDepthLocal(Float_t d) override
This is virtual method from base-class REveProjected.
Definition: REveBox.cxx:170
ROOT::Experimental::REveBox
Definition: REveBox.hxx:26
ROOT::Experimental::REveBoxProjected::ComputeBBox
void ComputeBBox() override
Compute bounding-box, virtual from TAttBBox.
Definition: REveBox.cxx:160
ROOT::Experimental::REveBoxProjected::fDebugPoints
vVector2_t fDebugPoints
Definition: REveBox.hxx:68
ROOT::Experimental::REveBoxProjected::WriteCoreJson
Int_t WriteCoreJson(nlohmann::json &j, Int_t rnr_offset) override
Fill core part of JSON representation.
Definition: REveBox.cxx:278
ROOT::Experimental::REveBox::BuildRenderData
void BuildRenderData() override
Crates 3D point array for rendering.
Definition: REveBox.cxx:114
ROOT::Experimental::REveBox::fVertices
Float_t fVertices[8][3]
Definition: REveBox.hxx:32
Float_t
float Float_t
Definition: RtypesCore.h:57
ROOT::Experimental::REveBoxProjected::operator=
REveBoxProjected & operator=(const REveBoxProjected &)=delete
ROOT::Experimental::REveBox::ProjectedClass
virtual TClass * ProjectedClass(const REveProjection *p) const override
Virtual from REveProjectable, return REveBoxProjected class.
Definition: REveBox.cxx:128
ROOT::Experimental::REveBoxProjected::SetProjection
void SetProjection(REveProjectionManager *mng, REveProjectable *model) override
This is virtual method from base-class REveProjected.
Definition: REveBox.cxx:178
Int_t
int Int_t
Definition: RtypesCore.h:45
ROOT::Experimental::REveBoxProjected::fBreakIdx
Int_t fBreakIdx
Definition: REveBox.hxx:67
ROOT::Experimental::REveBoxProjected::~REveBoxProjected
virtual ~REveBoxProjected()
Destructor.
Definition: REveBox.cxx:153
x
Double_t x[n]
Definition: legend1.C:17
ROOT::Experimental::REveBox::operator=
REveBox & operator=(const REveBox &)=delete
ROOT::Experimental::REveElement
Definition: REveElement.hxx:80
v
@ v
Definition: rootcling_impl.cxx:3635
bool
ROOT::Experimental::REveProjection
REveProjection Base for specific classes that implement non-linear projections.
Definition: REveProjections.hxx:30
ROOT::Experimental::REveBoxProjected::UpdateProjection
void UpdateProjection() override
Re-project the box.
Definition: REveBox.cxx:191
ROOT::Experimental::REveBox::SetVertex
void SetVertex(Int_t i, Float_t x, Float_t y, Float_t z)
Set vertex 'i'.
Definition: REveBox.cxx:54
ROOT::Experimental::REveShape
Definition: REveShape.hxx:31
ROOT::Experimental::REveShape::vVector2_t
std::vector< REveVector2 > vVector2_t
Definition: REveShape.hxx:37
ROOT::Experimental::REveBoxProjected::GetDebugCornerPoints
Bool_t GetDebugCornerPoints()
Get state of fgDebugCornerPoints static.
Definition: REveBox.cxx:245
ROOT::Experimental::REveBoxProjected
Definition: REveBox.hxx:60
ROOT::Experimental::REveProjectable
Definition: REveProjectionBases.hxx:38
ROOT::Experimental::REveBox::REveBox
REveBox(const REveBox &)=delete
y
Double_t y[n]
Definition: legend1.C:17
ROOT::Experimental::REveBox::GetVertex
const Float_t * GetVertex(Int_t i) const
Definition: REveBox.hxx:42
ROOT::Experimental::REveBoxProjected::BuildRenderData
void BuildRenderData() override
Crates 3D point array for rendering.
Definition: REveBox.cxx:263
ROOT::Experimental::REveBoxProjected::SetDebugCornerPoints
void SetDebugCornerPoints(Bool_t d)
Set state of fgDebugCornerPoints static.
Definition: REveBox.cxx:255
TClass
TClass instances represent classes, structs and namespaces in the ROOT type system.
Definition: TClass.h:80
ROOT::Experimental::REveBoxProjected::REveBoxProjected
REveBoxProjected(const REveBoxProjected &)=delete
d
#define d(i)
Definition: RSha256.hxx:102
make_cnn_model.model
model
Definition: make_cnn_model.py:6
ROOT::Experimental::REveBoxProjected::GetProjectedAsElement
REveElement * GetProjectedAsElement() override
Returns this projected dynamic-casted to REveElement.
Definition: REveBox.hxx:91
ROOT::Experimental::REveProjectionManager
REveProjectionManager Manager class for steering of projections and managing projected objects.
Definition: REveProjectionManager.hxx:30
ROOT::Experimental::REveBox::WriteCoreJson
Int_t WriteCoreJson(nlohmann::json &j, Int_t rnr_offset) override
Fill core part of JSON representation.
Definition: REveBox.cxx:101
ROOT
VSD Structures.
Definition: StringConv.hxx:21
ROOT::Experimental::REveBox::ComputeBBox
virtual void ComputeBBox() override
Compute bounding-box of the data.
Definition: REveBox.cxx:86
ROOT::Experimental::REveBox::SetVertices
void SetVertices(const Float_t *vs)
Set vertices.
Definition: REveBox.cxx:76
ROOT::Experimental::REveBox::~REveBox
virtual ~REveBox()
Destructor.
Definition: REveBox.cxx:47
int