Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Andrew Bauer
VTK
Commits
e178db19
Commit
e178db19
authored
Sep 05, 2019
by
David E. DeMarle
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change 2D Rectgrid from ZY to XY
parent
e4be1fb8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
6 deletions
+17
-6
IO/Xdmf2/vtkXdmfHeavyData.cxx
IO/Xdmf2/vtkXdmfHeavyData.cxx
+17
-6
No files found.
IO/Xdmf2/vtkXdmfHeavyData.cxx
View file @
e178db19
...
...
@@ -729,7 +729,6 @@ vtkRectilinearGrid* vtkXdmfHeavyData::RequestRectilinearGrid(XdmfGrid* xmfGrid)
// convert to stridden update extents.
int
scaled_extents
[
6
];
vtkScaleExtents
(
update_extents
,
scaled_extents
,
this
->
Stride
);
int
scaled_dims
[
3
];
vtkGetDims
(
scaled_extents
,
scaled_dims
);
...
...
@@ -782,11 +781,23 @@ vtkRectilinearGrid* vtkXdmfHeavyData::RequestRectilinearGrid(XdmfGrid* xmfGrid)
case
XDMF_GEOMETRY_VXVY
:
{
xarray
->
FillComponent
(
0
,
0
);
xmfGeometry
->
GetVectorY
()
->
GetValues
(
update_extents
[
2
],
yarray
->
GetPointer
(
0
),
scaled_dims
[
1
],
this
->
Stride
[
1
]);
xmfGeometry
->
GetVectorX
()
->
GetValues
(
update_extents
[
4
],
zarray
->
GetPointer
(
0
),
scaled_dims
[
2
],
this
->
Stride
[
2
]);
// Note:
// XDMF and VTK structured extents are reversed
// Where I varies fastest, VTK's convention is IJK, but XDMF's is KJI
// However, users naturally don't want VXVY to mean VZVY.
// Let's accept VisIt's interpretation of this 2D case
// (KJI is ZXY where Z=0).
xarray
->
SetNumberOfTuples
(
scaled_dims
[
1
]);
yarray
->
SetNumberOfTuples
(
scaled_dims
[
2
]);
zarray
->
SetNumberOfTuples
(
scaled_dims
[
0
]);
rg
->
SetExtent
(
scaled_extents
[
2
],
scaled_extents
[
3
],
scaled_extents
[
4
],
scaled_extents
[
5
],
scaled_extents
[
0
],
scaled_extents
[
1
]);
xmfGeometry
->
GetVectorX
()
->
GetValues
(
update_extents
[
2
],
xarray
->
GetPointer
(
0
),
scaled_dims
[
1
],
this
->
Stride
[
1
]);
xmfGeometry
->
GetVectorY
()
->
GetValues
(
update_extents
[
4
],
yarray
->
GetPointer
(
0
),
scaled_dims
[
2
],
this
->
Stride
[
2
]);
zarray
->
FillComponent
(
0
,
0
);
}
break
;
...
...
Write
Preview
Markdown
is supported
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