source: subversion/applications/utils/mod_tile/dir_utils.h @ 28454

Last change on this file since 28454 was 15835, checked in by jochen, 10 years ago

More changes to make the tile cache directory configurable at runtime

-ttile-dir option for render_list and convert_meta
  • renderd reads it from renderd.conf section "[renderd]" setting "tile_dir"
  • mod_tile reads from Apache conf ModTileTileDir? directive

There are still some places in store.c left, where HASH_DIR is used directly. More fixes needed.

File size: 982 bytes
Line 
1#ifndef DIR_UTILS_H
2#define DIR_UTILS_H
3
4#include <sys/types.h>
5
6#ifdef __cplusplus
7  extern "C" {
8#endif
9
10#include "render_config.h"
11
12/* Build parent directories for the specified file name
13 * Note: the part following the trailing / is ignored
14 * e.g. mkdirp("/a/b/foo.png") == shell mkdir -p /a/b
15 */
16int mkdirp(const char *path);
17
18/* File path hashing. Used by both mod_tile and render daemon
19 * The two must both agree on the file layout for meta-tiling
20 * to work
21 */
22void xyz_to_path(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z);
23
24int check_xyz(int x, int y, int z);
25int path_to_xyz(const char *path, char *xmlconfig, int *px, int *py, int *pz);
26
27#ifdef METATILE
28/* New meta-tile storage functions */
29/* Returns the path to the meta-tile and the offset within the meta-tile */
30int xyz_to_meta(char *path, size_t len, const char *tile_dir, const char *xmlconfig, int x, int y, int z);
31#endif
32
33#ifdef __cplusplus
34  }
35#endif
36
37
38#endif
Note: See TracBrowser for help on using the repository browser.