ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / CameraTrack Class
Members Example

In This Topic
    CameraTrack Class
    In This Topic
    A track containing a collection of CameraKeyframe objects that defines the view direction and rotation during the animation.
    Object Model
    CameraTrack ClassKeyframe Class
    Syntax
    Public NotInheritable Class CameraTrack 
       Inherits Track
    public sealed class CameraTrack : Track 
    Example
    Camera Keyframes
    {
      var animation = mapView.Map.Animation;
      var cameraTrack = animation.Tracks.OfType<CameraTrack>().First(); //There will always be only 1 CameraTrack in the animation.
      var result = cameraTrack.Keyframes.OfType<CameraKeyframe>().ToList();
      //Use the camera keyframes (if any)
    }
    Create Camera Keyframe
    {
      var animation = mapView.Map.Animation;
      var cameraTrack = animation.Tracks.OfType<CameraTrack>().First(); //There will always be only 1 CameraTrack in the animation.
      cameraTrack.CreateKeyframe(mapView.Camera, atTime, AnimationTransition.FixedArc);
    }
    Inheritance Hierarchy

    System.Object
       ArcGIS.Desktop.Mapping.Track
          ArcGIS.Desktop.Mapping.CameraTrack

    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also