Performance problem

General discussion about LÖVE, Lua, game development, puns, and unicorns.
User avatar
TsT
Party member
Posts: 161
Joined: Thu Sep 25, 2008 7:04 pm
Location: France
Contact:

Performance problem

Post by TsT »

After reading this post :
Tenoch wrote:Well, the "official" ubuntu deb of Löve works with Ubuntu on the Eee. (I run Ubuntu-eee, but i'm pretty sure it's really the same).

Unfortunately, perfs are terrible. I don't know the reason, but i suppose it has to do with the fact that Löve relies on OpenGL and hardware acceleration for everything. Almost all "real time" demos posted here have a FPS so low it becomes unplayable.
This is too bad since the Eee has a quite correct processor, and plays "pure" SDL games really fine.
Maybe we'd need a "SDL render" option in Löve, even if it would propose less features (like this really neat seamless rotation and zoom of sprites). But I don't know if it would need a lot of work or not. I think i reaad somewhere that Löve didn't even use SDL_Surface at all, so I guess it would need a lot of rewriting.

Too bad. For now I'm back to plain old SDL calls, and wrapping stuff in Lua...
I'm starting to tell what I got.

I have started to code with love on my personnal laptop computer (~4-5 years old, with nvidia gforce ...) I got a very good performance like more than 1000 FPS on a very simple love sample, and between 100-250 FPS with my actual game.

After that I have checked on 2 office computers (less than 2 years old).
1 (workstation) Dell optiplex 755 and 1 (laptop) Dell Latitude D620,
both have Intel Graphics Controller.

And both I got less than 100 FPS on sample and 2-3 FPS with my game !

Is it a bug or love need a "true" 3d accelerated chipset ?


Some technical details :

Code: Select all

00:02.0 VGA compatible controller: Intel Corporation 82Q35 Express Integrated Graphics Controller (rev 02)
00:02.1 Display controller: Intel Corporation 82Q35 Express Integrated Graphics Controller (rev 02)

Code: Select all

00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller (rev 03)

glxgears -info
GL_RENDERER   = Mesa DRI Intel(R) 945GM 20061017 x86/MMX/SSE2
GL_VERSION    = 1.3 Mesa 7.0.4
GL_VENDOR     = Tungsten Graphics, Inc
GL_EXTENSIONS = GL_ARB_depth_texture GL_ARB_fragment_program GL_ARB_imaging GL_ARB_multisample GL_ARB_multitexture GL_ARB_point_parameters GL_ARB_shadow GL_ARB_texture_border_clamp GL_ARB_texture_compression GL_ARB_texture_cube_map GL_ARB_texture_env_add GL_ARB_texture_env_combine GL_ARB_texture_env_crossbar GL_ARB_texture_env_dot3 GL_ARB_texture_mirrored_repeat GL_ARB_texture_rectangle GL_ARB_transpose_matrix GL_ARB_vertex_buffer_object GL_ARB_vertex_program GL_ARB_window_pos GL_EXT_abgr GL_EXT_bgra GL_EXT_blend_color GL_EXT_blend_equation_separate GL_EXT_blend_func_separate GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_clip_volume_hint GL_EXT_cull_vertex GL_EXT_compiled_vertex_array GL_EXT_convolution GL_EXT_copy_texture GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_histogram GL_EXT_multi_draw_arrays GL_EXT_packed_pixels GL_EXT_point_parameters GL_EXT_polygon_offset GL_EXT_rescale_normal GL_EXT_secondary_color GL_EXT_separate_specular_color GL_EXT_shadow_funcs GL_EXT_stencil_wrap GL_EXT_subtexture GL_EXT_texture GL_EXT_texture3D GL_EXT_texture_edge_clamp GL_EXT_texture_env_add GL_EXT_texture_env_combine GL_EXT_texture_env_dot3 GL_EXT_texture_filter_anisotropic GL_EXT_texture_lod_bias GL_EXT_texture_object GL_EXT_texture_rectangle GL_EXT_vertex_array GL_3DFX_texture_compression_FXT1 GL_APPLE_client_storage GL_APPLE_packed_pixels GL_ATI_blend_equation_separate GL_IBM_rasterpos_clip GL_IBM_texture_mirrored_repeat GL_INGR_blend_func_separate GL_MESA_pack_invert GL_MESA_ycbcr_texture GL_MESA_window_pos GL_NV_blend_square GL_NV_light_max_exponent GL_NV_texture_rectangle GL_NV_texgen_reflection GL_NV_vertex_program GL_NV_vertex_program1_1 GL_OES_read_format GL_SGI_color_matrix GL_SGI_color_table GL_SGIS_generate_mipmap GL_SGIS_texture_border_clamp GL_SGIS_texture_edge_clamp GL_SGIS_texture_lod GL_SGIX_depth_texture GL_SUN_multi_draw_arrays

