Posted 01 November 1999 - 07:52 PM
The other suggestion I have (if you're not already using it) is to draw your map to a memory buffer instead of directly to the back buffer. This removes the need for your alpha function to look up video memory, which will save time. Once you've applied your alpha (or lookup table, this should speed up either) to the memory buffer, use BltFast to draw it to the back buffer for best results (this way system -> video hardware acceleration will be used also, if available). If you're drawing your map with a lot of overlap, this might even speed up your initial framerate. Then again, it may also drop it if you aren't drawing a lot of overlap, but in the case of the alpha blending it's worth a try to see if it helps things. It does depend on other factors of your program and hardware, so play around with it and see what you come up with.
Good luck, and post back to the thread if you need any further help.
[This message has been edited by Starfall (edited November 02, 1999).]
Expecting fast full screen non accelerated alpha is a bit unrealistic, but I think you can do better than 5fps. However, if you just want to make the map a dark tint of blue as you say, I'd suggest you make a routine to shift down the red and green values of the pixels in question. If you have 128k memory to blow, you can even make a lookup of pixels (ie. unsigned short blue_tint) then precalculate the new pixel value for each of the 65536 possible pixels. This would likely be a little faster still. It's not going to run at 75fps, but implemented properly it will be a big improvement over 5fps. If you only want to run this on your computer you could, as Mason suggested, use your 3D card's acceleration, but I highly recommend you include a software mode if you're planning on other people using your program.