Geant4-11
Public Types | Public Member Functions | Protected Attributes | Private Attributes | Friends
G4VMarker Class Reference

#include <G4VMarker.hh>

Inheritance diagram for G4VMarker:
G4Visible G4Circle G4Polymarker G4Square G4Text

Public Types

enum  FillStyle { noFill , hashed , filled }
 
enum  SizeType { none , world , screen }
 

Public Member Functions

 G4VMarker ()
 
 G4VMarker (const G4Point3D &position)
 
 G4VMarker (const G4VMarker &)=default
 
 G4VMarker (G4VMarker &&)=default
 
FillStyle GetFillStyle () const
 
virtual const G4String & GetInfo () const
 
G4Point3D GetPosition () const
 
G4double GetScreenDiameter () const
 
G4double GetScreenRadius () const
 
G4double GetScreenSize () const
 
SizeType GetSizeType () const
 
const G4VisAttributes * GetVisAttributes () const
 
G4double GetWorldDiameter () const
 
G4double GetWorldRadius () const
 
G4double GetWorldSize () const
 
G4bool operator!= (const G4Visible &right) const
 
G4bool operator!= (const G4VMarker &) const
 
G4VMarker & operator= (const G4VMarker &)=default
 
G4VMarker & operator= (G4VMarker &&)=default
 
G4bool operator== (const G4VMarker &) const
 
void SetDiameter (SizeType, G4double)
 
void SetFillStyle (FillStyle)
 
virtual void SetInfo (const G4String &info)
 
void SetPosition (const G4Point3D &)
 
void SetRadius (SizeType, G4double)
 
void SetScreenDiameter (G4double)
 
void SetScreenRadius (G4double)
 
void SetScreenSize (G4double)
 
void SetSize (SizeType, G4double)
 
void SetVisAttributes (const G4VisAttributes &)
 
void SetVisAttributes (const G4VisAttributes *)
 
void SetWorldDiameter (G4double)
 
void SetWorldRadius (G4double)
 
void SetWorldSize (G4double)
 
virtual ~G4VMarker ()
 

Protected Attributes

G4bool fAllocatedVisAttributes
 
const G4VisAttributes * fpVisAttributes
 

Private Attributes

FillStyle fFillStyle
 
G4String fInfo
 
G4Point3D fPosition
 
G4double fScreenSize
 
G4double fWorldSize
 

Friends

std::ostream & operator<< (std::ostream &os, const G4VMarker &)
 

Detailed Description

Definition at line 90 of file G4VMarker.hh.

Member Enumeration Documentation

◆ FillStyle

Enumerator
noFill 
hashed 
filled 

Definition at line 96 of file G4VMarker.hh.

◆ SizeType

Enumerator
none 
world 
screen 

Definition at line 97 of file G4VMarker.hh.

Constructor & Destructor Documentation

◆ G4VMarker() [1/4]

G4VMarker::G4VMarker ( )

Definition at line 34 of file G4VMarker.cc.

34 :
36 fWorldSize (0.),
37 fScreenSize (0.),
39{
40 // fInfo: default initialisation.
41}
G4double fScreenSize
Definition: G4VMarker.hh:153
G4Point3D fPosition
Definition: G4VMarker.hh:151
FillStyle fFillStyle
Definition: G4VMarker.hh:154
G4double fWorldSize
Definition: G4VMarker.hh:152

◆ G4VMarker() [2/4]

G4VMarker::G4VMarker ( const G4VMarker &  )
default

◆ G4VMarker() [3/4]

G4VMarker::G4VMarker ( G4VMarker &&  )
default

◆ G4VMarker() [4/4]

G4VMarker::G4VMarker ( const G4Point3D &  position)

Definition at line 43 of file G4VMarker.cc.

43 :
44 fPosition (pos),
45 fWorldSize (0.),
46 fScreenSize (0.),
48 fInfo (G4String())
49{
50 // fInfo: default initialisation.
51}
static const G4double pos
G4String fInfo
Definition: G4VMarker.hh:157

◆ ~G4VMarker()

G4VMarker::~G4VMarker ( )
virtual

Definition at line 53 of file G4VMarker.cc.

53{}

Member Function Documentation

◆ GetFillStyle()

FillStyle G4VMarker::GetFillStyle ( ) const

◆ GetInfo()

virtual const G4String & G4VMarker::GetInfo ( ) const
virtual

◆ GetPosition()

G4Point3D G4VMarker::GetPosition ( ) const

◆ GetScreenDiameter()

G4double G4VMarker::GetScreenDiameter ( ) const

◆ GetScreenRadius()

G4double G4VMarker::GetScreenRadius ( ) const

◆ GetScreenSize()

G4double G4VMarker::GetScreenSize ( ) const

◆ GetSizeType()

G4VMarker::SizeType G4VMarker::GetSizeType ( ) const

Definition at line 87 of file G4VMarker.cc.

87 {
88 SizeType type = none;
89 if (fWorldSize) type = world;
90 else if (fScreenSize) type = screen;
91 return type;
92}

References fScreenSize, fWorldSize, none, screen, and world.

Referenced by G4Qt3DSceneHandler::AddPrimitive().

◆ GetVisAttributes()

const G4VisAttributes * G4Visible::GetVisAttributes ( ) const
inherited

◆ GetWorldDiameter()

G4double G4VMarker::GetWorldDiameter ( ) const

◆ GetWorldRadius()

G4double G4VMarker::GetWorldRadius ( ) const

◆ GetWorldSize()

G4double G4VMarker::GetWorldSize ( ) const

◆ operator!=() [1/2]

G4bool G4Visible::operator!= ( const G4Visible &  right) const
inherited

Definition at line 103 of file G4Visible.cc.

103 {
104 if (fpVisAttributes && right.fpVisAttributes)
105 return *fpVisAttributes != *right.fpVisAttributes;
106 else if (!fpVisAttributes && !right.fpVisAttributes) return false;
107 else return true;
108}
const G4VisAttributes * fpVisAttributes
Definition: G4Visible.hh:82

References G4Visible::fpVisAttributes.

◆ operator!=() [2/2]

G4bool G4VMarker::operator!= ( const G4VMarker &  mk) const

Definition at line 55 of file G4VMarker.cc.

55 {
56 return ( (G4Visible::operator != (mk)) ||
57 (fWorldSize != mk.fWorldSize) ||
58 (fScreenSize != mk.fScreenSize) ||
59 (fFillStyle != mk.fFillStyle) ||
60 !(fPosition == mk.fPosition) ||
61 (fInfo != mk.fInfo) );
62}

References fFillStyle, fInfo, fPosition, fScreenSize, and fWorldSize.

◆ operator=() [1/2]

G4VMarker & G4VMarker::operator= ( const G4VMarker &  )
default

◆ operator=() [2/2]

G4VMarker & G4VMarker::operator= ( G4VMarker &&  )
default

◆ operator==()

G4bool G4VMarker::operator== ( const G4VMarker &  ) const

◆ SetDiameter()

void G4VMarker::SetDiameter ( SizeType  ,
G4double   
)

◆ SetFillStyle()

void G4VMarker::SetFillStyle ( FillStyle  )

◆ SetInfo()

virtual void G4VMarker::SetInfo ( const G4String &  info)
virtual

◆ SetPosition()

void G4VMarker::SetPosition ( const G4Point3D &  )

◆ SetRadius()

void G4VMarker::SetRadius ( SizeType  ,
G4double   
)

◆ SetScreenDiameter()

void G4VMarker::SetScreenDiameter ( G4double  )

◆ SetScreenRadius()

void G4VMarker::SetScreenRadius ( G4double  )

◆ SetScreenSize()

void G4VMarker::SetScreenSize ( G4double  )

◆ SetSize()

void G4VMarker::SetSize ( SizeType  sizeType,
G4double  size 
)

◆ SetVisAttributes() [1/2]

void G4Visible::SetVisAttributes ( const G4VisAttributes &  VA)
inherited

Definition at line 85 of file G4Visible.cc.

85 {
86 // Allocate G4VisAttributes on the heap in case the user specifies a
87 // short-lived VA for a long-lived G4Visible. Flag so that it can
88 // be deleted in the destructor.
89 // First delete any G4VisAttributes already on the heap...
93}
G4bool fAllocatedVisAttributes
Definition: G4Visible.hh:83

References G4Visible::fAllocatedVisAttributes, and G4Visible::fpVisAttributes.

◆ SetVisAttributes() [2/2]

