Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Christian Butz
VTK
Commits
7bdb132c
Commit
7bdb132c
authored
Dec 03, 2011
by
Philippe Pébay
Browse files
Initializing LastMin/MaxCoordinate iVars
Change-Id: I4cf16e5a78bc07c055f29aea6aadb3325f3d63d0
parent
2e564c35
Changes
1
Hide whitespace changes
Inline
Side-by-side
Hybrid/vtkAxisActor.cxx
View file @
7bdb132c
...
...
@@ -183,6 +183,12 @@ vtkAxisActor::vtkAxisActor()
this
->
TitleConstantPosition
[
0
]
=
this
->
TitleConstantPosition
[
1
]
=
0.
;
this
->
VerticalOffsetXTitle2D
=
-
40.
;
this
->
HorizontalOffsetYTitle2D
=
-
50.
;
this
->
LastMinDisplayCoordinate
[
0
]
=
0
;
this
->
LastMinDisplayCoordinate
[
1
]
=
0
;
this
->
LastMinDisplayCoordinate
[
2
]
=
0
;
this
->
LastMaxDisplayCoordinate
[
0
]
=
0
;
this
->
LastMaxDisplayCoordinate
[
1
]
=
0
;
this
->
LastMaxDisplayCoordinate
[
2
]
=
0
;
}
// ****************************************************************
...
...
@@ -1017,8 +1023,9 @@ void vtkAxisActor::PrintSelf(ostream& os, vtkIndent indent)
os
<<
indent
<<
"Title: "
<<
(
this
->
Title
?
this
->
Title
:
"(none)"
)
<<
"
\n
"
;
os
<<
indent
<<
"Number Of Labels Built: "
<<
this
->
NumberOfLabelsBuilt
<<
"
\n
"
;
os
<<
indent
<<
"Range: ("
<<
this
->
Range
[
0
]
<<
", "
<<
this
->
Range
[
1
]
<<
")
\n
"
;
os
<<
indent
<<
"Range: ("
<<
this
->
Range
[
0
]
<<
", "
<<
this
->
Range
[
1
]
<<
")
\n
"
;
os
<<
indent
<<
"Label Format: "
<<
this
->
LabelFormat
<<
"
\n
"
;
...
...
@@ -1115,6 +1122,14 @@ void vtkAxisActor::PrintSelf(ostream& os, vtkIndent indent)
os
<<
indent
<<
"SaveTitlePosition: "
<<
this
->
SaveTitlePosition
<<
endl
;
os
<<
indent
<<
"VerticalOffsetXTitle2D"
<<
this
->
VerticalOffsetXTitle2D
<<
endl
;
os
<<
indent
<<
"HorizontalOffsetYTitle2D"
<<
this
->
HorizontalOffsetYTitle2D
<<
endl
;
os
<<
indent
<<
"LastMinDisplayCoordinates: ("
<<
this
->
LastMinDisplayCoordinate
[
0
]
<<
", "
<<
this
->
LastMinDisplayCoordinate
[
1
]
<<
", "
<<
this
->
LastMinDisplayCoordinate
[
2
]
<<
")"
<<
endl
;
os
<<
indent
<<
"LastMaxDisplayCoordinates: ("
<<
this
->
LastMaxDisplayCoordinate
[
0
]
<<
", "
<<
this
->
LastMaxDisplayCoordinate
[
1
]
<<
", "
<<
this
->
LastMaxDisplayCoordinate
[
2
]
<<
")"
<<
endl
;
}
// **************************************************************************
...
...
@@ -2160,16 +2175,18 @@ bool vtkAxisActor::BoundsDisplayCoordinateChanged(vtkViewport *viewport)
viewport
->
WorldToDisplay
();
viewport
->
GetDisplayPoint
(
transMaxPt
);
if
(
LastMinDisplayCoordinate
[
0
]
!=
transMinPt
[
0
]
||
LastMinDisplayCoordinate
[
1
]
!=
transMinPt
[
1
]
||
LastMinDisplayCoordinate
[
2
]
!=
transMinPt
[
2
]
||
LastMaxDisplayCoordinate
[
0
]
!=
transMaxPt
[
0
]
||
LastMaxDisplayCoordinate
[
1
]
!=
transMaxPt
[
1
]
||
LastMaxDisplayCoordinate
[
2
]
!=
transMaxPt
[
2
]
)
if
(
this
->
LastMinDisplayCoordinate
[
0
]
!=
transMinPt
[
0
]
||
this
->
LastMinDisplayCoordinate
[
1
]
!=
transMinPt
[
1
]
||
this
->
LastMinDisplayCoordinate
[
2
]
!=
transMinPt
[
2
]
||
this
->
LastMaxDisplayCoordinate
[
0
]
!=
transMaxPt
[
0
]
||
this
->
LastMaxDisplayCoordinate
[
1
]
!=
transMaxPt
[
1
]
||
this
->
LastMaxDisplayCoordinate
[
2
]
!=
transMaxPt
[
2
]
)
{
int
i
=
0
;
for
(
i
=
0
;
i
<
3
;
++
i
)
{
LastMinDisplayCoordinate
[
i
]
=
transMinPt
[
i
];
LastMaxDisplayCoordinate
[
i
]
=
transMaxPt
[
i
];
this
->
LastMinDisplayCoordinate
[
i
]
=
transMinPt
[
i
];
this
->
LastMaxDisplayCoordinate
[
i
]
=
transMaxPt
[
i
];
}
return
true
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment