Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Sphet

Tilesets and Windowed mode.

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

the method of using LoadImage/GetDC is the method i use. if you are concerned with wide surface support (i remember reading somewhere that in dx5+ it was no longer an issue, or at least not much of an issue, because you can always create surfaces in system memory), then i will suggest the following...

the use of LoadImage/GetDC is still a perfectly suitable way to do the image conversion. however, nobody ever said that you have to blit the ENTIRE bitmap image onto the surface. you could just blit a portion of it, lock that surface, and pull the image data out of it (thus saving yourself the trouble of writing your own conversion code). so, you could work with just a single surface, BitBlt the bitmap onto it however many times you need to to get all of the image data out and into whatever user-defined structure you want. of course, you'll then have to write custom blitting code, and make special code for allowing transparency and whatnot.

Share this post


Link to post
Share on other sites
Advertisement
Uhh.. if I have a windowed directX game using tiles, I can only create directX surfaces that are as big as the smallest screen size I want to support (640x480). Anything larger than that and the surface creation will fail. I would use my own memory for my tiles to overcome this problem, except I am relying on the LoadBitmap/GetDC method of converting from 24 bit to 16 and icky 8 bit mode. Anyone else trying to deal with this? Some of my tiles are 128x128 which means I can get 15 tiles in a 640x480 area. I am going to need tones of surfaces for this to work. Or should I use my own memory / bitmap manager and do the 24 to 16 bit conversion myself, ignoring 8 bit mode for now (maybe later include 8bit specific graphics which would look better than the WinAPI 24 to 8bit conversion anyways)?

erg.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

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

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!