-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve handling of multilayer formats #72
Comments
- Currently only supports single layer FileGDB - Proper support is dependent on solving #72
@springmeyer I think we may try and bite off #68 soon, but this introduces a new wrinkle that makes me think we may not be able to accomplish this kind of refactor without significant breaking changes. Currently we're outputting a JSON object that more or less assumes that your file has one projection, one extent, one center, etc. We could adjust the output such that its more like: {
"filepath": "/somewhere/some.file",
"layers": [ "array of objects describing proj, extent, etc" ]
} Or, alternately, we could treat each layer in a filegeodatabase as a distinct datasource, and adjust the inputs to allow for designation of the layer-of-interest: omnivore.digest('/path/to/raster.tif', callback(err, result) {
// result is valid for the only "layer" that exists
});
omnivore.digest('/path/to/geodatabase.fgdb', 'some-layer', callback(err, result) {
// result is valid for the designated layer
});
omnivore.digest('/path/to/geodatabase.fgdb', callback(err, result) {
// result is valid for the first layer??
}); |
I'm okay pausing on this until after more critical refactoring passes are in place. As far as how to re-design, I like your second idea of |
I'm trying to add FileGDB support and noticing a design limitation: mapnik-omnivore assumes a file has only one projection.
In the case of FileGDB each table is a layer with a potentially unique projection and extent. This means that inside
processOgrDatasource
thegetCenterAndExtent
andgetMinMaxZoom
functions need to operate per layer and not per file.The text was updated successfully, but these errors were encountered: