• Advertisement
Sign in to follow this  

anyone knows sketchup?

This topic is 2354 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm trying to finish a sketchup importer for opengl in c++ .
My problem is that the shaders that rapresent the materials of sketchup are five:
1)front color back color
2)front color back texture
3)texture front, back color
4)double color
5)double texture.

in these shaders i use the gl_frontfacing (that return true if the face is front and false if the face is back )for draw the different materials.
For example ,in case 2: in the pixel shader:

gl_color = frontColor
gl_color = texture color


I see that the gl_frontFacing return true if the vertexes are in counterclockwise order or the opposite, i'm not remember good, The problem is that in my importer i have some faces that are counterclockwise and others that are clockwise , then i get a wrong model.
I think that the problem is the indexes order of the vertexes , how i can get all the faces in an unique wind order?

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement