public static void InitStarVertexBuffer(RenderContext renderContext) { if (!starsDownloading) { GetStarFile("http://www.worldwidetelescope.org/wwtweb/catalog.aspx?Q=hipparcos"); starsDownloading = true; } if (starSprites == null && starCount > 0) { double ecliptic = Coordinates.MeanObliquityOfEcliptic(SpaceTimeController.JNow) / 180.0 * Math.PI; int count = stars.Count; starCount = count; starSprites = new PointList(renderContext); starSprites.DepthBuffered = false; foreach (Star star in stars) { Vector3d pos = Coordinates.RADecTo3dAu(star.RA, star.Dec, star.Distance); pos.RotateX(ecliptic); star.Position = pos; double radDec = (1200000) / Math.Pow(1.6, star.AbsoluteMagnitude); starSprites.AddPoint(pos, star.Col, new Dates(0, 1), (float)radDec * 100); } } }