To support big polygons in MongoDB 3.0 they now support the addition of a Coordinate Reference System to GeoJSON documents. Currently the only supported CRS is:
urn:x-mongodb:crs:strictwinding:EPGS:4326
This can only be used with query documents. e.g.,
var bigPoly = {
type : "Polygon",
coordinates : [
[
[-10.0, -10.0],
[10.0, -10.0],
[10.0, 10.0],
[-10.0, 10.0],
[-10.0, -10.0]
]
],
crs : {
type : "name",
properties : {
name : "urn:x-mongodb:crs:strictwinding:EPSG:4326"
}
}
};
var cursor = db.collection.find({ loc : { $geoWithin : { $geometry : bigPoly } } });
var cursor = db.collection.find({ loc : { $geoIntersects : { $geometry : bigPoly } } });
To support big polygons in MongoDB 3.0 they now support the addition of a Coordinate Reference System to GeoJSON documents. Currently the only supported CRS is:
This can only be used with query documents. e.g.,