forums

TNT Basic Forums > Programming Q&A
Hardware mode not working
< Last Thread     Next Thread >
Author
Thread        Post A Reply

07-19-2006 04:02

Posted by:
Stu

Location:
USA

Click Here to Email Stu   Find more posts by Stu

I've just been using regular graphics mode up to now, but I'd like to be able to use sprite scaling and rotating functions. I tried using "graphics mode hardware", but it all runs very slowly, and some of my images refuse to load (they appear as green boxes about the size of the sprite mask). Is there something else I need to put in the code? Is it some other problem? I'm running TNT 1.31 on an iMac G4 with Mac OS 10.3.9.

07-19-2006 15:32

Posted by:
someone

Location:
Quebec ( Canada )

Click Here to Email someone   Find more posts by someone

as for the speed, hardware mode is known to be slower than software mode. However, if you could post your code, maybe we could see ways of improving it.

As for the green boxes... all software mode code should work as well in hardware mode. Either it is a bug, either the imge you're using is incompatible with OpenGL (?) try saving your images as uncompressed TGAs (if you compressed the colors that may be a reason i think?) there seeing the project file could help

07-19-2006 18:19

Posted by:
Stu

Location:
USA

Click Here to Email Stu   Find more posts by Stu

Well, if it is going to be that much slower...

The speed at which it was running was far too slow for me to bother to try to run it in hardware mode. That's really a shame. I suppose that I can just save my images twice, facing each direction to get around the flip sprite function. Thanks for the help!

07-19-2006 22:17

Posted by:
swagIT

Location:
Great Wet North (Vancouver)

Find more posts by swagIT

Interestingly enough - I have found that Hardware Mode while slower than Software Mode on newer Macs, is WAY faster on older macs.

for example the same program:

Software mode
runs 60+ fps in software mode on a newer Mac
Runs between 7 and 20 fps on a 400 mhz G4

Hardware mode
runs 40-60+ fps in hardware mode on a newer Mac
Runs between 30 and 40 fps on a 400 mhz G4

Maybe something to keep in mind when building small games for public consumption. Many people don't upgrade their Mac every year or so

Just a thought

cheers

barry


07-20-2006 14:45

Posted by:
someone

Location:
Quebec ( Canada )

Click Here to Email someone   Find more posts by someone

well, hardware mode is still to improve a lot... but still there might be ways to imrpove your code. hardware mode is slower, but rarely so slow it's unplayable!

well, i don't know

07-20-2006 18:10

Posted by:
Stu

Location:
USA

Click Here to Email Stu   Find more posts by Stu

Well, there isn't much code in the program. Pretty much all it does so far is to display a picture, a few buttons, and a sprite for a cursor. I've saved my other sprite images twice, so that I won't need the sprite flip function. I don't think that there will be any other added benefits to using hardware mode for my game.

All times are GMT        Post A Reply

Forum Jump:
< Last Thread     Next Thread >

< Contact Us - TNT Basic >

Powered by: vBulletin Lite Version 1.0.1 Lite
Copyright © Jelsoft Enterprises Limited 2000.