Skip to content

Commit

Permalink
r3.out.vtk: improved error message when output cannot be written
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.osgeo.org/grass/grass/trunk@73693 15284696-431f-4ddb-bdfa-cd5b030d7da7
  • Loading branch information
neteler committed Nov 22, 2018
1 parent 5cd0a2d commit b19bbd7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions raster3d/r3.out.vtk/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -417,8 +417,7 @@ int main(int argc, char *argv[])
fp = fopen(param.output->answer, "w");
if (fp == NULL) {
perror(param.output->answer);
G_usage();
exit(EXIT_FAILURE);
G_fatal_error(_("Unable to open file <%s>"), param.output->answer);
}
} else
fp = stdout;
Expand Down
6 changes: 3 additions & 3 deletions raster3d/r3.out.vtk/r3.out.vtk.html
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,11 @@ <h3>Slovakia3d example</h3>
r.mapcalc "bottom = 100"

#export of volume to VTK:
r3.out.vtk -s in=precip3d.500z50 top=dem500 bottom=bottom
out=/tmp/slovakia3d.vtk
r3.out.vtk -s in=precip3d.500z50 top=dem500 bottom=bottom \
output=/path/to/slovakia3d.vtk

# visualize in paraview or other VTK viewer:
paraview --data=/tmp/slovakia3d.vtk
paraview --data=/path/to/slovakia3d.vtk
# set Display style to 'surface#
# set Actor Control z to 10
</pre></div>
Expand Down

0 comments on commit b19bbd7

Please sign in to comment.