My projects current projects : dragoon-framework (includes lua-newmodule, lua-provide, lovemodular, , classcommons2, and more ...)
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Performance problem

Post by rude »

A long shot, but could it be that you're using line stipple?
User avatar
TsT
Party member
Posts: 161
Joined: Thu Sep 25, 2008 7:04 pm
Location: France
Contact:

Re: Performance problem

Post by TsT »

rude wrote:A long shot, but could it be that you're using line stipple?
Not at all. And I got same little poor performance with a simple love.graphics.rectangle(...)

This is my complete list of love functions called (maybe not really usefull :D)

Code: Select all

love.graphics.circle(
love.graphics.draw(
love.graphics.drawf(
love.graphics.getHeight(
love.graphics.getLineWidth(
love.graphics.getWidth(
love.graphics.line(
love.graphics.newFont(
love.graphics.newImage(
love.graphics.rectangle(
love.graphics.setCaption(
love.graphics.setColor(
love.graphics.setColorMode(
love.graphics.setFont(
love.graphics.setLine(
love.graphics.setLineStyle(
love.graphics.setLineWidth(
love.graphics.setScissor(
love.graphics.triangle(
love.mouse.getPosition(
love.mouse.getX(
love.mouse.getY(
love.mouse.isDown(
love.mouse.isVisible(
love.mouse.setPosition(
love.mouse.setVisible(
love.system.exit(
love.system.grabInput(
love.timer.getFPS(
I will try to make some sample to see if one function than consume very more resource than others.

To be continue...
My projects current projects : dragoon-framework (includes lua-newmodule, lua-provide, lovemodular, , classcommons2, and more ...)
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Performance problem

Post by rude »

If you get horrible performance even on a simple shape program, then maybe you should start testing some other OpenGL apps.

Thanks for providing information about VGA-controllers etc -- I'll start logging this for future use.

(Line stipple: there is a bug in the OpenGL-implementation on my laptop [XP, ATI X1250] which brings performance down to 1-2 FPS when using line stipple, regardless of the script complexity.)
User avatar
TsT
Party member
Posts: 161
Joined: Thu Sep 25, 2008 7:04 pm
Location: France
Contact:

love benchmark

Post by TsT »

Hello,

I have built a simple love benchmark to show my performance problem.
perftest.love
simple love benchmark ; perftest v0.2 20081030
(13.5 KiB) Downloaded 514 times
On my personnal (little old) laptop I got :
Good perf!
Good perf!
hight.png (21.35 KiB) Viewed 11751 times
On my office (not really old) laptop, I got :
Poor perf : 22FPS for 35 rectangles!
Poor perf : 22FPS for 35 rectangles!
slow.png (16.67 KiB) Viewed 11750 times
And you what FPS result do you have ?

Regards,
My projects current projects : dragoon-framework (includes lua-newmodule, lua-provide, lovemodular, , classcommons2, and more ...)
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: Performance problem

Post by bartbes »

Don't know if it's windows or the Nvidia driver, however it looks like I've got frame limiter on as I get 60fps everywhere.
u9_
Citizen
Posts: 54
Joined: Thu Oct 23, 2008 7:12 am

Re: Performance problem

Post by u9_ »

Same here. 60fps everywhere, on windows, Nvidia 8600GTS
surtic
Citizen
Posts: 74
Joined: Sat Jul 12, 2008 12:18 am

Re: Performance problem

Post by surtic »

My monitor's refresh rate is 75Hz (yes, a CRT). I'm getting 76 fps.
I am guessing that LCDs with their 60Hz get 60 fps for a reason.

If I add game.conf with vsync=false I get between 976 and 2090 fps.
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Performance problem

Post by rude »

Here are the results on my AMD4400+/Geforce9800GTX:
perf.png
perf.png (17.11 KiB) Viewed 11702 times
Obviously with vsync disabled. Here's a new version of perftest.love with vsync disabled:
perftest.love
(13.6 KiB) Downloaded 469 times
If you still get 60FPS, 75FPS or something which looks like a refresh rate, then your graphics driver is set to "force vsync", and you have to change the setting manually to something like "let the application decide".

I'll post results for more machines later.
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: Performance problem

Post by bartbes »

On Ubuntu Linux 8.10 (clean install), without vsync, Geforce 8500:
perftest.png
perftest.png (14.53 KiB) Viewed 11706 times
surtic wrote:I am guessing that LCDs with their 60Hz get 60 fps for a reason.
I have a 60 Hz CRT

(I know I don't have the best computer...)
Post Reply

Who is online

Users browsing this forum: No registered users and 9 guests