Sphere Texture Mapping shows visible seams
        Posted  
        
            by 
                AvengerDr
            
        on Game Development
        
        See other posts from Game Development
        
            or by AvengerDr
        
        
        
        Published on 2014-05-31T13:49:58Z
        Indexed on 
            2014/05/31
            16:05 UTC
        
        
        Read the original article
        Hit count: 476
        
As you can see from the above picture there is a visible seam in the texture mapping. The underlying mesh is a geosphere based on octahedron subdivisions. On that particular latitude, vertices have been duplicated. However there still is a visible seam.
Here is how I calculate the UV coordinates:
float longitude = (float)Math.Atan2(normal.X, -normal.Z);
float latitude = (float)Math.Acos(normal.Y);
float u = (float)(longitude / (Math.PI * 2.0) + 0.5);
float v = (float)(latitude / Math.PI);
Is this a problem in the coordinates or a mipmapping issue?
© Game Development or respective owner