Ejemplo n.º 1
0
        override public void OnPulse(Timeline timeline, double time)
        {
            ViewPosition pvp = timeline.GetMostPreviousInTime(time) as ViewPosition;
            ViewPosition nvp = timeline.GetNextInTime(time) as ViewPosition;

            if (pvp != null && nvp != null)
            {
                double alpha = ScriptPlayer.ComputeAlpha(time - pvp.Time, pvp, nvp);
                double span  = (nvp.Longitude - pvp.Longitude) % 360;
                if (span >= 180)
                {
                    span -= 360;
                }
                else if (span < -180)
                {
                    span += 360;
                }

                double lon = pvp.Longitude + alpha * span;
                double lat = pvp.Latitude + alpha * (nvp.Latitude - pvp.Latitude);
                double ele = pvp.Elevation + alpha * (nvp.Elevation - pvp.Elevation);

                this.globe.SetViewPosition(lat, lon, ele);
            }
            else if (pvp != null)
            {
                this.globe.SetViewPosition(pvp.Latitude, pvp.Longitude, pvp.Elevation);
            }
        }
Ejemplo n.º 2
0
		override public void OnPulse(Timeline timeline, double time)
		{
			ViewPosition pvp = timeline.GetMostPreviousInTime(time) as ViewPosition;
			ViewPosition nvp = timeline.GetNextInTime(time) as ViewPosition;

			if (pvp != null && nvp != null)
			{
				double alpha = ScriptPlayer.ComputeAlpha(time - pvp.Time, pvp, nvp);
				double span = (nvp.Longitude - pvp.Longitude) % 360;
				if (span >= 180)
					span -= 360;
				else if (span < -180)
					span += 360;

				double lon = pvp.Longitude + alpha * span;
				double lat = pvp.Latitude + alpha * (nvp.Latitude - pvp.Latitude);
				double ele = pvp.Elevation + alpha * (nvp.Elevation - pvp.Elevation);

				this.globe.SetViewPosition(lat, lon, ele);
			}
			else if (pvp != null)
			{
				this.globe.SetViewPosition(pvp.Latitude, pvp.Longitude, pvp.Elevation);
			}
		}
Ejemplo n.º 3
0
		override public void OnPulse(Timeline timeline, double time)
		{
			WmsImage wi = timeline.GetMostPreviousInTime(time) as WmsImage;
			if (wi == null)
				return;

			this.globe.SetWmsImage(wi.Descriptor, null, 0);
		}
Ejemplo n.º 4
0
		override public void OnPulse(Timeline timeline, double time)
		{
			ToggleBase toggle = timeline.GetMostPreviousInTime(time) as ToggleBase;
			if (toggle != null)
			{
				this.DoPulse(toggle.ToggleValue);
			}
		}
Ejemplo n.º 5
0
		override public void OnPulse(Timeline timeline, double time)
		{
			DisplayMessages dms = timeline.GetMostPreviousInTime(time) as DisplayMessages;
			if (dms == null)
				return;

			this.globe.SetDisplayMessages(dms.Messages);
		}
Ejemplo n.º 6
0
		override public void OnPulse(Timeline timeline, double time)
		{
			Layers prev = timeline.GetMostPreviousInTime(time) as Layers;
			if (prev != null)
			{
//				System.Console.Write(time + " : ");
				this.globe.SetLayers(prev.LayerList);
			}
		}
Ejemplo n.º 7
0
        override public void OnPulse(Timeline timeline, double time)
        {
            ToggleBase toggle = timeline.GetMostPreviousInTime(time) as ToggleBase;

            if (toggle != null)
            {
                this.DoPulse(toggle.ToggleValue);
            }
        }
Ejemplo n.º 8
0
        override public void OnPulse(Timeline timeline, double time)
        {
            Layers prev = timeline.GetMostPreviousInTime(time) as Layers;

            if (prev != null)
            {
//				System.Console.Write(time + " : ");
                this.globe.SetLayers(prev.LayerList);
            }
        }
Ejemplo n.º 9
0
        override public void OnPulse(Timeline timeline, double time)
        {
            DisplayMessages dms = timeline.GetMostPreviousInTime(time) as DisplayMessages;

            if (dms == null)
            {
                return;
            }

            this.globe.SetDisplayMessages(dms.Messages);
        }
Ejemplo n.º 10
0
        override public void OnPulse(Timeline timeline, double time)
        {
            WmsImage wi = timeline.GetMostPreviousInTime(time) as WmsImage;

            if (wi == null)
            {
                return;
            }

            this.globe.SetWmsImage(wi.Descriptor, null, 0);
        }
Ejemplo n.º 11
0
		override public void OnPulse(Timeline timeline, double time)
		{
			ViewDirection pvd = timeline.GetMostPreviousInTime(time) as ViewDirection;
			ViewDirection nvd = timeline.GetNextInTime(time) as ViewDirection;

			if (pvd != null)
			{
				if (pvd.SpecForm.Equals("angles"))
					this.playFromAngles(timeline, time, pvd, nvd);
				else if (pvd.SpecForm.Equals("position"))
					this.playFromPosition(timeline, time, pvd, nvd);
			}

		}
Ejemplo n.º 12
0
        override public void OnPulse(Timeline timeline, double time)
        {
            ViewDirection pvd = timeline.GetMostPreviousInTime(time) as ViewDirection;
            ViewDirection nvd = timeline.GetNextInTime(time) as ViewDirection;

            if (pvd != null)
            {
                if (pvd.SpecForm.Equals("angles"))
                {
                    this.playFromAngles(timeline, time, pvd, nvd);
                }
                else if (pvd.SpecForm.Equals("position"))
                {
                    this.playFromPosition(timeline, time, pvd, nvd);
                }
            }
        }
        override public void OnPulse(Timeline timeline, double time)
        {
            VerticalExaggeration pve =
                timeline.GetMostPreviousInTime(time) as VerticalExaggeration;
            VerticalExaggeration nve =
                timeline.GetNextInTime(time) as VerticalExaggeration;

            if (pve != null && nve != null)
            {
                double alpha = ScriptPlayer.ComputeAlpha(time - pve.Time, pve, nve);
                double span  = nve.Exaggeration - pve.Exaggeration;
                double ve    = pve.Exaggeration + alpha * span;

                this.globe.SetVerticalExaggeration(ve);
            }
            else if (pve != null)
            {
                this.globe.SetVerticalExaggeration(pve.Exaggeration);
            }
        }
		override public void OnPulse(Timeline timeline, double time)
		{
			VerticalExaggeration pve =
				timeline.GetMostPreviousInTime(time) as VerticalExaggeration;
			VerticalExaggeration nve =
				timeline.GetNextInTime(time) as VerticalExaggeration;

			if (pve != null && nve != null)
			{
				double alpha = ScriptPlayer.ComputeAlpha(time - pve.Time, pve, nve);
				double span = nve.Exaggeration - pve.Exaggeration;
				double ve = pve.Exaggeration + alpha * span;

				this.globe.SetVerticalExaggeration(ve);
			}
			else if (pve != null)
			{
				this.globe.SetVerticalExaggeration(pve.Exaggeration);
			}
		}