HRESULT IApplicationGE::SetCameraParams ( [in] double lat,
[in] double lon,
[in] double alt,
[in] AltitudeModeGE altMode,
[in] double range,
[in] double tilt,
[in] double azimuth,
[in] double speed
)
Flies to the specified camera without requiring an ICameraInfoGE instance.
This is provided for performance reasons.
This is an optimized way of setting the camera rather than using SetCamera since it requires a much smaller number of COM calls.
lat | Latitude in degrees. Between -90 and 90 . | |
lon | Longitude in degrees. Between -180 and 180 . | |
alt | Altitude in meters. | |
altMode | Altitude mode that defines altitude reference origin. | |
range | Distance between focus point and camera in meters. | |
tilt | Tilt angle in degrees. Between 0 and 90 . | |
azimuth | Azimuth angle in degrees. | |
speed | Speed factor to use. Overrides autopilot speed. Value must be greater than 0 . If greater than or equal to 5.0 , the camera will immediately be set without any transition. This mode is called 'teleport'. |
S_OK | Successfully set camera. | |
S_TELEPORTED | Given speed is grater than or equal to 5.0 , in which case application's camera was teleported to the destination view. | |
E_INVALIDARG | invalid argument(s) (e.g. speed is not more than zero). | |
E_APPLICATION_UNINITIALIZED | Google Earth is not initialized. See IsInitialized. | |
(other) | Appropriate error code. |
上面是来自google earth com api 官方文档的资料,http://earth.google.com/comapi/interfaceIApplicationGE.html#9e1c8da5b36e8687fe718f2267224103
Defines a virtual camera that is associated with any element derived from Feature. The LookAt element positions the "camera" in relation to the object that is being viewed. In Google Earth, the view "flies to" this LookAt viewpoint when the user double-clicks an item in the Places panel or double-clicks an icon in the 3D viewer.
This diagram illustrates the <range>, <tilt>, and <altitude> elements:
上面的图来自KML文档,解释的比较清楚
http://code.google.com/apis/kml/documentation/kmlreference.html#lookat
联系客服