binding 2d textures
I want to use glGenTextures and glBindTextures to create some simple textures, but I don't have and don't want to use glaux, which nehe's tutorial (which I am currently working through) uses for this purpose. I normally use LoadImage to load a bitmap for my own little projects (they aren't leaving this computer yet...) so I would like to know how to bind an HBITMAP or something to an object. Thanks.
short answer : you cant directly.
longer answer :
You have to give glTexImage*() a pointer to the raw texture data, if you can get that from the HBITMAP then it shouldnt be a problem, however not dealing with HBITMAPs I dont know how todo it off the top of my head.
longer answer :
You have to give glTexImage*() a pointer to the raw texture data, if you can get that from the HBITMAP then it shouldnt be a problem, however not dealing with HBITMAPs I dont know how todo it off the top of my head.
also u might wanna look at another file format instead of bmp as it doesnt handle alpha eg see tga or dds
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement