Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 7 of 7

Thread: texture lost

  1. #1
    Junior Member Newbie
    Join Date
    Feb 2000
    Posts
    4

    texture lost

    hi,
    I displayed texture-mapped model and no texture-mapped model. But first i displayed the texture-mapped model correctly, then change to display the no-texture model, it's all right.
    But when i change to display the texture mapped model again, the texture almost disappear--it is also a simple model. Only when rotating the model I notice some triangle edge with color.
    I thought this is the buffer problem, but i do not know how to solve it?
    thanks.

    [This message has been edited by sujin (edited 02-16-2000).]

  2. #2
    Intern Contributor
    Join Date
    Feb 2000
    Location
    Italy
    Posts
    77

    Re: texture lost

    Your explanation is not of very much help, but I will try anyway to give you a checklist.
    Firstly, what do you mean by switching a 'model' ? I assume that you're enabling and disabling GL_TEXTURE_2D; if you are using two completely different objects, let me know.
    Anyway you should check:
    - state changes affecting GL_TEXTURE_2D
    - texture params, such as GL_TEXTURE_MAG_FILTER, GL_TEXTURE_MIN_FILTER, wrapping, etc.
    - texture environment params, such as mode
    - texture coordinates; are you using generation?
    --
    Paolo M.

  3. #3
    Junior Member Newbie
    Join Date
    Feb 2000
    Posts
    4

    Re: texture lost

    what is the option
    ?
    - texture environment params, such as mode texture coordinates; are you using generation?
    Anyway I know how to display a texture mapped object correctly.

    I use a SDI VC program, then i save a 3D geometry model(including its coordinates, its texture coordinates).

    If i display the object without drawing any line or others, it will display correctly. Then i can only disply the object without texture.
    But after then i want to display the textured object, the texture disappear.
    the display change by click a button, following set a flag: mTexFlag=true or mModelFg=true.
    that's all.

  4. #4
    Intern Contributor
    Join Date
    Feb 2000
    Location
    Italy
    Posts
    77

    Re: texture lost

    Mmhh. I'm still confused.
    Can you post a code snippet, where the rendering and state change happen?
    --
    Paolo M.

  5. #5
    Member Regular Contributor
    Join Date
    Feb 2000
    Location
    milano, italy
    Posts
    282

    Re: texture lost

    normally when texturing, the underlying color is set to white (glColor3f(1,1,1))

    since you're rendering a textured model, then a non-textured one and then again you use textures, maybe you forgot to set the color/material again to white...
    or maybe is a lighting problem.

    try to render your models without texturing, without lighting and color set to white to see what happens.

    Dolo/\/\ightY



    [This message has been edited by dmy (edited 02-17-2000).]
    Dolo/\/\ightY

  6. #6
    Junior Member Regular Contributor
    Join Date
    Feb 2000
    Location
    Brisbane,QLD, Australia
    Posts
    101

    Re: texture lost

    [QUOTE]Originally posted by sujin:

    I use a SDI VC program, then i save a 3D geometry model(including its coordinates, its texture coordinates).
    ------------------------------------

    Whats this programme called? Where can I get it?

    Thanks
    Dan S.

  7. #7
    Junior Member Newbie
    Join Date
    Feb 2000
    Posts
    4

    Re: texture lost

    It seems no buffer using tricks in texture mapping. I solved my problem this morning, it's too simple for i define the polygon mode to GL_LINE and when using texture , i forgot to set the mode to GL_FILL!
    thanks for oyur response.

Posting Permissions

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