Results 1 to 3 of 3

Thread: artefacts with transparency

  1. #1
    Junior Member Newbie
    Join Date
    May 2001
    Location
    aulnay, france
    Posts
    19

    artefacts with transparency

    hi,
    i construct objects 3D composed by severals levels of polygons. each level is a ribbon of gl_triangle_strip.

    i apply transparency to these objects. i can see throw the objects but i have an artefact : separations between each triangle_strip are visible.

    is there something to do with glEdgeFlag() ? (i don't use it )
    how does it works ?

    here is my pseudo-code :

    glBegin(GL_TRIANGLE_STRIP) ;
    for each level {
    Vertices from 1 to 1 ;
    }


    for transparency, i use blending :
    glEnable(GL_BLEND);
    glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);


    thanks.
    phanie

  2. #2
    Senior Member OpenGL Guru Relic's Avatar
    Join Date
    Apr 2000
    Posts
    2,450

    Re: artefacts with transparency

    If you see the edges between individual triangles or triangle strips, that's an indication for drawing those pixels more than once. This normally happens with polygon antialiasing enabled.
    Disable GL_POLYGON_SMOOTH! This will also increase darwing speed.

    Additionally, to have transparency working correctly for 3D objects you have to watch for the drawing order have to sort triangles in z.

    Search for "transparency" on these forums and you'll find lots of hints.

  3. #3
    Junior Member Newbie
    Join Date
    May 2001
    Location
    aulnay, france
    Posts
    19

    Re: artefacts with transparency

    thanks : )
    phanie

Similar Threads

  1. Rendering artefacts on some cards
    By Mace2 in forum OpenGL: Advanced Coding
    Replies: 3
    Last Post: 01-27-2004, 11:49 AM
  2. Stencil Shadows Artefacts.
    By MrShoe in forum OpenGL: Advanced Coding
    Replies: 4
    Last Post: 06-07-2003, 01:24 AM
  3. some artefacts with transparency
    By phanie in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 05-23-2001, 06:46 AM
  4. GL_SMOOTH artefacts
    By Eric in forum OpenGL: Advanced Coding
    Replies: 4
    Last Post: 07-14-2000, 08:22 AM

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