Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Slow Frame Rate with a matrix

Author
Message
sgalland
22
Years of Service
User Offline
Joined: 18th Nov 2002
Location: United States
Posted: 15th May 2004 12:33
I was wondering if you can help me figure out why my code is so slow, it runs at about 12 fps, but if I take the matrix out it runs at 49 fps:



Any assistance is greatly appreciated!
Arkheii
21
Years of Service
User Offline
Joined: 15th Jun 2003
Location: QC, Philippines
Posted: 15th May 2004 12:58
Quote: "Make Matrix 1, 200, 200, 50, 50"


Matrices are very slow. Try reducing the size and use one of the "infinite matrix" snippets somewhere.


.::formerly r_kabouter
You're happy cause you smile, but how much can you fake?
Emperor Baal
21
Years of Service
User Offline
Joined: 1st Dec 2003
Location: The Netherlands - Oudenbosch
Posted: 15th May 2004 14:22 Edited at: 17th May 2004 15:19
And you are using 2D (pasting images) real-time

Quote: "
UPDATED

Amd 2800+ 1024mb pc3200 A7N8X - Deluxe Ati Radeon 9800PRO 256mb
"
Mentor
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 15th May 2004 15:32
change make matrix 200,200,50,50 (5000 polys) to make matrix 200,200,20,20 (800 polys), for some reason a matrix slows the game down a lot if you make it too large, yet a 5000 poly model wouldn`t hurt the framerate so much.

Mentor.

PC1: P4 hyperthreading 3ghz, 1gig mem, 2x160gig hd`s, Nvidia FX5900 gfx, 6 way surround sound, PC2: AMD 1.2ghz, 512mb ram, FX5200 ultra gfx, stereo 16 bit soundblaster, ups.
Oneka
21
Years of Service
User Offline
Joined: 24th Apr 2004
Location: Hampton,VA
Posted: 15th May 2004 18:48
thats wierd I use a matrix of 10000,10000,50,50 and have a Fps of 38-42

A 1 man team
Emperor Baal
21
Years of Service
User Offline
Joined: 1st Dec 2003
Location: The Netherlands - Oudenbosch
Posted: 15th May 2004 19:56
what happens if you make it 100,100,50,50 Oneka production?

Quote: "
UPDATED

Amd 2800+ 1024mb pc3200 A7N8X - Deluxe Ati Radeon 9800PRO 256mb
"
Mentor
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 15th May 2004 23:40 Edited at: 15th May 2004 23:42
it`s not the size thats the problem, its the number of elements in it



play with that by altering the values, you can make a matrix as big as you like and it will be ok, but you have to avoid having too many tiles or the speed goes down the tube.

Mentor.

PC1: P4 hyperthreading 3ghz, 1gig mem, 2x160gig hd`s, Nvidia FX5900 gfx, 6 way surround sound, PC2: AMD 1.2ghz, 512mb ram, FX5200 ultra gfx, stereo 16 bit soundblaster, ups.
Emperor Baal
21
Years of Service
User Offline
Joined: 1st Dec 2003
Location: The Netherlands - Oudenbosch
Posted: 17th May 2004 11:18
I thought matrix points that were beyond the camera range weren't calculated.. Oh well (Thats why I told him to make it smaller)

Quote: "
UPDATED

Amd 2800+ 1024mb pc3200 A7N8X - Deluxe Ati Radeon 9800PRO 256mb
"
Arkheii
21
Years of Service
User Offline
Joined: 15th Jun 2003
Location: QC, Philippines
Posted: 17th May 2004 13:55 Edited at: 17th May 2004 14:00
I don't think anything beyond the clip range is rendered, so a physically small matrix with many segments can be very slow.

Login to post a reply

Server time is: 2025-05-23 19:34:54
Your offset time is: 2025-05-23 19:34:54