Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mpim-sw
libcdi
Commits
e31d7c0c
Commit
e31d7c0c
authored
Dec 07, 2015
by
Thomas Jahns
🤸
Browse files
Improve virtualization of grid X/Y bounds data.
parent
ceb0850f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/grid.c
View file @
e31d7c0c
...
...
@@ -3089,10 +3089,11 @@ gridInqXBoundsSerial(grid_t *gridptr, double *xbounds)
||
gridptr
->
type
==
GRID_UNSTRUCTURED
;
size_t
size
=
nvertex
*
(
size_t
)(
irregular
?
gridptr
->
size
:
gridptr
->
xsize
);
if
(
gridptr
->
xbounds
)
const
double
*
gridptr_xbounds
=
gridptr
->
vtable
->
inqXBoundsPtr
(
gridptr
);
if
(
gridptr_xbounds
)
{
if
(
size
&&
xbounds
)
memcpy
(
xbounds
,
gridptr
->
xbounds
,
size
*
sizeof
(
double
));
memcpy
(
xbounds
,
gridptr
_
xbounds
,
size
*
sizeof
(
double
));
}
else
size
=
0
;
...
...
@@ -3175,10 +3176,11 @@ gridInqYBoundsSerial(grid_t *gridptr, double *ybounds)
||
gridptr
->
type
==
GRID_UNSTRUCTURED
;
size_t
size
=
nvertex
*
(
size_t
)(
irregular
?
gridptr
->
size
:
gridptr
->
ysize
);
if
(
gridptr
->
ybounds
)
const
double
*
gridptr_ybounds
=
gridptr
->
vtable
->
inqYBoundsPtr
(
gridptr
);
if
(
gridptr_ybounds
)
{
if
(
size
&&
ybounds
)
memcpy
(
ybounds
,
gridptr
->
ybounds
,
size
*
sizeof
(
double
));
memcpy
(
ybounds
,
gridptr
_
ybounds
,
size
*
sizeof
(
double
));
}
else
size
=
0
;
...
...
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