void G4Visible::SetVisAttributes ( const G4VisAttributes *  pVA)
inherited

Definition at line 96 of file G4Visible.cc.

96 {
97 // First delete any G4VisAttributes already on the heap...
99 fpVisAttributes = pVA;
101}

References G4Visible::fAllocatedVisAttributes, and G4Visible::fpVisAttributes.

Referenced by G4OpenGLSceneHandler::AddCompound(), G4Qt3DSceneHandler::AddCompound(), G4VisCommandSceneAddArrow2D::Arrow2D::Arrow2D(), G4DrawVoxels::ComputeVoxelPolyhedra(), G4AxesModel::Construct(), G4PhysicalVolumeModel::DescribeSolid(), G4GPSModel::DescribeYourselfTo(), G4VFieldModel::DescribeYourselfTo(), G4ScoringBox::Draw(), G4ScoringCylinder::Draw(), G4ScoreLogColorMap::DrawColorChartBar(), G4VScoreColorMap::DrawColorChartBar(), G4ScoreLogColorMap::DrawColorChartText(), G4VScoreColorMap::DrawColorChartText(), G4ScoringBox::DrawColumn(), G4ScoringCylinder::DrawColumn(), G4OpenGLStoredViewer::DrawDisplayLists(), anonymous_namespace{G4LogicalVolumeModel.cc}::DrawPoint(), G4TrajectoryDrawerUtils::DrawWithoutTime(), G4TrajectoryDrawerUtils::DrawWithTime(), G4ArrowModel::G4ArrowModel(), G4VisCommandSceneAddLogo::G4Logo::G4Logo(), G4VisCommandSceneAddLine::Line::Line(), G4VisCommandSceneAddLine2D::Line2D::Line2D(), G4VisCommandSceneAddDate::Date::operator()(), G4VisCommandSceneAddEventID::EventID::operator()(), G4VisCommandSceneAddFrame::Frame::operator()(), G4VisCommandSceneAddLogo2D::Logo2D::operator()(), G4VSceneHandler::RequestPrimitives(), G4VisCommandSceneAddScale::Scale::Scale(), G4VisCommandSceneAddText::SetNewValue(), and G4VisCommandSceneAddText2D::SetNewValue().

◆ SetWorldDiameter()

void G4VMarker::SetWorldDiameter ( G4double  )

◆ SetWorldRadius()

void G4VMarker::SetWorldRadius ( G4double  )

◆ SetWorldSize()

void G4VMarker::SetWorldSize ( G4double  )

Friends And Related Function Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const G4VMarker &  marker 
)
friend

Definition at line 64 of file G4VMarker.cc.

64 {
65 os << "G4VMarker: position: " << marker.fPosition
66 << ", world size: " << marker.fWorldSize
67 << ", screen size: " << marker.fScreenSize << '\n'
68 << " fill style: ";
69 switch (marker.fFillStyle) {
71 os << "no fill";
72 break;
74 os << "hashed";
75 break;
77 os << "filled";
78 break;
79 default:
80 os << "unrecognised"; break;
81 }
82 if (!marker.fInfo.empty()) os << "\n User information: " << marker.fInfo;
83 os << "\n " << (const G4Visible&) marker;
84 return os;
85}

Field Documentation

◆ fAllocatedVisAttributes

G4bool G4Visible::fAllocatedVisAttributes
protectedinherited

◆ fFillStyle

FillStyle G4VMarker::fFillStyle
private

Definition at line 154 of file G4VMarker.hh.

Referenced by operator!=().

◆ fInfo

G4String G4VMarker::fInfo
private

Definition at line 157 of file G4VMarker.hh.

Referenced by operator!=().

◆ fPosition

G4Point3D G4VMarker::fPosition
private

Definition at line 151 of file G4VMarker.hh.

Referenced by operator!=().

◆ fpVisAttributes

const G4VisAttributes* G4Visible::fpVisAttributes
protectedinherited

◆ fScreenSize

G4double G4VMarker::fScreenSize
private

Definition at line 153 of file G4VMarker.hh.

Referenced by GetSizeType(), operator!=(), and SetSize().

◆ fWorldSize

G4double G4VMarker::fWorldSize
private

Definition at line 152 of file G4VMarker.hh.

Referenced by GetSizeType(), operator!=(), and SetSize().


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