MapObject::getShape()
This works in a project you run on your own computer, but not in the examples you can start here in the browser. There is no file system, no video encoder and no OpenGL behind a web page, so calling it there tells you as much and does nothing.
Returns a Shape object representing the current map object. The type of Shape returned depends on the properties of the map object: - If the object is a point, a 1x1 rectangle is returned. - If the object is an ellipse, an Ellipse2D object with the specified width and height is returned. - If the object is a polygon, a Polygon object with the specified points is returned.
- If none of the above conditions are met, a rectangle with the specified width and height is returned.
Syntax
Java
.getShape()
Return
Shape