Optimize sphere generation

Use hash to get vertex indices for faces array. Also eliminates
duplication of vertices between faces that share a vertex.