Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
caddies
caddies-api
Commits
31d08afe
Commit
31d08afe
authored
Mar 30, 2016
by
Luís de Sousa
Browse files
Output raster file extensions now given by the implementation Grid classes.
parent
724a4a2e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
impls/hexagonal-cell/1-levels/simple/HexAsciiGrid.hpp
impls/hexagonal-cell/1-levels/simple/HexAsciiGrid.hpp
+4
-2
impls/square-cell/vn-neighbours/1-levels/simple/ESRI_ASCIIGrid.hpp
...are-cell/vn-neighbours/1-levels/simple/ESRI_ASCIIGrid.hpp
+3
-0
No files found.
impls/hexagonal-cell/1-levels/simple/HexAsciiGrid.hpp
View file @
31d08afe
...
...
@@ -57,6 +57,7 @@ namespace CA {
static
const
char
*
key_yll
;
static
const
char
*
key_side
;
static
const
char
*
key_nodata
;
static
const
std
::
string
file_extension
;
//! Read token and value pair from a line of the header of an hexagonal ASCII raster file.
//! .
...
...
@@ -180,7 +181,7 @@ namespace CA {
//Clock total_timer;
// Open file
std
::
ofstream
onfile
(
filename
.
c_str
());
std
::
ofstream
onfile
(
(
filename
+
file_extension
)
.
c_str
());
// Check if the file was open.
if
(
!
onfile
)
...
...
@@ -240,7 +241,8 @@ namespace CA {
const
char
*
HexAsciiGrid
<
T
>::
key_side
=
"side"
;
template
<
typename
T
>
const
char
*
HexAsciiGrid
<
T
>::
key_nodata
=
"no_data"
;
template
<
typename
T
>
const
std
::
string
HexAsciiGrid
<
T
>::
file_extension
=
".hasc"
;
}
// end of namespace
...
...
impls/square-cell/vn-neighbours/1-levels/simple/ESRI_ASCIIGrid.hpp
View file @
31d08afe
...
...
@@ -184,6 +184,9 @@ namespace CA {
// Get starting time.
//Clock total_timer;
// Add file extension
filename
+=
".asc"
;
// Open file
std
::
ofstream
onfile
(
filename
.
c_str
());
...
...
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