GoogleNavigation Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GMSNavigationTravelMode
enum GMSNavigationTravelMode : NSInteger {}
The different travel modes that can be used for navigation.
-
Driving routes will be fetched, and the reported user course will be based on the direction of
movement.
Declaration
Objective-C
GMSNavigationTravelModeDriving = 0
-
Cycling routes will be fetched, and the reported user course will be based on the compass
direction the device is facing.
Note: During cycling navigation, the chevron always points in the direction that the
user’s device is facing (toward the top of the device in landscape mode). Keep in mind that
when testing with an emulator, neither the chevron direction nor the map orientation will
appear to change. However, when using a physical device, the map orientation will change when
the device is rotated, while the chevron continues to point in the direction that the device
is facing.
Declaration
Objective-C
GMSNavigationTravelModeCycling
-
Walking routes will be fetched, and the reported user course will be based on the compass
direction the device is facing.
Note: During walking navigation, the chevron always points in the direction that the
user’s device is facing (toward the top of the device in landscape mode). Keep in mind that
when testing with an emulator, neither the chevron direction nor the map orientation will
appear to change. However, when using a physical device, the map orientation will change when
the device is rotated, while the chevron continues to point in the direction that the device
is facing.
Declaration
Objective-C
GMSNavigationTravelModeWalking
-
Two-wheeler routes will be fetched, and the reported user course will be based on the direction
of movement.
Declaration
Swift
case twoWheeler = 3
Objective-C
GMSNavigationTravelModeTwoWheeler
-
Taxicab routes will be fetched, and the reported user course will be based on the direction
of movement. This is an experimental feature.
Declaration
Objective-C
GMSNavigationTravelModeTaxicab
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\u003eGMSNavigationTravelMode\u003c/code\u003e defines different travel modes for navigation, including driving, cycling, walking, two-wheeler, and taxicab.\u003c/p\u003e\n"],["\u003cp\u003eEach travel mode determines the type of route fetched and how user course is reported (based on direction of movement or compass direction).\u003c/p\u003e\n"],["\u003cp\u003eDriving, two-wheeler, and taxicab modes use the direction of movement for user course, while cycling and walking modes rely on the compass direction.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can select the appropriate travel mode to optimize navigation for different transportation methods.\u003c/p\u003e\n"]]],[],null,["# GoogleNavigation Framework Reference\n\nGMSNavigationTravelMode\n=======================\n\n enum GMSNavigationTravelMode : NSInteger {}\n\nThe different travel modes that can be used for navigation.\n- `\n ``\n ``\n `\n\n ### [GMSNavigationTravelModeDriving](#/c:@E@GMSNavigationTravelMode@GMSNavigationTravelModeDriving)\n\n `\n ` \n Driving routes will be fetched, and the reported user course will be based on the direction of\n movement. \n\n #### Declaration\n\n Swift \n\n case driving = 0\n\n Objective-C \n\n GMSNavigationTravelModeDriving = 0\n\n- `\n ``\n ``\n `\n\n ### [GMSNavigationTravelModeCycling](#/c:@E@GMSNavigationTravelMode@GMSNavigationTravelModeCycling)\n\n `\n ` \n Cycling routes will be fetched, and the reported user course will be based on the compass\n direction the device is facing.\n\n \u003cbr /\u003e\n\n Note: During cycling navigation, the chevron always points in the direction that the\n user's device is facing (toward the top of the device in landscape mode). Keep in mind that\n when testing with an emulator, neither the chevron direction nor the map orientation will\n appear to change. However, when using a physical device, the map orientation will change when\n the device is rotated, while the chevron continues to point in the direction that the device\n is facing. \n\n #### Declaration\n\n Swift \n\n case cycling = 1\n\n Objective-C \n\n GMSNavigationTravelModeCycling\n\n- `\n ``\n ``\n `\n\n ### [GMSNavigationTravelModeWalking](#/c:@E@GMSNavigationTravelMode@GMSNavigationTravelModeWalking)\n\n `\n ` \n Walking routes will be fetched, and the reported user course will be based on the compass\n direction the device is facing.\n\n \u003cbr /\u003e\n\n Note: During walking navigation, the chevron always points in the direction that the\n user's device is facing (toward the top of the device in landscape mode). Keep in mind that\n when testing with an emulator, neither the chevron direction nor the map orientation will\n appear to change. However, when using a physical device, the map orientation will change when\n the device is rotated, while the chevron continues to point in the direction that the device\n is facing. \n\n #### Declaration\n\n Swift \n\n case walking = 2\n\n Objective-C \n\n GMSNavigationTravelModeWalking\n\n- `\n ``\n ``\n `\n\n ### [GMSNavigationTravelModeTwoWheeler](#/c:@E@GMSNavigationTravelMode@GMSNavigationTravelModeTwoWheeler)\n\n `\n ` \n Two-wheeler routes will be fetched, and the reported user course will be based on the direction\n of movement. \n\n #### Declaration\n\n Swift \n\n case twoWheeler = 3\n\n Objective-C \n\n GMSNavigationTravelModeTwoWheeler\n\n- `\n ``\n ``\n `\n\n ### [GMSNavigationTravelModeTaxicab](#/c:@E@GMSNavigationTravelMode@GMSNavigationTravelModeTaxicab)\n\n `\n ` \n Taxicab routes will be fetched, and the reported user course will be based on the direction\n of movement. This is an experimental feature. \n\n #### Declaration\n\n Swift \n\n case taxicab = 4\n\n Objective-C \n\n GMSNavigationTravelModeTaxicab"]]