Android GLUT does not have many functionalities, and sphere generation is the lacking one. I believe you'll have to generate the vertices and indices buffer manually.

What I have done with sky dome ( half a sphere ) is something like this. Unfortunately, my coworker did the maths, so I can only give you the idea:

Using java Syntax Highlighting

vertices = new float[NUM_VERTICES];

voffset = 0;

y = 0;

radius = 100.0f;

while( y < HEIGHT )

{

voffset += generateCircleVertices( vertices, voffset, y, radius );

radius -= 1.0f;

y += 1.0f;

}

indices = generateSkyDomeIndices();

int generateCircleVertices( float[] arr, int offset, float y, float r )

{

< use your maths to generate a number of vertices of a circle >

< the more vertices, the nicer the dome will look >

}

short[] generateSkyDomeIndices()

{

< lots of brain work here >

}

Parsed in 0.031 seconds, using

GeSHi 1.0.8.4