fun calcPosition( camera: BaseCamera, geometry: Geometry, screenArea: Padding? = null, tilt: Tilt? = null, bearing: Bearing? = null, size: ScreenSize? = null ): CameraPosition
Calculation of the camera position such that the geometric object located on the map is completely inscribed in the screen area specified by the screen_area parameter.
If you do not need to change the settings of the original camera, then you can configure the one copied via IBaseCamera::clone().
the camera used to calculate the position.
a geometric object to fit into the screen area specified by the screen_area parameter.
area of the screen to fit the geometry into. If not specified, the camera's padding is used for calculation.
map tilt. If not specified, the current camera tilt is used.
map rotation. If not specified, then the current camera rotation is used.
Size of the viewport. If not specified, the value of ICamera::size() is used.