Advertisement

Simple RGB Color/Texture question (hopefully)

Started by June 01, 2000 01:45 AM
1 comment, last by ichor 24 years, 5 months ago
I''ve just started learning OpenGL, and I''ve been following the NeHe tutorial to learn. However, I''m having problems between tutorial 5 and tutorial 6. I completed tutorial 5, and made the quad for the bottom of the triangle, and it looks fine, as does the cube. Now I''ve done the tutorial #6, but I wanted to keep the spinning triangle next to the textured cube. That''s where the problems started. I can get both the triangle and the cube to show up and spin, but the triangle *only* has the color of the FIRST color (top left) of whatever is in the bitmap texture... So, if it''s green, the triangle is green...and if it''s black, the triangle isn''t visible. I still have the glColor3f()''s before drawing each side of the triangle... How do I fix this so that the textures remain on the cube, and the triangle still contains its RGB colors?
Once you enable textures, everything is textured until it is disabled.

Here''s how you should do it:
Enable textures
Draw the cube
Disable textures
Draw the pyramid

Eric Laberge
----------------------------------------"Inash neteia haeg joa kavari quilm..." SD4
Advertisement
Hey, thanks! It worked great! I disabled textures when drawing the triangle, and reenabled them for the cube. =)

Thanks again.


Steve

This topic is closed to new replies.

Advertisement