HWSurface

Hello

Should my game use HWSurfaces if the videocard supports them?

Does it increase performance?

Should I let the user choose to disable HWSurfaces when starting the game?

If yes, why??

thank you MandarX------------------------
http://mandarx.xoom.it/index.php?lang=eng

Hi.

I think you should give Bob Pendleton’s SDL articles a read:

This assumes your are talking about SDL 1.2.X

– BrianOn 16 February 2010 09:53, mandarx wrote:

Hello

Should my game use HWSurfaces if the videocard supports them?

Does it increase performance?

Should I let the user choose to disable HWSurfaces when starting the game?

If yes, why??

thank you MandarX

Brian Barrett wrote:

Hi.

I think you should give Bob Pendleton’s SDL articles a read:
http://www.oreillynet.com/pub/au/1205

This assumes your are talking about SDL 1.2.X

– Brian

I read it! it seems it’s better if I let the user choose, because the behaviour of HWSurfaces depends on too many factors!!!

Thanks

MandarX------------------------
http://mandarx.xoom.it/index.php?lang=eng

Users don’t care about hardware surfaces. I would recommend against this.
One of the things about being a designer is to make choices for the user, so
the user can concentrate on what the task they are trying to achieve:

Just run some tests of your game on the kind of minimum hardware you want to
target, see which is faster.

– BrianOn 16 February 2010 12:06, mandarx wrote:

I read it! it seems it’s better if I let the user choose, because the
behaviour of HWSurfaces depends on too many factors!!!

Thanks

MandarX

Brian Barrett wrote:

Users don’t care about hardware surfaces. I would recommend against this. One of the things about being a designer is to make choices for the user, so the user can concentrate on what the task they are trying to achieve:?http://www.joelonsoftware.com/uibook/chapters/fog0000000059.html (http://www.joelonsoftware.com/uibook/chapters/fog0000000059.html)

intresting

Just run some tests of your game on the kind of minimum hardware you want to target, see which is faster.

it seems swsurfaces are faster on my hardware

MandarX------------------------
http://mandarx.xoom.it/index.php?lang=eng

I would say this depends on your target audience. For some people it
seems very inconvenient to have to dig to get at the options they may
want to tweak, and your code can’t always know better than the user.

An interesting real life example of how different technology companies
have dealt with this same sort of question: Each graphics operations,
and even the same operation with different options or different
conditions, may or may not be candidates for hardware acceleration on
different platforms. NVIDIA is known for silently disabling some
features that your hardware can’t accelerate even when your program
asks for them. Automatically making performance decisions without the
user is great for some people, but a lot of those gamers are playing
on iPhone or Flash, and for those platforms it’s easiest and most
effective simply to test on those platforms and use a configuration
that works best on those platforms.

So I would say, make the options accessible somewhere. A plain text
configuration file and/or command-line options helps a lot especially
if certain options cause your game to crash!On Tue, Feb 16, 2010 at 8:02 AM, Brian Barrett <brian.ripoff at gmail.com> wrote:

Users don’t care about hardware surfaces. I would recommend against this.
One of the things about being a designer is to make choices for the user, so
the user can concentrate on what the task they are trying to
achieve:?http://www.joelonsoftware.com/uibook/chapters/fog0000000059.html
Just run some tests of your game on the kind of minimum hardware you want to
target, see which is faster.
– Brian
On 16 February 2010 12:06, mandarx wrote:

I read it! it seems it’s better if I let the user choose, because the
behaviour of HWSurfaces depends on too many factors!!!

Thanks

MandarX


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


http://codebad.com/

Donny Viszneki wrote:

So I would say, make the options accessible somewhere. A plain text
configuration file and/or command-line options helps a lot especially
if certain options cause your game to crash!

Thank you for your answer

now I think that in my case is not important to let the user choose to use hwsurfaces

I realized that when I remebered that I cap the frame rate!!!

but I think that if hwsurfaces can be used it’s a waste not to use them…

so I will make a very easy menu at the start (in zx spectrum style!)

by default the game will run in a window using swsurfaces

but it’ll be possible to start it in fullscreenmode and

if(VideoInfo->hw_available==1) hwsurfaces can be used!

best regards!!!

MandarX------------------------
http://mandarx.xoom.it/index.php?lang=eng

Even when a hardware surface is accelerated, it is not necessarily faster for all purposes.

For example on the Amiga there was a hardware blitter that was fully capable of any 2D drawing operations one might want to do, but for small images the CPU was faster than setting up the blitter to
do the blitting operation, and on faster Amigas it was even more biased.

As an example, a single glDrawRangeElements call can take thousands of cycles depending on state changes, so if a game was rendering a lot of very small images with individual draw calls, that would
be slower than just drawing it directly into a software surface and uploading that.

This is all on a case by case basis of course.On 02/16/2010 07:06 AM, mandarx wrote:

Donny Viszneki wrote:

So I would say, make the options accessible somewhere. A plain text
configuration file and/or command-line options helps a lot especially
if certain options cause your game to crash!

Thank you for your answer

now I think that in my case is not important to let the user choose to
use hwsurfaces

I realized that when I remebered that I cap the frame rate!!!

but I think that if hwsurfaces can be used it’s a waste not to use them…

so I will make a very easy menu at the start (in zx spectrum style!)

by default the game will run in a window using swsurfaces

but it’ll be possible to start it in fullscreenmode and

if(VideoInfo->hw_available==1) hwsurfaces can be used!

best regards!!!

MandarX


http://mandarx.xoom.it/index.php?lang=eng


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


LordHavoc
Author of DarkPlaces Quake1 engine - http://icculus.org/twilight/darkplaces
Co-designer of Nexuiz - http://alientrap.org/nexuiz
"War does not prove who is right, it proves who is left." - Unknown
"Any sufficiently advanced technology is indistinguishable from a rigged demo." - James Klass
"A game is a series of interesting choices." - Sid Meier