Texture makes entire scene Black and White? OpenTK
I have a texture where it is a 4x4 grid in a 256x256 pixel jpg. If i use that picture for my texture, my entire scene turns black and white. However if I use a different pattern, a checkerboard, the scene has color again. I did make the 2nd texture in GIMP if that has something to do with it. I have quite a lot of code so If anyone has an idea what could be the problem that would be awesome. Otherwise, I will paste bin the code so that you can probably find the one thing I missed lol.
Basically, I just followed the StencilCSG OpenTK example for loading a jpg. I also us开发者_Go百科ed the wrap modes for textures. It seems like if I just use some random texture from Google Images it works but my own textures make it all black and white. I think it has to do with how GIMP saves the files in SRGB but idk.
EDIT:
I found a work around right after I decided to post a question. I just disable textures after I render my textured square. I found a FAQ for opengl textures that said to disable and enable when needed. This works but I didnt think you needed to do that. Anyway, I would still love to know what was happening behind the scenes to make my scene black and white.
Solution, turn off textures after you render all of your textured polys.
精彩评论