java.lang.Object | |
↳ | com.google.android.gms.maps.model.CameraPosition |
An immutable class that aggregates all camera position parameters.
For more information, read the Changing the View developer guide.
Nested Classes | |||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
CameraPosition.Builder | Builds camera position. |
[Expand]
Inherited Constants | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
From interface
android.os.Parcelable
|
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
CREATOR | |||||||||||
bearing | Direction that the camera is pointing in, in degrees clockwise from north. | ||||||||||
target | The location that the camera is pointing at. | ||||||||||
tilt | The angle, in degrees, of the camera angle from the nadir (directly facing the Earth). | ||||||||||
zoom | Zoom level near the center of the screen. |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Constructs a CameraPosition.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a builder for a camera position.
| |||||||||||
Creates a builder for a camera position, initialized to a given position.
| |||||||||||
Creates a CameraPostion from the attribute set
| |||||||||||
Constructs a CameraPosition pointed for a particular target and zoom level.
| |||||||||||
[Expand]
Inherited Methods | |||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||||||||||||||||||||||||
From interface
android.os.Parcelable
|
Direction that the camera is pointing in, in degrees clockwise from north.
The angle, in degrees, of the camera angle from the nadir (directly facing the Earth). See
tilt
for details of restrictions on the range of values.
Zoom level near the center of the screen. See zoom
for the definition of the
camera's zoom level.
Constructs a CameraPosition.
target | The target location to align with the center of the screen. |
---|---|
zoom | Zoom level at target. See
zoom for details
of restrictions. |
tilt | The camera angle, in degrees, from the nadir (directly down). See
tilt for details
of restrictions. |
bearing | Direction that the camera is pointing in, in degrees clockwise from north. This value will be normalized to be within 0 degrees inclusive and 360 degrees exclusive. |
NullPointerException | if target is null |
---|---|
IllegalArgumentException | if tilt is outside the range of 0 degress inclusive
to 90 degrees inclusive.
|
Creates a builder for a camera position, initialized to a given position.
Creates a CameraPostion from the attribute set
Constructs a CameraPosition pointed for a particular target and zoom level. The resultant bearing is North, and the viewing angle is perpendicular to the Earth's surface. i.e., directly facing the Earth's surface, with the top of the screen pointing North.
target | The target location to align with the center of the screen. |
---|---|
zoom | Zoom level at target. See
zoom(float) for
details on the range the value will be clamped to. The larger the value the more
zoomed in the camera is.
|