Results 1 to 10 of 10

Thread: OpenGL Texture Mapping [Equirectangular 2 Azimuthal Equidistant]

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #4

    Default

    Quote Originally Posted by Redrobes View Post
    But looking at the image I dont think that is your issue. What it looks like to me is the gourand shader for opengl where it will linearly ramp the texture coord from one vertex to another. If you have texture coords that run from say 0 to 1 around the globe and your last face has vertexes with texture coord of 0.95 on the left and 0 on the right then that last face is going to shade the whole texture map around. What you need is probably a duplicated set of vertices on the seam with a texture coord of 1.0 so it maps back to the 0. I.e. you now have 0.95 on the left and 1.0 on the right.
    Thanks for that Redrobes, I looked ito the problem and it is exactly that. Here are some pictures I made with MATLAB. I have put a screenshot my program from the same aspect next to it. The blue quadrilaterals are where the texture coordinates where seperated by more than some threshold (i.e. they have wrapped around).
    [img] http://dl.dropbox.com/u/49415695/1.PNG [/img]
    [img] http://dl.dropbox.com/u/49415695/2.PNG [/img]
    [img] http://dl.dropbox.com/u/49415695/3.PNG [/img]

    I made an attempt at correcting by adding 1 to the smaller of the coordinates but this didn't seem to correct the problem, but I still need to try a few things.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	1.PNG 
Views:	563 
Size:	346.7 KB 
ID:	46965  
    Last edited by felixrulz; 07-27-2012 at 03:50 AM. Reason: tried to delete atachment

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •