示例#1
0
        public static ARComplexCamera CreateSpringFollowCamera(GraphicsDevice device, AR3DObject unit)
        {
            ARComplexCamera c = new ARComplexCamera(device);

            c.cameraType      = CameraType.SpringCamera;
            c.cameraObjOffset = new Vector3(0, 10, 40);
            c.lookAtOffset    = new Vector3(0, 4, -8);
            c.follow(unit);
            return(c);
        }
示例#2
0
        public static ARComplexCamera CreateAODChaseCamera(GraphicsDevice device, AR3DObject unit)
        {
            ARComplexCamera c = new ARComplexCamera(device);

            c.cameraType = CameraType.AODChaseCamera;

            c.cameraObjOffset = new Vector3(0, 10, 40);
            c.lookAtOffset    = new Vector3(0, 0, -1000);

            c.follow(unit);
            return(c);
        }
示例#3
0
        public static ARComplexCamera CreateNormalFollowCamera(GraphicsDevice device, AR3DObject unit)
        {
            ARComplexCamera c = new ARComplexCamera(device);

            c.cameraType = CameraType.NormalCamera;

            c.cameraObjOffset = new Vector3(6, 5, 20);
            c.lookAtOffset    = new Vector3(0, 0, -1000);

            c.follow(unit);

            return(c);
        }
示例#4
0
 /// <summary>
 /// 使该相机位置和旋转与目标相机保持同步注意,如果是该相机为普通相机则永久改变位置
 /// </summary>
 /// <param name="target"></param>
 public void Sync(ARComplexCamera target)
 {
     this.position       = target.position;
     this.cameraRotation = target.cameraRotation;
 }