* (yet?) test if the tile would be drawn */
gdouble scale = eye->elev / min_dist;
view_res /= scale;
+ view_res *= 1.8;
//view_res /= 1.4; /* make it a little nicer, not sure why this is needed */
//g_message("tile=(%7.2f %7.2f %7.2f %7.2f) "
// "eye=(%9.1f %9.1f %9.1f) "
return;
}
- /* Need more resolution, split tile and update recursively */
- if (!tile->children[0][0]) {
- switch (tile->proj) {
- case GRITS_PROJ_LATLON: _grits_tile_split_latlon(tile); break;
- case GRITS_PROJ_MERCATOR: _grits_tile_split_mercator(tile); break;
+ /* Split tile if needed */
+ grits_tile_foreach(tile, child) {
+ if (child == NULL) {
+ switch (tile->proj) {
+ case GRITS_PROJ_LATLON: _grits_tile_split_latlon(tile); break;
+ case GRITS_PROJ_MERCATOR: _grits_tile_split_mercator(tile); break;
+ }
}
}
+ /* Update recursively */
grits_tile_foreach(tile, child) {
GRITS_OBJECT(child)->hidden = FALSE;
grits_tile_update(child, eye, res, width, height,