0024739: TKOpenGl - port ray-tracing from OpenCL to GLSL for better integration and...
[occt.git] / src / OpenGl / OpenGl_GraduatedTrihedron.hxx
CommitLineData
b311480e 1// Created on: 2011-09-20
2// Created by: Sergey ZERCHANINOV
a174a3c5 3// Copyright (c) 2011-2013 OPEN CASCADE SAS
b311480e 4//
973c2be1 5// This file is part of Open CASCADE Technology software library.
b311480e 6//
d5f74e42 7// This library is free software; you can redistribute it and/or modify it under
8// the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 9// by the Free Software Foundation, with special exception defined in the file
10// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11// distribution for complete text of the license and disclaimer of any warranty.
b311480e 12//
973c2be1 13// Alternatively, this file may be used under the terms of Open CASCADE
14// commercial license or contractual agreement.
b311480e 15
2166f0fa
SK
16#ifndef _OpenGl_GraduatedTrihedron_Header
17#define _OpenGl_GraduatedTrihedron_Header
18
a174a3c5 19#include <OpenGl_Element.hxx>
2166f0fa 20
a174a3c5 21#include <OpenGl_Text.hxx>
2166f0fa
SK
22#include <Graphic3d_CGraduatedTrihedron.hxx>
23
fd03ee4b 24class Visual3d_View;
2166f0fa
SK
25class OpenGl_View;
26
a174a3c5 27class OpenGl_GraduatedTrihedron : public OpenGl_Element
2166f0fa 28{
a174a3c5 29
30public:
2166f0fa
SK
31
32 static void SetMinMax (const Standard_ShortReal xMin, const Standard_ShortReal yMin, const Standard_ShortReal zMin,
33 const Standard_ShortReal xMax, const Standard_ShortReal yMax, const Standard_ShortReal zMax);
34
a174a3c5 35public:
36
37 OpenGl_GraduatedTrihedron (const Graphic3d_CGraduatedTrihedron& theData);
38
39 virtual void Render (const Handle(OpenGl_Workspace)& theWorkspace) const;
40 virtual void Release (const Handle(OpenGl_Context)& theCtx);
2166f0fa 41
a174a3c5 42protected:
2166f0fa 43
a174a3c5 44 virtual ~OpenGl_GraduatedTrihedron();
2166f0fa 45
a174a3c5 46protected:
47
48 mutable OpenGl_Text myLabelX;
49 mutable OpenGl_Text myLabelY;
50 mutable OpenGl_Text myLabelZ;
51 mutable OpenGl_Text myLabelValues;
52 mutable OpenGl_AspectText myAspectLabels;
53 mutable OpenGl_AspectText myAspectValues;
54 TEL_COLOUR myXNameColor;
55 TEL_COLOUR myYNameColor;
56 TEL_COLOUR myZNameColor;
57
58 bool myToDrawXName;
59 bool myToDrawYName;
60 bool myToDrawZName;
61 bool myToDrawXValues;
62 bool myToDrawYValues;
63 bool myToDrawZValues;
64 bool myToDrawGrid;
65 bool myToDrawAxes;
2166f0fa
SK
66 unsigned int myNbX, myNbY, myNbZ;
67 int myXOffset, myYOffset, myZOffset;
68 int myXAxisOffset, myYAxisOffset, myZAxisOffset;
8263fcd3 69 Standard_Boolean myDrawXTickmarks;
70 Standard_Boolean myDrawYTickmarks;
71 Standard_Boolean myDrawZTickmarks;
2166f0fa
SK
72 unsigned int myXTickmarkLength, myYTickmarkLength, myZTickmarkLength;
73 float myGridColor[3];
a174a3c5 74 TEL_COLOUR myXColor;
75 TEL_COLOUR myYColor;
76 TEL_COLOUR myZColor;
fd03ee4b 77 Graphic3d_CGraduatedTrihedron::minMaxValuesCallback myCbCubicAxes;
78 Visual3d_View* myPtrVisual3dView;
2166f0fa 79
a174a3c5 80public:
81
1c35b92f 82 DEFINE_STANDARD_ALLOC
a174a3c5 83
2166f0fa
SK
84};
85
86#endif //_OpenGl_GraduatedTrihedron_Header