Consistent circle transform

Depending on compilation flags, applying a transform used to either:
- work;
- fail throwing an abstract method not implemented message;
- fail silently.

Now it should consistently work, like the other geometries.

Adding a polygon factory method creating an approximation of a circle on
a plane would be useful for users wanting the circle to be deformed.
It would be similar to the `circular` function which creates an
approximation of a circle on a sphere.
This commit is contained in:
Guillaume Beraudo
2014-09-09 14:14:22 +02:00
parent 7e502ac477
commit d67cefdf3a
3 changed files with 28 additions and 16 deletions

View File

@@ -203,16 +203,6 @@ describe('ol.geom.Circle', function() {
});
describe('#transform', function() {
it('throws an exception', function() {
expect(function() {
circle.applyTransform(ol.proj.identityTransform);
}).to.throwException();
});
});
});
});
@@ -220,4 +210,3 @@ describe('ol.geom.Circle', function() {
goog.require('ol.geom.Circle');
goog.require('ol.geom.GeometryType');
goog.require('ol.proj');