Jump to content
  • Advertisement
Sign in to follow this  
Oni Sephiroth

need some help with bitmaps

This topic is 3620 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

Can someone show me a decent function for loading and drawing a bitmap with the glDrawPixels function? I've tried using several from the internet and textbooks, none of them want to work. Does anyone have one they're willing to share that actually works?

Share this post


Link to post
Share on other sites
Advertisement
What is it you are actually trying to do? I dunno about how fast or slow drawPixels is but my first gut reaction would be to just texture a quad instead.

Share this post


Link to post
Share on other sites
Yea, I eventually want to texture it onto a quad, but I want to see if I can actually get the bitmap to load and display properly first before jumping into texture mapping.

Share this post


Link to post
Share on other sites
Since it's just for looking, I suggest you just jump into texture mapping. You'll have to do it eventually, and it's not rocket science. There are also a lot of tutorials for it (including NeHe, which I can recommend to learn the very basics - don't actually adopt any of it for program architecture - but your first stop should be the Red Book itself).

If you do want to stick to glDrawPixels, post your code and I'll try looking at it to see what could the the problem. Can't promise anything though, I'm not too familiar with how that function works.

Share this post


Link to post
Share on other sites
I actually used Nehe's tutorial already, which didn't work due to the lack of the glaux library. Well, give me a minute to type up the function from my book again since I removed it.

Share this post


Link to post
Share on other sites
...Well, this is odd. It seems to be working now. Huh...interesting. I did nothing any differently. Well, good, now I can move onto texture mapping. Thank you for posting, even though it was fixed on its own.

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!