ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4Colour Class Reference

#include <geant4/tree/geant4-10.6-release/source/graphics_reps/include/G4Colour.hh>

+ Collaboration diagram for G4Colour:

Public Member Functions

 G4Colour (G4double r=1., G4double g=1., G4double b=1., G4double a=1.)
 
 G4Colour (G4ThreeVector)
 
 operator G4ThreeVector ()
 
G4bool operator!= (const G4Colour &c) const
 
G4bool operator== (const G4Colour &c) const
 
G4Colouroperator+= (const G4Colour &rhs)
 
G4double GetRed () const
 
G4double GetGreen () const
 
G4double GetBlue () const
 
G4double GetAlpha () const
 
void SetRed (G4double)
 
void SetGreen (G4double)
 
void SetBlue (G4double)
 
void SetAlpha (G4double)
 

Static Public Member Functions

static G4Colour White ()
 
static G4Colour Gray ()
 
static G4Colour Grey ()
 
static G4Colour Black ()
 
static G4Colour Brown ()
 
static G4Colour Red ()
 
static G4Colour Green ()
 
static G4Colour Blue ()
 
static G4Colour Cyan ()
 
static G4Colour Magenta ()
 
static G4Colour Yellow ()
 
static G4bool GetColour (const G4String &key, G4Colour &result)
 
static void AddToMap (const G4String &key, const G4Colour &colour)
 
static void InitialiseColourMap ()
 
static const std::map
< G4String, G4Colour > & 
GetMap ()
 

Private Attributes

G4double red
 
G4double green
 
G4double blue
 
G4double alpha
 

Static Private Attributes

static std::map< G4String,
G4Colour
fColourMap
 
static G4bool fInitColourMap = false
 

Friends

std::ostream & operator<< (std::ostream &, const G4Colour &)
 

Detailed Description

Definition at line 82 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 82 of file G4Colour.hh

Constructor & Destructor Documentation

G4Colour::G4Colour ( G4double  r = 1.,
G4double  g = 1.,
G4double  b = 1.,
G4double  a = 1. 
)

Definition at line 35 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 35 of file G4Colour.cc

References alpha, blue, green, and red.

Referenced by Black(), Blue(), Brown(), Cyan(), Gray(), Green(), Grey(), Magenta(), Red(), White(), and Yellow().

+ Here is the caller graph for this function:

G4Colour::G4Colour ( G4ThreeVector  v)

Definition at line 44 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 44 of file G4Colour.cc

References blue, green, and red.

Member Function Documentation

void G4Colour::AddToMap ( const G4String key,
const G4Colour colour 
)
static

Definition at line 110 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 110 of file G4Colour.cc

References fColourMap, G4endl, G4Exception(), G4Threading::IsMasterThread(), JustWarning, and G4String::toLower().

Referenced by InitialiseColourMap().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Black ( )
inlinestatic

Definition at line 157 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 157 of file G4Colour.hh

References G4Colour().

Referenced by PHG4BarrelEcalDisplayAction::ApplyDisplayAction(), PHG4CrystalCalorimeterDisplayAction::ApplyDisplayAction(), PHG4ForwardEcalDisplayAction::ApplyDisplayAction(), PHG4LFHcalDisplayAction::ApplyDisplayAction(), PHG4MicromegasDetector::construct_micromegas(), PHG4ECAPToFDetector::ConstructMe(), PHG4CylinderStripDetector::ConstructMe(), CML2WorldConstruction::create(), InitialiseColourMap(), and PHG4Utils::SetColour().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Blue ( )
inlinestatic

Definition at line 161 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 161 of file G4Colour.hh

References G4Colour().

