my app is really slow

Started by
5 comments, last by firecast 20 years, 4 months ago
hi! i''m making a game which consists of a map (isometric of course) but the rendering is really slow, how can i improve it? (using DX9) i''m using: - a class for a tile which receives the texture from another class call GRID in which is stored all the terrain textures - a class for a mouse pointer (using Direct3D) - all of my classes ar set as pointers... is there anything i can do? TIA!
This really pisses me off!!
Advertisement
I''m not familiar with DX9,
and without seeing your code i really cant gage what is wrong.

but im gonna take a stab and say that, your program is slow because your misusing the DX9 API,

for instance,

1. creating the device wrong, using only software mode or somthing
2. using too many or too few verticies in a given vertex buffer.
3. making too many texture (switches?) requiring the hard ware to do alot of unneccisary information transfer work,

again like i said, this is a stab in the dark, i would check some online tutorials (let google be your guide) how to properly setup DX9 for the kind of rendering your going to be doing.

hope that helps=)



Raymond Jacobs,

www.EDIGames.com

www.EtherealDarkness.com

Raymond Jacobs, Owner - Ethereal Darkness Interactive
www.EDIGames.com - EDIGamesCompany - @EDIGames

some points for you to check:

1.check that you are not loading each frame any file (textures/map).
2.check that you are not rendering all map, you should render only the visible parts.
3.IMMEDIATE or DEFAULT?
1. Profile
2. Profile
3. Profile

[ Start Here ! | How To Ask Smart Questions | Recommended C++ Books | C++ FAQ Lite | Function Ptrs | CppTips Archive ]
[ Header Files | File Format Docs | LNK2001 | C++ STL Doc | STLPort | Free C++ IDE | Boost C++ Lib | MSVC6 Lib Fixes ]
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan
what do you mean with IMMEDIATE or DEFAULT???
i''m not loading the texture the frames every frame, it''s loaded at the constructor, but i''m using a vertex buffer for each cell... how could i use just one VB in all the grid...maybe that''s what''s slowing it down... hehe
since the grid is 20 x 20 cells
This really pisses me off!!
IMMEDIATE and DEFAULT are passed to the function that creats the d3d device, check presentation interval.
One of my trial-run programs was running really slowly until I noticed that I was rebuilding every vertex from a master array each cycle = waste of processing time.

You mentioned you had a tile class... this sounds kinda similiar to what I did... if you''re converting each tile into vertex coordinates each cycle you''re gonna get really bogged down really fast.

This topic is closed to new replies.

Advertisement