116 glTranslatef(
x1, y1, z1);
125 if (y2==y1 &&
x2==
x1) {
130 p3[0] = p2[0]; p3[1] = p2[1]; p3[2] = 0;
135 glRotatef(phi, normal[0], normal[1], normal[2]);
144 }
else if ((
x2-
x1)<0) {
148 if (y2>y1) theta = 90;
152 if (
x2<
x1) theta = 180;
154 glRotatef(theta, 0., 0., 1.);
171 Float_t red = 1.f, green = 1.f, blue = 1.f;
173 col->
GetRGB(red, green, blue);
174 glColor3d(red, green, blue);
177 glVertex3d(0., 0., 0.);
218 glVertex3f(
fTicks1[i], yo*tl, zo*tl);
226 glLineStipple(1, stipple);
227 glEnable(GL_LINE_STIPPLE);
234 glDisable(GL_LINE_STIPPLE);
245 glVertex3f(
fTicks2[i], yo*tl, zo*tl);
289 for (i=0; i<
fNDiv1+1 ; i++) {
302 if (strchr(opt,
'N')) optionNoopt =
kTRUE;
else optionNoopt =
kFALSE;
351 for (j=0; j<
fNDiv2-1; j++) {
365 Int_t i, j, k, nDivOpt;
366 Double_t step1=0, step2=0, wmin2=0, wmax2=0;
391 wmin2, wmax2, nDivOpt,
402 for (j=0; j<
fNDiv2-1; j++) {
410 for (i=0; i<nTickl; i++) {
418 for (i=0; i<nTickr; i++) {
static const double x2[5]
static const double x1[5]
char * Form(const char *fmt,...)
virtual Color_t GetLineColor() const
Return the line color.
virtual Width_t GetLineWidth() const
Return the line width.
virtual void SetTextAlign(Short_t align=11)
Set the text alignment.
virtual Short_t GetTextAlign() const
Return the text alignment.
virtual Font_t GetTextFont() const
Return the text font.
virtual Color_t GetTextColor() const
Return the text color.
virtual void SetTextColor(Color_t tcolor=1)
Set the text color.
virtual void SetTextSize(Float_t tsize=1)
Set the text size.
The color creation and management class.
virtual void GetRGB(Float_t &r, Float_t &g, Float_t &b) const
void Init()
Default initialization.
void TicksPositionsOpt()
Compute ticks positions. Linear and optimized.
void PaintGLAxis(const Double_t p1[3], const Double_t p2[3], Double_t wmin, Double_t wmax, Int_t ndiv, Option_t *opt="")
Paint GL Axis.
Double_t fTickMarksLength
void PaintGLAxisBody()
Paint horizontal axis body at position (0,0,0)
void TicksPositions(Option_t *opt="")
Compute ticks positions.
void SetLabelsAngles(Double_t a1, Double_t a2, Double_t a3)
Set labels' angles.
void PaintGLAxisLabels()
Paint axis labels on the main tick marks.
void DoLabels()
Do labels.
void TicksPositionsNoOpt()
Compute ticks positions. Linear and not optimized.
Int_t fTickMarksOrientation
void PaintGLAxisTickMarks()
Paint axis tick marks.
virtual ~TGLAxis()
Destructor.
void SetGLTextAngles(Double_t a1, Double_t a2, Double_t a3)
Set the text rotation angles.
void PaintGLText(Double_t x, Double_t y, Double_t z, const char *text)
Draw text.
void SetGLTextFont(Font_t fontnumber)
static Float_t LineWidth()
Get the line-width, taking the global scaling into account.
static void Optimize(Double_t A1, Double_t A2, Int_t nold, Double_t &BinLow, Double_t &BinHigh, Int_t &nbins, Double_t &BWID, Option_t *option="")
Static function to compute reasonable axis limits.
T * Normal2Plane(const T v1[3], const T v2[3], const T v3[3], T normal[3])
Calculate a normal vector of a plane.
Double_t Sqrt(Double_t x)