Referenced by PHG4BbcDisplayAction::ApplyDisplayAction(), PHG4ZDCDisplayAction::ApplyDisplayAction(), BeastMagnetDisplayAction::ApplyDisplayAction(), PHG4EPDDisplayAction::ApplyDisplayAction(), PHG4BarrelEcalDisplayAction::ApplyDisplayAction(), PHG4InttDisplayAction::ApplyDisplayAction(), AllSiliconTrackerDisplayAction::ApplyDisplayAction(), G4LBLVtxDisplayAction::ApplyDisplayAction(), PHG4TTLDisplayAction::ApplyDisplayAction(), PHG4LFHcalDisplayAction::ApplyDisplayAction(), CML2Ph_BoxInBox::Construct(), PHG4TRDDetector::ConstructMe(), PHG4PSTOFDetector::ConstructMe(), PHG4ECAPToFDetector::ConstructMe(), PHG4FPbScDetector::ConstructMe(), PHG4CEmcTestBeamDetector::ConstructSandwichVolume(), PHG4Detector::DisplayVolume(), G4AxesModel::G4AxesModel(), G4TrajectoryDrawByCharge::G4TrajectoryDrawByCharge(), InitialiseColourMap(), CML2Acc1::ionizationChamber(), CML2Acc2::ionizationChamber(), CML2AccSaturn::ionizationChamber(), CML2Acc1::Jaw1X(), CML2Acc2::Jaw1X(), CML2AccSaturn::Jaw1X(), CML2AccSaturn::Jaw1Y(), CML2Acc2::Jaw2X(), CML2AccSaturn::Jaw2X(), CML2AccSaturn::Jaw2Y(), CML2AccSaturn::primaryCollimator(), DetectorConstruction::ResiduesView(), and PHG4Utils::SetColour().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Brown ( )
inlinestatic

Definition at line 158 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 158 of file G4Colour.hh

References G4Colour().

Referenced by PHG4BarrelEcalDisplayAction::ApplyDisplayAction(), PHG4MicromegasDetector::construct_micromegas(), PHG4TRDDetector::ConstructMe(), PHG4CylinderStripDetector::ConstructMe(), InitialiseColourMap(), and G4VisCommandSceneAddLogo2D::Logo2D::operator()().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4bool G4Colour::GetColour ( const G4String key,
G4Colour result 
)
static

Definition at line 162 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 162 of file G4Colour.cc

References fColourMap, InitialiseColourMap(), and G4String::toLower().

Referenced by G4ViewParameters::CameraAndLightingCommands(), G4VVisCommand::ConvertToColour(), G4AxesModel::G4AxesModel(), G4ModelColourMap< T >::Set(), G4TrajectoryDrawByOriginVolume::SetDefault(), G4TrajectoryDrawByEncounteredVolume::SetDefault(), G4TrajectoryDrawByParticleID::SetDefault(), G4ModelCmdApplyStringColour< M >::SetNewValue(), CexmcScenePrimitivesMessenger::SetNewValue(), and G4ModelCmdApplyColour< M >::SetNewValue().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

const std::map< G4String, G4Colour > & G4Colour::GetMap ( )
static

Definition at line 180 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 180 of file G4Colour.cc

References fColourMap, and InitialiseColourMap().

Referenced by operator<<(), and G4VisManager::PrintAvailableColours().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Green ( )
inlinestatic

Definition at line 160 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 160 of file G4Colour.hh

References G4Colour().

Referenced by EicFRichDetector::addDetectorSection(), PHG4OuterHcalDisplayAction::ApplyDisplayAction(), BeastMagnetDisplayAction::ApplyDisplayAction(), PHG4BarrelEcalDisplayAction::ApplyDisplayAction(), PHG4HybridHomogeneousCalorimeterDisplayAction::ApplyDisplayAction(), PHG4BbcDisplayAction::ApplyDisplayAction(), AllSiliconTrackerDisplayAction::ApplyDisplayAction(), PHG4InnerHcalDisplayAction::ApplyDisplayAction(), PHG4RICHDisplayAction::ApplyDisplayAction(), PHG4TTLDisplayAction::ApplyDisplayAction(), PHG4MicromegasDetector::construct_micromegas(), PHG4TRDDetector::ConstructMe(), PHG4ECAPToFDetector::ConstructMe(), PHG4CylinderStripDetector::ConstructMe(), PHG4CEmcTestBeamDetector::ConstructSandwichVolume(), PHG4Detector::DisplayVolume(), G4AxesModel::G4AxesModel(), G4TrajectoryDrawByCharge::G4TrajectoryDrawByCharge(), InitialiseColourMap(), CML2AccSaturn::Jaw1X(), CML2AccSaturn::Jaw1Y(), CML2AccSaturn::Jaw2X(), CML2AccSaturn::Jaw2Y(), CML2Acc2::mirror(), CML2Acc1::mirror(), CML2Acc1::MLC(), CML2Acc2::MLC(), CML2Acc2::primaryCollimator(), CML2AccSaturn::primaryCollimator(), DetectorConstruction::ResiduesView(), EICG4ZDCStructure::SetColors(), PHG4Utils::SetColour(), and CML2AccSaturn::vacuumWindow().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Grey ( )
inlinestatic

Definition at line 156 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 156 of file G4Colour.hh

References G4Colour().

Referenced by PHG4InnerHcalDisplayAction::ApplyDisplayAction(), PHG4InttDisplayAction::ApplyDisplayAction(), PHG4OuterHcalDisplayAction::ApplyDisplayAction(), AllSiliconTrackerDisplayAction::ApplyDisplayAction(), PHG4MicromegasDetector::construct_micromegas(), PHG4CylinderStripDetector::ConstructMe(), PHG4HcalDetector::ConstructMe(), InitialiseColourMap(), EICG4ZDCStructure::SetColors(), and CML2AccSaturn::target().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4Colour::InitialiseColourMap ( )
static

Definition at line 142 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 142 of file G4Colour.cc

References AddToMap(), Black(), Blue(), Brown(), Cyan(), fInitColourMap, Gray(), Green(), Grey(), Magenta(), Red(), White(), and Yellow().

Referenced by GetColour(), GetMap(), and G4VisManager::InitialiseG4ColourMap().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour G4Colour::Magenta ( )
inlinestatic

Definition at line 163 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 163 of file G4Colour.hh

References G4Colour().

Referenced by EicFRichDetector::addDetectorSection(), PHG4LFHcalDisplayAction::ApplyDisplayAction(), PHG4ForwardEcalDisplayAction::ApplyDisplayAction(), DetectorConstruction::BarycenterView(), PHG4TRDDetector::ConstructMe(), PHG4ECAPToFDetector::ConstructMe(), PHG4EnvelopeDetector::ConstructMe(), PHG4Detector::DisplayVolume(), UVA_VisAction::Draw(), CML2AccSaturn::flatteningFilter(), InitialiseColourMap(), CML2AccSaturn::ionizationChamber(), CML2Acc1::Jaw2Y(), CML2Acc1::primaryCollimator(), EICG4ZDCStructure::SetColors(), PHG4Utils::SetColour(), and CML2Acc1::target().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4Colour::operator G4ThreeVector ( )

Definition at line 76 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 76 of file G4Colour.cc

G4bool G4Colour::operator!= ( const G4Colour c) const

Definition at line 96 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 96 of file G4Colour.cc

References alpha, blue, green, and red.

Referenced by operator==().

+ Here is the caller graph for this function:

G4Colour& G4Colour::operator+= ( const G4Colour rhs)
inline

Definition at line 101 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 101 of file G4Colour.hh

G4bool G4Colour::operator== ( const G4Colour c) const
inline

Definition at line 99 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 99 of file G4Colour.hh

References operator!=().

+ Here is the call graph for this function:

G4Colour G4Colour::Red ( )
inlinestatic

Definition at line 159 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 159 of file G4Colour.hh

References G4Colour().

