Added a "front" view option (Y, Z plane).
Added a "front" view option (Y, Z plane).
Working on fixing the hub generation. It appears to be favoring x & y
near zero.

file:a/Galaxy.cs -> file:b/Galaxy.cs
--- a/Galaxy.cs
+++ b/Galaxy.cs
@@ -39,13 +39,14 @@
 			
 			for (int i = 1; i <= NumStars; ++i)
 			{
-				double Radius = rand.NextDouble() * rand.NextDouble() * GalaxyRadius;
+				double Radius = rand.NextDouble() * (double)GalaxyRadius;
 				double Phi, Theta;  // Rotational angles for some spherical coordinates.
 				double x, y, z;  // Cartesian coordinates, maybe?
 				
 				// If the radius puts the star outside the Hub (be fuzzy), we need to align it in an arm.
 				if (Radius > (HubRadius + rand.NextDouble() * ( rand.NextDouble() * 2 - 1 ) * ( DiskRadius - HubRadius)))
 				{
+					Radius = Radius * rand.NextDouble();
 					// This spiral algorithm was taken from the python Galaxy Generator found here: http://www.ailis.de/~k/archives/29-Galaxy-Generator.html
 					// Rotate the star by the specified number of rotations, then
 					// multiply by the proportional distance from center to give
@@ -58,21 +59,25 @@
 					             // Then add some extra "fuzz".
 					             + (rand.NextDouble() * 2d - 1d) * (double)Fuzz);
 					
-					z = rand.NextDouble() * Math.Sin(Phi) * (double)HubRadius * Math.Pow((Radius / (double)GalaxyRadius),3);
+					z = (2d * rand.NextDouble() - 1d) * (double)HubRadius * ( Math.Pow (( 1 - (Radius / (double)GalaxyRadius) ), 4 ) 
+						+ (rand.NextDouble() * 2d - 1d) * (double)Fuzz);
 					Theta = Math.Acos (z / Radius);
+
+					// Find the x, y cartesians from r and phi.
+					x = Math.Cos(Phi) * Radius;
+					y = Math.Sin(Phi) * Radius;
 				}
 				// If the star is not in an arm, the distribution should be spherical.
 				else
 				{
 					Phi = rand.NextDouble() * TwoPi;
-					Theta = rand.NextDouble() * TwoPi;
-					z = Math.Cos(Theta) * Math.Sin(Phi) * Radius;
+					Theta = rand.NextDouble() * Math.PI;
+
+					z = Math.Cos(Theta) * Radius;
+					x = Math.Sin(Theta) * Math.Cos(Phi) * Radius;
+					y = Math.Sin(Theta) * Math.Sin(Phi) * Radius;
 				}
-				
-				// Find the x, y cartesians from r and phi.
-				x = Math.Cos(Phi) * Radius;
-				y = Math.Sin(Phi) * Radius;
-				
+
 				AddStar(new Star(x, y, z));
 			}
 		}

--- a/PngRenderer.cs
+++ b/PngRenderer.cs
@@ -35,6 +35,10 @@
 				case "side":
 					p1 = (int)star.getCoords().getZ();
 					break;
+				case "front":
+					p0 = (int)star.getCoords().getY();
+					p1 = (int)star.getCoords().getZ();
+					break;
 				default:
 					ThrowException(ERR_INVALID_VIEW);
 					break;
@@ -64,6 +68,9 @@
 				break;
 			case "side":
 				filename = prefix + "side.png";
+				break;
+			case "front":
+				filename = prefix + "front.png";
 				break;
 			default:
 				ThrowException(ERR_INVALID_VIEW);

 Binary files a/bin/Release/CleanExceptionHandler.dll and b/bin/Release/CleanExceptionHandler.dll differ
 Binary files a/bin/Release/NDesk.Options.dll and b/bin/Release/NDesk.Options.dll differ
 Binary files a/bin/Release/galaxy_generator.exe and b/bin/Release/galaxy_generator.exe differ