Tag Info

New answers tagged


Your question is similar to what I'm doing , but I'm using libnoise , doing most of the work for me .Can generate 4 faces of a icoespher using libnoise(they fit perfectly in a icoesphere) and saving as bmp, but unfortunately , there must be some wrong in libnoise , which causes distortion in the top faces and down , looked at the code ...


Your line of: glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, width, height, 0, GL_RGB, GL_UNSIGNED_BYTE, image); You should have the GL_TEXTURE_2D replaced with your variable "targets[]" so that as you iterate through your for loop you specify GL_TEXTURE_CUBE_MAP_POSITIVE_X, etc. The changed line would be: glTexImage2D(targets[i], 0, GL_RGB, width, height, 0, ...

Top 50 recent answers are included