Referenced by PHG4ZDCDisplayAction::ApplyDisplayAction(), BeastMagnetDisplayAction::ApplyDisplayAction(), AllSi_Al_support_DisplayAction::ApplyDisplayAction(), AllSiliconTrackerDisplayAction::ApplyDisplayAction(), G4LBLVtxDisplayAction::ApplyDisplayAction(), PHG4EPDDisplayAction::ApplyDisplayAction(), PHG4RICHDisplayAction::ApplyDisplayAction(), PHG4LFHcalDisplayAction::ApplyDisplayAction(), PHG4BackwardHcalDisplayAction::ApplyDisplayAction(), PHG4ForwardEcalDisplayAction::ApplyDisplayAction(), PHG4TTLDisplayAction::ApplyDisplayAction(), DetectorConstruction::AtomisticView(), CML2Ph_BoxInBox::Construct(), CML2Ph_FullWater::Construct(), PHG4TRDDetector::ConstructMe(), PHG4CEmcTestBeamDetector::ConstructSandwichVolume(), PHG4Detector::DisplayVolume(), UVA_VisAction::Draw(), G4VVisCommand::DrawExtent(), CML2Acc1::flatteningFilter(), G4AxesModel::G4AxesModel(), G4TrajectoryDrawByCharge::G4TrajectoryDrawByCharge(), InitialiseColourMap(), CML2AccSaturn::ionizationChamber(), CML2AccSaturn::Jaw1X(), CML2Acc1::Jaw1Y(), CML2Acc2::Jaw1Y(), CML2AccSaturn::Jaw1Y(), CML2AccSaturn::Jaw2X(), CML2Acc2::Jaw2Y(), CML2AccSaturn::Jaw2Y(), CML2AccSaturn::primaryCollimator(), DetectorConstruction::ResiduesView(), PerspectiveVisAction::RoomAndChair(), and CML2Acc2::target().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4Colour::SetAlpha ( G4double  a)

Definition at line 70 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 70 of file G4Colour.cc

References a, and alpha.

Referenced by G4VVisCommand::ConvertToColour().

+ Here is the caller graph for this function:

void G4Colour::SetBlue ( G4double  b)

Definition at line 64 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 64 of file G4Colour.cc

References b, and blue.

void G4Colour::SetGreen ( G4double  gr)

Definition at line 58 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 58 of file G4Colour.cc

References green.

void G4Colour::SetRed ( G4double  r)

Definition at line 52 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 52 of file G4Colour.cc

References r, and red.

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const G4Colour c 
)
friend

Definition at line 80 of file G4Colour.cc.

View newest version in sPHENIX GitHub at line 80 of file G4Colour.cc

Member Data Documentation

G4double G4Colour::alpha
private

Definition at line 143 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 143 of file G4Colour.hh

Referenced by G4Colour(), GetAlpha(), operator!=(), operator<<(), and SetAlpha().

G4double G4Colour::blue
private

Definition at line 143 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 143 of file G4Colour.hh

Referenced by G4Colour(), GetBlue(), operator!=(), operator<<(), and SetBlue().

std::map< G4String, G4Colour > G4Colour::fColourMap
staticprivate

Definition at line 145 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 145 of file G4Colour.hh

Referenced by AddToMap(), GetColour(), and GetMap().

G4bool G4Colour::fInitColourMap = false
staticprivate

Definition at line 146 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 146 of file G4Colour.hh

Referenced by InitialiseColourMap().

G4double G4Colour::green
private

Definition at line 143 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 143 of file G4Colour.hh

Referenced by G4Colour(), GetGreen(), operator!=(), operator<<(), and SetGreen().

G4double G4Colour::red
private

Definition at line 143 of file G4Colour.hh.

View newest version in sPHENIX GitHub at line 143 of file G4Colour.hh

Referenced by G4Colour(), GetRed(), operator!=(), operator<<(), and SetRed().


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