Geant4
9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4Scale.cc
Go to the documentation of this file.
1
//
2
// ********************************************************************
3
// * License and Disclaimer *
4
// * *
5
// * The Geant4 software is copyright of the Copyright Holders of *
6
// * the Geant4 Collaboration. It is provided under the terms and *
7
// * conditions of the Geant4 Software License, included in the file *
8
// * LICENSE and available at http://cern.ch/geant4/license . These *
9
// * include a list of copyright holders. *
10
// * *
11
// * Neither the authors of this software system, nor their employing *
12
// * institutes,nor the agencies providing financial support for this *
13
// * work make any representation or warranty, express or implied, *
14
// * regarding this software system or assume any liability for its *
15
// * use. Please see the license in the file LICENSE and URL above *
16
// * for the full disclaimer and the limitation of liability. *
17
// * *
18
// * This code implementation is the result of the scientific and *
19
// * technical work of the GEANT4 collaboration. *
20
// * By using, copying, modifying or distributing the software (or *
21
// * any work based on the software) you agree to acknowledge its *
22
// * use in resulting scientific publications, and indicate your *
23
// * acceptance of all terms of the Geant4 Software license. *
24
// ********************************************************************
25
//
26
//
27
// $Id$
28
//
29
//
30
// John Allison 21st July 2001
31
32
#include "
G4Scale.hh
"
33
34
G4Scale::G4Scale
(
G4double
length,
const
G4String
& annotation,
35
G4Scale::Direction
direction,
36
G4bool
autoPlacing,
37
G4double
xmid,
G4double
ymid,
G4double
zmid):
38
fLength(length),
39
fAnnotation(annotation),
40
fDirection(direction),
41
fAutoPlacing(autoPlacing),
42
fXmid(xmid), fYmid(ymid), fZmid(zmid) {}
43
44
G4Scale::~G4Scale
() {}
45
46
const
G4String
G4Scale::GuidanceString
47
(
48
"An annotated line in the specified direction with tick marks at the"
49
"\nend. If autoPlacing is true it is required to be centred at the"
50
"\nfront, right, bottom corner of the world space, comfortably outside"
51
"\nthe existing bounding box/sphere so that existing objects do not"
52
"\nobscure it. Otherwise it is required to be drawn with mid-point at"
53
"\n(xmid, ymid, zmid)."
54
"\n"
55
"\nThe auto placing algorithm might be:"
56
"\n x = xmin + (1 + comfort) * (xmax - xmin);"
57
"\n y = ymin - comfort * (ymax - ymin);"
58
"\n z = zmin + (1 + comfort) * (zmax - zmin);"
59
"\n if direction == x then (x - length,y,z) to (x,y,z);"
60
"\n if direction == y then (x,y,z) to (x,y + length,z);"
61
"\n if direction == z then (x,y,z - length) to (x,y,z);"
62
);
63
64
const
G4String
&
G4Scale::GetGuidanceString
()
65
{
66
return
GuidanceString;
67
}
G4Scale.hh
G4double
double G4double
Definition:
G4Types.hh:64
G4bool
bool G4bool
Definition:
G4Types.hh:67
G4Scale::~G4Scale
~G4Scale()
Definition:
G4Scale.cc:44
G4Scale::G4Scale
G4Scale(G4double length, const G4String &annotation="", Direction direction=x, G4bool autoPlacing=true, G4double xmid=0., G4double ymid=0., G4double zmid=0.)
Definition:
G4Scale.cc:34
G4Scale::Direction
Direction
Definition:
G4Scale.hh:42
G4Scale::GetGuidanceString
static const G4String & GetGuidanceString()
Definition:
G4Scale.cc:64
G4String
Definition:
G4String.hh:105
geant4-v9.6.0
source
graphics_reps
src
G4Scale.cc
Generated by
1.9.6