Results 1 to 6 of 6

Thread: how to flip a texture for a skybox ?

  1. #1
    Senior Member Regular Contributor
    Join Date
    Apr 2003
    Location
    France
    Posts
    112

    how to flip a texture for a skybox ?

    the thing is: i got a sphere all around my scene, and i applied a texture on it; but the texture is oriented to the outside and so it appeared really darkened inside .... how can i flip it to have it clear inside ?
    thx a lot - wizzo
    You snooze, you loose

  2. #2
    Senior Member Frequent Contributor
    Join Date
    Apr 2003
    Posts
    680

    Re: how to flip a texture for a skybox ?

    the texture is for sure on both sides, but you seem to have backface culling enabled, which in this case culls the wrong face of the polygons, so change this, or disable backface culling for the sky dome.

  3. #3
    Senior Member Regular Contributor
    Join Date
    Apr 2003
    Location
    France
    Posts
    112

    Re: how to flip a texture for a skybox ?

    ok i'll try this
    thx a lot for helping
    You snooze, you loose

  4. #4
    Member Newbie
    Join Date
    Jan 2003
    Location
    Belgrade, Serbia
    Posts
    35

    Re: how to flip a texture for a skybox ?

    You sad darkened? Seems to me that the sphere normals are pointing outside. If you are using glut function, there's no way to make them point inside; but you can change the orientation of the triangles in your sphere - something like GL_CW (clock-wise).
    DARKO

  5. #5
    Senior Member Frequent Contributor
    Join Date
    Apr 2003
    Posts
    680

    Re: how to flip a texture for a skybox ?

    the problem with the normals is surely another point and is not "easy" to solve, but i would not render the sky dome with lighting enablend anyway.. the light sources in your 3d scene normally do not affect the lighting of the sky, so it will probably look very unrealistic to render the sky dome with the world lighting properties.

  6. #6
    Senior Member Regular Contributor
    Join Date
    Apr 2003
    Location
    France
    Posts
    112

    Re: how to flip a texture for a skybox ?

    that's alright i found my problem was related to my old post... that was finally a "problem" in my tga loader function: i had the third parameter at GL_MODULATE, which explain the darkness; for all those who had this problem (i heard they are some), juste change GL_MODULATE into GL_REPLACE.
    i feel better with that problem solve, thx to you all for helping me
    You snooze, you loose

Similar Threads

  1. Skybox texture error
    By Jippie in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 01-21-2018, 04:23 AM
  2. DDS Inverted - How to flip over the texture?
    By doodlemunch in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 02-24-2007, 03:01 AM
  3. Skybox help and texture map source
    By in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 02-21-2005, 01:57 AM
  4. How to flip a texture via the texture matrix?
    By Diapolo in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 05-18-2001, 07:02 PM
  5. glHint and skybox texture problem
    By in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 02-11-2001, 07:29 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean