PDA

View Full Version : mapping and FPS


D@rk_BLu3
10-07-2002, 07:00 AM
Well,thats sort of a strange problem.I created a map but the fps are extremely low for its density (you know,effects etc...).In the actual game I have 80 to 100 FPS (AMD 1800+,GF4 Ti 4200)and in my map I have 23-40 FPS!!!!!!!!

Does anyone know what's going on?
:confused: :confused: :confused:

Leslie Judge
10-07-2002, 08:05 AM
Hmm... It can be that the game has to always render the whole map... Try r_showtris 1 in the console to see what the game is actually drawing.

If your map is small then I don't know...

D@rk_BLu3
10-07-2002, 08:40 AM
no,its quite big.I thought that was the prob,but I dont know how to overcome it.Supposing it does render the entire map,then what I do?

jalisko
10-07-2002, 09:58 AM
There could be many different reasons, it's hard to tell you what to do without having seen at least one screenie of the map, or the r_speeds data.

Some stuff that uses to happen:

- You didn't pass the vis stage at compiling (ahem... I had to mention it, sorry)

- Your map is too open and doesn't block vis at all.

- Your map has leaks between inner rooms and doesn't block vis.

- You put a lot of details but didn't use the detail flag for brushes, so lots of polys are created for the bsp.

- You made structural walls detail so they don't block vis.

- You used a enormous amount of shaders (tho having a gf4 this should be really giant)

- You made func_train (or any other func entities) with a very sophisticated construction inside it (Entities aren't blocked by vis).

There are more possibilities, but these should serve to make you an idea of what can be going wrong. At least I hope so.

Leslie Judge
10-07-2002, 10:23 AM
What can I say after this? :)

Btw: That r_speed thing doesn't work for me. I tried several times, several way, but I still make something wrong.

It's either r_speed 1 or r_speed 2, doen't it? If yes, what should I see and where on the screen?

WhiteShdw
10-07-2002, 10:40 AM
I'm not completely sure, but i think you can do that stuff only in the SP game. So start up your map in SP and then activate cheats. Then you can use those funtions.

Showtris 1
r_speeds 1

that's the stuff i use.

D@rk_BLu3
10-07-2002, 11:58 AM
As I can see,the prob lies with the vis blocking.SURELY cause I simply don't know how to block the vis and my map is HUGE.6 rooms 4 times bigger from the room when u enter the jedi academy at the end of the game(yavin countyard),with the tie fighter.So,if u can briefly inform me about vis blocking I would be grateful....Cheers:D

D@rk_BLu3
10-07-2002, 12:11 PM
I create the map,u know everything,hollow ok,meshes ok,textures ok,elevators ok,solidness ok,lights ok,NPCs ok,but the framerate is awful.If noone can answer directly try downloading it from jediknightII.It should be up shortly.name:
Emperor_reborn_BETA0.01

Leslie Judge
10-07-2002, 01:01 PM
WhiteShdw: thanks. Who knows why but I try r_speed always without the ending S. :)

D@rk_BLu3: I'll download it and I'll see I can help or not.

idontlikegeorge
10-07-2002, 02:32 PM
ok, heres the thing.

the engine, basically, really loves: little rooms, little boxes. thats the easiest and most effective environment to render - its the mappers job to make the boxes etc. look like a space station, city, or outside areas

now im not saying that everything should be little boxes, but you can't just have massive rooms with a lot of detail and wonder why framerate sucks, without knowing what the engine is doing

show yeah, use the commands listed, and if you stand in one spot and see alot of stuff that isnt really in the players FOV, then you got VIS problems

basically, id say, redo the map, it may be easier in the long run - reworking already made large maps is a bitch - maybe try copying parts of the map that you like, and put them in a new one

try to seperate big rooms, with hallways or something, and make it so there is vis blocking between the big rooms - if you have two big walls, and a door between the rooms, use an area portal in the doorway

D@rk_BLu3
10-07-2002, 05:19 PM
Well,after what u said,I noticed sth VERY strange.My map is like this:
____________
| |
| |
| |
-------- |
| | | etc,etc --->to this direction there is LOTS
| x |==========| of stuff.
| | |
-------- |
| |
--------------------
|
===

Consider I am in place "x".If I look towards the arrow --->,where the LOTS of stuff are(almost everything,effects,npcs,etc) then I see a dramatic fall in fps (25-30).
Now,if I look to the opposite direction where there isnt anything,I get 60-70fps(still low for my pc but quite faster.
So ,this means that,when I look towrads the LOTS of stuff,the game must be rendering the map altogether asif I was in one big room.same as if I look up or down.the biggest room is 2600x4000 in the scale used by GTKRadiant.

Hope this sheds some light....

Leslie Judge
10-07-2002, 05:57 PM
In a room with that size the LOTS of stuff can be extreme. :) And a room is a room, eh? I mean it's a big space with the lots of stuff in it. Try to make things wich not let the player to see the whole room. Some architecture, big cargo block, anything. that could help.

Btw: I couldn't find your map. Could you give a more specific link?

D@rk_BLu3
10-08-2002, 05:23 AM
Yeah,thnx.I've got a small prob with the map so it will take a while before it's up.My stupid little brother...
Anyway,the thnig is that the engine shouldnt control you so much.
For example my huge room.why should it suck fps so dramatically?after all,we ve seen games with larger areas than the one I designed,that run with 100 fps.
Basically,the engine sucks ;)

As for the problem,couldnt I just shorten the FOV?I mean,is there a way so that the player can't see far enough,cause it's really awsome to have a map with the kind of rooms I created.

And,u said that if I could put sth in front,like cargo and stuff to block the FOV,would it just put more problems?I mean,it would have to render the fov and the new cargo.

TIP:does textures which are hollow(you can pass rom inside them likea ghost)block the VIS?

Leslie Judge
10-08-2002, 07:08 AM
You can change the max visibility for the VIS process in the worldspawn entity. Now I don't remember exactly what the key's name is, but it sounds like distancecull or what... You can read about that in the info in entity window.

About what I said... When you compile your map, there is a BSP, a VIS and a LIGHT phase. BSP creates the .bsp file, and defines all the visible area in your map with the fewer possible boxes (not always box, but it's always concave). In the VIS phase the compiler computes wich area ('box') can be seen from every other area.

So, if you make things that blocks the players view, and those are structural not detail brushes (Radiant creates structural brushes by default), then they will block the the VIS, so in the game the engine will not have to render those places wich can't be seen from where the player is.

I'm sure someone else could make a much better description of this, but maybe this is enough for you to understand.


About those textures: I don't know how they affect this, but I think they are transparent for VIS, so the engine has to render the area behind them.

Others? Masters? :)

D@rk_BLu3
10-09-2002, 09:03 AM
I ve made a little test which has some weird results.if all the huge rooms are the one behind the other,like

room====room===room

then the fps drop fastly.
Now,if I put the rooms like this:

room
I
room===I
I
room
then the fps stays at 90 fps.Now,that's a new one...
The trick works for numerous huge rooms ,not just one or two.simply you can also change the heightif you run out of sides :)

Leslie Judge
10-09-2002, 09:34 AM
True.

If you put the rooms in a line the only way to raise the fps is using doors AND area portals.

Area portals are like structural brushes in the way they block the VIS. But in other way they are seemless and players can go through them. Area portals have to be IN doors and be ONLY ONE unit wide and must COMPLETELY separate the two area.

You can make a brush into area portal by putting the system/areaportal shader on it.

So area portals block the VIS and doors make the effect acceptable by not letting the player see that the most part of the area behind the door isn't drawn.

jalisko
10-09-2002, 03:46 PM
Originally posted by D@rk_BLu3
I ve made a little test which has some weird results.if all the huge rooms are the one behind the other,like

room====room===room

then the fps drop fastly.
Now,if I put the rooms like this:

room
I
room===I
I
room
then the fps stays at 90 fps.Now,that's a new one...
The trick works for numerous huge rooms ,not just one or two.simply you can also change the heightif you run out of sides :)

Dark_blue, thas is because if they are all in line, none of them have the visibility blocked, and the full three rooms are drawn. As you move the middle one out of the line, it blocks vis to itself, so only the 2 rooms in line are drawn.
If you made a "L" hallway for entering the first and third room you'll achieve only one room to be drawn at the time, so fps would be better and you'll be able to use more detail at each room (or make each room bigger).

Like this:

...........II==room
...........II.............
room==II.............
...........II.............
...........II==room

That's exactly what vis blocking is for. :)

Leslie Judge
10-09-2002, 04:59 PM
:) I think D@rk_BLu3 made the same plan but you know those leading spaces... :)

D@rk_BLu3
10-14-2002, 06:40 AM
Leslie:Yes,Idid the same pan but that wasn't so god :P

As for the rooms,thnx all for the help,and I 'd like to give one last question/notice:
the height of the roomcan be taller from above than from below.If I am in x position:

I
I
I
I
X
I

This room will actually give more fps than this one.Notice the rooms are exactly the same in the inside

I
I
X
I
I
I
I
I

Quite weird e?

D@rk_BLu3
10-14-2002, 06:48 AM
And sth else.I put all the stuff in a pk3 file ,scripts,maps,snapshots etc but I can't load it from the game...What silly thing have I forgotten?

Leslie Judge
10-14-2002, 07:07 AM
Hmm... Two stupid questions:

1. Did you put the pk3 file into base directory?
2. Did you use paths in the pk3 as on your hard disk?

Only these came to mind. Sorry. :)

D@rk_BLu3
10-14-2002, 07:22 PM
Of course......what the hell, then I write devmap xxxx and I take a glorious "map not found".....

Leslie Judge
10-15-2002, 03:10 AM
Hmm... strange. If you want you can send me (lbiro@kum.hu) that pk3 to check it for you. But the others might know the solution.