public Satellites()
        {
            m_satellites        = new List <MotionEvaluator <Cartesian> >();
            m_accessPositions   = new List <Cartesian>();
            m_noAccessPositions = new List <Cartesian>();

            m_accessBatch = new MarkerBatchPrimitive
            {
                Texture = SceneManager.Textures.FromUri(LotsOfSatellites.GetDataFilePath("Markers/Satellite-Red.png"))
            };

            m_noAccessBatch = new MarkerBatchPrimitive
            {
                Texture = SceneManager.Textures.FromUri(LotsOfSatellites.GetDataFilePath("Markers/Satellite.png"))
            };

            SceneManager.Primitives.Add(m_accessBatch);
            SceneManager.Primitives.Add(m_noAccessBatch);
        }
        private void OnLoad(object sender, EventArgs e)
        {
            // Create overlay toolbar and panels
            m_overlayToolbar = new OverlayToolbar(m_insight3D);
            m_overlayToolbar.Overlay.Origin = ScreenOverlayOrigin.BottomCenter;

            // Add additional toolbar buttons

            // Number of Satellites Button
            m_overlayToolbar.AddButton(GetDataFilePath("Textures/OverlayToolbar/manysatellites.png"),
                                       GetDataFilePath("Textures/OverlayToolbar/fewsatellites.png"),
                                       ToggleNumberOfSatellites);

            // Show/Hide Access Button
            m_overlayToolbar.AddButton(GetDataFilePath("Textures/OverlayToolbar/noshowaccess.png"),
                                       GetDataFilePath("Textures/OverlayToolbar/showaccess.png"),
                                       ToggleComputeAccess);

            // Initialize the text panel
            m_textPanel = new TextureScreenOverlay(0, 0, 80, 35)
            {
                Origin             = ScreenOverlayOrigin.TopRight,
                BorderSize         = 2,
                BorderColor        = Color.Transparent,
                BorderTranslucency = 0.6f,
                Color        = Color.Transparent,
                Translucency = 0.4f
            };
            SceneManager.ScreenOverlays.Add(m_textPanel);

            // Show label for the moon
            Scene scene = m_insight3D.Scene;

            scene.CentralBodies[CentralBodiesFacet.GetFromContext().Moon].ShowLabel = true;

            // Create a marker primitive for the facility at Bells Beach Australia
            EarthCentralBody earth = CentralBodiesFacet.GetFromContext().Earth;

            Cartographic facilityPosition = new Cartographic(Trig.DegreesToRadians(144.2829), Trig.DegreesToRadians(-38.3697), 0.0);

            Texture2D facilityTexture = SceneManager.Textures.FromUri(GetDataFilePath(@"Markers\Facility.png"));

            MarkerBatchPrimitive marker = new MarkerBatchPrimitive(SetHint.Infrequent)
            {
                Texture = facilityTexture
            };

            marker.Set(new[] { earth.Shape.CartographicToCartesian(facilityPosition) });

            SceneManager.Primitives.Add(marker);

            PointCartographic point     = new PointCartographic(earth, facilityPosition);
            Axes           topographic  = new AxesNorthEastDown(earth, point);
            ReferenceFrame facilityTopo = new ReferenceFrame(point, topographic);

            m_fixedToFacilityTopoEvaluator = GeometryTransformer.GetReferenceFrameTransformation(earth.FixedFrame, facilityTopo);
            Axes temeAxes = earth.TrueEquatorMeanEquinoxFrame.Axes;

            m_temeToFixedEvaluator = GeometryTransformer.GetAxesTransformation(temeAxes, earth.FixedFrame.Axes);
            m_showAccess           = true;
            m_satellites           = new Satellites();
            CreateSatellites("stkSatDb");

            // This Render() is needed so that the stars will show.
            scene.Render();
        }