mirror of
https://github.com/openstreetmap/mod_tile.git
synced 2025-07-25 15:04:30 +00:00
Move xyzo_to_meta into proper header file (#456)
This commit is contained in:
@ -25,7 +25,6 @@ extern "C" {
|
||||
#include "store.h"
|
||||
|
||||
struct storage_backend *init_storage_file(const char *tile_dir);
|
||||
int xyzo_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, const char *options, int x, int y, int z);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -32,17 +32,18 @@ extern "C" {
|
||||
*/
|
||||
int mkdirp(const char *path);
|
||||
|
||||
/* File path hashing. Used by both mod_tile and render daemon
|
||||
* The two must both agree on the file layout for meta-tiling
|
||||
* to work
|
||||
*/
|
||||
int path_to_xyz(const char *tilepath, const char *path, char *xmlconfig, int *px, int *py, int *pz);
|
||||
|
||||
#ifdef METATILE
|
||||
/* New meta-tile storage functions */
|
||||
/* Returns the path to the meta-tile and the offset within the meta-tile */
|
||||
int xyzo_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, const char *options, int x, int y, int z);
|
||||
int xyz_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z);
|
||||
#else
|
||||
/* File path hashing. Used by both mod_tile and render daemon
|
||||
* The two must both agree on the file layout for meta-tiling
|
||||
* to work
|
||||
*/
|
||||
void xyz_to_path(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z);
|
||||
#endif
|
||||
|
||||
|
@ -171,12 +171,6 @@ int path_to_xyz(const char *tilepath, const char *path, char *xmlconfig, int *px
|
||||
}
|
||||
|
||||
#ifdef METATILE
|
||||
// Returns the path to the meta-tile and the offset within the meta-tile
|
||||
int xyz_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z)
|
||||
{
|
||||
return xyzo_to_meta(path, len, tile_dir, xmlconfig, "", x, y, z);
|
||||
}
|
||||
|
||||
// Returns the path to the meta-tile and the offset within the meta-tile
|
||||
int xyzo_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, const char *options, int x, int y, int z)
|
||||
{
|
||||
@ -214,6 +208,12 @@ int xyzo_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlco
|
||||
#endif // DIRECTORY_HASH
|
||||
return offset;
|
||||
}
|
||||
|
||||
// Returns the path to the meta-tile and the offset within the meta-tile
|
||||
int xyz_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z)
|
||||
{
|
||||
return xyzo_to_meta(path, len, tile_dir, xmlconfig, "", x, y, z);
|
||||
}
|
||||
#else // METATILE
|
||||
void xyz_to_path(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z)
|
||||
{
|
||||
|
Reference in New Issue
Block a user