Simple texture mapping example needed

BlitzMax Forums/BlitzMax OpenGL Programming/Simple texture mapping example needed

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

I figured out what's going on, though I don't have a fix yet.

my_texture = GLTexFromPixmap(pixmap)

works fine. The second parameter (indicating if mip-maps should be generated) defaults to true. When I set it to false:

GLTexFromPixmap(pixmap, false)

then the resulting texture is a solid color. That My's the reason my texture mapping was broken. I verified this on both OS X and Windows XP with different video cards, so it looks like a Blitz issue. I'll see if I can come up with a fix and report back.

UPDATE: This looks like the classic OpenGL problem of not changing the default filter from GL_NEAREST_MIPMAP_LINEAR when you don't have mipmaps. I forgot all about this. Argh.