GoogleMaps Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GMSPanoramaCameraUpdate
@interface GMSPanoramaCameraUpdate : NSObject
GMSPanoramaCameraUpdate
represents an update that may be applied to a GMSPanoramaView
.
It encapsulates some logic for modifying the current camera.
It should only be constructed using the factory helper methods below.
-
Returns an update that increments the camera heading with deltaHeading
.
Declaration
Swift
class func rotate(by deltaHeading: CGFloat) -> GMSPanoramaCameraUpdate
Objective-C
+ (nonnull GMSPanoramaCameraUpdate *)rotateBy:(CGFloat)deltaHeading;
-
Returns an update that sets the camera heading to the given value.
Declaration
Swift
class func setHeading(_ heading: CGFloat) -> GMSPanoramaCameraUpdate
Objective-C
+ (nonnull GMSPanoramaCameraUpdate *)setHeading:(CGFloat)heading;
-
Returns an update that sets the camera pitch to the given value.
Declaration
Swift
class func setPitch(_ pitch: CGFloat) -> GMSPanoramaCameraUpdate
Objective-C
+ (nonnull GMSPanoramaCameraUpdate *)setPitch:(CGFloat)pitch;
-
Returns an update that sets the camera zoom to the given value.
Declaration
Swift
class func setZoom(_ zoom: CGFloat) -> GMSPanoramaCameraUpdate
Objective-C
+ (nonnull GMSPanoramaCameraUpdate *)setZoom:(CGFloat)zoom;
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-27 UTC.
[null,null,["Last updated 2025-08-27 UTC."],[[["\u003cp\u003e\u003ccode\u003eGMSPanoramaCameraUpdate\u003c/code\u003e objects are used to modify the camera view within a \u003ccode\u003eGMSPanoramaView\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThese updates control properties like heading, pitch, and zoom of the camera.\u003c/p\u003e\n"],["\u003cp\u003eFactory methods are provided to create specific camera updates, such as rotating, setting heading, pitch, or zoom.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eGMSPanoramaCameraUpdate\u003c/code\u003e simplifies adjusting the viewpoint within a panoramic scene.\u003c/p\u003e\n"]]],["`GMSPanoramaCameraUpdate` modifies a `GMSPanoramaView` camera using factory methods. It provides four update actions: `rotateBy:` increments the camera heading by a specified amount. `setHeading:` directly sets the camera's heading. `setPitch:` sets the camera's pitch. `setZoom:` adjusts the camera's zoom level. These methods return a `GMSPanoramaCameraUpdate` object to apply to the panorama view. Each of these can be implemented in Swift and Objective-C.\n"],null,["# GoogleMaps Framework Reference\n\nGMSPanoramaCameraUpdate\n=======================\n\n @interface GMSPanoramaCameraUpdate : NSObject\n\n`GMSPanoramaCameraUpdate` represents an update that may be applied to a [GMSPanoramaView](../Classes/GMSPanoramaView.html).\nIt encapsulates some logic for modifying the current camera.\nIt should only be constructed using the factory helper methods below.\n- `\n ``\n ``\n `\n\n ### [+rotateBy:](#/c:objc(cs)GMSPanoramaCameraUpdate(cm)rotateBy:)\n\n `\n ` \n Returns an update that increments the camera heading with `deltaHeading`. \n\n #### Declaration\n\n Swift \n\n class func rotate(by deltaHeading: CGFloat) -\u003e GMSPanoramaCameraUpdate\n\n Objective-C \n\n + (nonnull GMSPanoramaCameraUpdate *)rotateBy:(CGFloat)deltaHeading;\n\n- `\n ``\n ``\n `\n\n ### [+setHeading:](#/c:objc(cs)GMSPanoramaCameraUpdate(cm)setHeading:)\n\n `\n ` \n Returns an update that sets the camera heading to the given value. \n\n #### Declaration\n\n Swift \n\n class func setHeading(_ heading: CGFloat) -\u003e GMSPanoramaCameraUpdate\n\n Objective-C \n\n + (nonnull GMSPanoramaCameraUpdate *)setHeading:(CGFloat)heading;\n\n- `\n ``\n ``\n `\n\n ### [+setPitch:](#/c:objc(cs)GMSPanoramaCameraUpdate(cm)setPitch:)\n\n `\n ` \n Returns an update that sets the camera pitch to the given value. \n\n #### Declaration\n\n Swift \n\n class func setPitch(_ pitch: CGFloat) -\u003e GMSPanoramaCameraUpdate\n\n Objective-C \n\n + (nonnull GMSPanoramaCameraUpdate *)setPitch:(CGFloat)pitch;\n\n- `\n ``\n ``\n `\n\n ### [+setZoom:](#/c:objc(cs)GMSPanoramaCameraUpdate(cm)setZoom:)\n\n `\n ` \n Returns an update that sets the camera zoom to the given value. \n\n #### Declaration\n\n Swift \n\n class func setZoom(_ zoom: CGFloat) -\u003e GMSPanoramaCameraUpdate\n\n Objective-C \n\n + (nonnull GMSPanoramaCameraUpdate *)setZoom:(CGFloat)zoom;"]]