b6472664 |
1 | // Copyright (c) 2016 OPEN CASCADE SAS |
b311480e |
2 | // |
973c2be1 |
3 | // This file is part of Open CASCADE Technology software library. |
b311480e |
4 | // |
d5f74e42 |
5 | // This library is free software; you can redistribute it and/or modify it under |
6 | // the terms of the GNU Lesser General Public License version 2.1 as published |
973c2be1 |
7 | // by the Free Software Foundation, with special exception defined in the file |
8 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
9 | // distribution for complete text of the license and disclaimer of any warranty. |
b311480e |
10 | // |
973c2be1 |
11 | // Alternatively, this file may be used under the terms of Open CASCADE |
12 | // commercial license or contractual agreement. |
7fd59977 |
13 | |
b6472664 |
14 | #ifndef _Graphic3d_PolygonOffset_HeaderFile |
15 | #define _Graphic3d_PolygonOffset_HeaderFile |
7fd59977 |
16 | |
b6472664 |
17 | #include <Aspect_PolygonOffsetMode.hxx> |
0904aa63 |
18 | #include <Standard_OStream.hxx> |
7fd59977 |
19 | |
b6472664 |
20 | //! Polygon offset parameters. |
21 | struct Graphic3d_PolygonOffset |
b64d84be |
22 | { |
b6472664 |
23 | Aspect_PolygonOffsetMode Mode; |
24 | Standard_ShortReal Factor; |
25 | Standard_ShortReal Units; |
7fd59977 |
26 | |
b6472664 |
27 | //! Empty constructor. |
8fd45ae7 |
28 | Graphic3d_PolygonOffset() : Mode(Aspect_POM_Fill), Factor (1.0f), Units (1.0f) {} |
bf5f0ca2 |
29 | |
30 | //! Equality comparison. |
31 | bool operator== (const Graphic3d_PolygonOffset& theOther) const |
32 | { |
33 | return Mode == theOther.Mode |
34 | && Factor == theOther.Factor |
35 | && Units == theOther.Units; |
36 | } |
0904aa63 |
37 | |
38 | //! Dumps the content of me into the stream |
bc73b006 |
39 | Standard_EXPORT void DumpJson (Standard_OStream& theOStream, Standard_Integer theDepth = -1) const; |
0904aa63 |
40 | |
b64d84be |
41 | }; |
7fd59977 |
42 | |
b6472664 |
43 | #endif // _Graphic3d_PolygonOffset_HeaderFile |