Tremulous Forum

General => Troubleshooting => Topic started by: Diggs on February 18, 2007, 06:13:09 pm

Title: Low FPS on Ubuntu - What to check/change?
Post by: Diggs on February 18, 2007, 06:13:09 pm
I installed Ubuntu (6.06) on the same machine that I had WinME running.  Then re-installed Tremulous.  I get about 1/2 the frame rate playing Tremeulous under Linux that I had under WinME.  It's an old machine I had laying around (PIII 933 w/384 MB ram and a FX5200).  From what I read, frame rates under Linux should equal of exceed Windows.  The video drivers are the latest from NVidia, but I could look for some aftermarkets.  What else should I check/change?

Example - Coming our of spawn on Transit (no other players) gives about a 20fps with Ubuntu vs. 35-40fps running WinME.


Diggs
Title: Low FPS on Ubuntu - What to check/change?
Post by: next_ghost on February 18, 2007, 06:20:34 pm
Look for some X configuration tweaks, like Option "EnablePageFlip" "True" in my /etc/X11/xorg.conf. That tweak gave me a pretty big performance boost.
Title: Low FPS on Ubuntu - What to check/change?
Post by: Diggs on February 18, 2007, 06:45:57 pm
Quote from: "next_ghost"
Look for some X configuration tweaks, like Option "EnablePageFlip" "True" in my /etc/X11/xorg.conf. That tweak gave me a pretty big performance boost.


Hmmm...
Not one of my options, but I can add it under device for the card.  I did see while looking at xorg.conf that it still has a device descriptor of nVidia Vanta which was the old card that was in that machine before I started swapping video cards around.  But it calls out "nvidia" as the driver which is for the FX5200 instead of "nv" which was for the Vanta card before.  Device Manager is showing that the FX5200 is installed and is the only graphics card.

Things that make you go - Hmmm.....
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 18, 2007, 11:12:44 pm
there is a niece GUI utility for nVidia GPU's that comes with the drivers - just type

Code: [Select]
nvidia-settings

in console or find a shortcut in some menu (don't know where might it be in GNOME).

It will bring up a window called "NVIDIA X Server Settings".
There you can get some info on your gfx system and tweak it a little.

I think the page flipping option mentioned by next_ghost is in the "OpenGL Settings" page ("Allow Flipping" checkbox).

The program runs w/o root priviliges so I assume the settings you make there affect only your account.
For global settings (concerning all users) the xorg.conf is the place to make changes.

BTW. The "Identifier" field in "Device" section of the xorg.conf does not influence the gfx driver - it's only a string that helps to configure the "Screen" section (you can have, for example, 2 screens and 2 devices and the "Identifier" lets you specify which device is used by which screen)
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 18, 2007, 11:46:55 pm
Quote from: "next_ghost"
Look for some X configuration tweaks, like Option "EnablePageFlip" "True" in my /etc/X11/xorg.conf. That tweak gave me a pretty big performance boost.
Woah, seriously? What section do you put it under?
Title: Low FPS on Ubuntu - What to check/change?
Post by: kevlarman on February 19, 2007, 02:02:33 am
Quote from: "Odin"
Quote from: "next_ghost"
Look for some X configuration tweaks, like Option "EnablePageFlip" "True" in my /etc/X11/xorg.conf. That tweak gave me a pretty big performance boost.
Woah, seriously? What section do you put it under?
in the "Device" section pertaining to your video card, it's consistently a 50% fps boost to glxgears on all the systems i've tried it on, it's much less in a realistic situation (like a 3d game) but still very noticable.
Title: Low FPS on Ubuntu - What to check/change?
Post by: David on February 19, 2007, 02:07:25 am
any more such useful hints?
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 19, 2007, 02:12:18 am
hmm...
http://download.nvidia.com/solaris/1.0-9629/README/appendix-d.html - nVidia X config options - can't find EnablePageFlip there... maby it's some old option?? the only option that seems to have anything to do with flipping (not counting the stereo buffer flipping) is "NoFlip" which disables OpenGL flipping...

but I will try it out - maby EnablePageFlip is not documented?
Title: Low FPS on Ubuntu - What to check/change?
Post by: kevlarman on February 19, 2007, 03:03:45 am
Quote from: "tomek-k"
hmm...
http://download.nvidia.com/solaris/1.0-9629/README/appendix-d.html - nVidia X config options - can't find EnablePageFlip there... maby it's some old option?? the only option that seems to have anything to do with flipping (not counting the stereo buffer flipping) is "NoFlip" which disables OpenGL flipping...

but I will try it out - maby EnablePageFlip is not documented?
the option isn't specific to nvidia
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 19, 2007, 08:03:41 am
Quote from: "kevlarman"
Quote from: "tomek-k"
hmm...
http://download.nvidia.com/solaris/1.0-9629/README/appendix-d.html - nVidia X config options - can't find EnablePageFlip there... maby it's some old option?? the only option that seems to have anything to do with flipping (not counting the stereo buffer flipping) is "NoFlip" which disables OpenGL flipping...

but I will try it out - maby EnablePageFlip is not documented?
the option isn't specific to nvidia


I've checked the option - my nvidia driver ignores it:

Code: [Select]
(WW) NVIDIA(0): Option "EnablePageFlip" is not used

maby it just does the flipping by default.
Title: Low FPS on Ubuntu - What to check/change?
Post by: Lava Croft on February 23, 2007, 06:17:57 am
MicroSoft (http://www.microsoft.com)
Title: Low FPS on Ubuntu - What to check/change?
Post by: TinMan on February 23, 2007, 12:41:58 pm
Umm...he already said that he has WinME, no need for the MicroSoft link, he's obviously trying to use Linux over Windows.

Have you tried the beta drivers? I know that 6.06 is LTS, but I had to upgrade from that to get trem to run better, and I got the beta nvidia drivers.
Title: Low FPS on Ubuntu - What to check/change?
Post by: FooBar on February 23, 2007, 02:45:23 pm
I'm not entirely clear about this: have you installed the nvidia driver package that comes with Ubuntu, or the proprietary binary driver that you download straight from nvidia?  I'm pretty sure you'll get better performance with the proprietary driver.  Also, I'll reiterate tomek-k's suggestion that you run nvidia-settings and see what changes you can make.

It's also worth checking to see if your in-game settings are different with your reinstall.  If you had changed the Tremulous settings in Windows for speed (i.e. lower resolution, lower quality) and they are set to "high" by a default installation, that would do it.

Also, are you sure you have the most current version of the driver?  The latest version is at http://www.nvidia.com/object/unix.html and is version #1.0-9746 (for 32-bit Linux).  Once I accidentally got a really old driver because I blindly followed a link from a Google search...
Title: Low FPS on Ubuntu - What to check/change?
Post by: Diggs on February 23, 2007, 10:00:00 pm
OK....

Lava - If Microsoft is the answer, what is the question?

nvidia-settings shows flipping enabled.  I have also tweaked settings every which way and little/no improvement on frame rate.

The drivers are the latest direct from nVidia (-9746) (and are what probably WERE the beta drivers as there are no beta drivers available now that i could see).

All settings are set to low/lowest even though a few settings under WinME were turned up a notch.

Not using Linux OVER WinME.  WinME used to be on the machine, but did a complete format and install of Ubuntu 6.06.

Some other maps I can get 35-40 fps.  But, I stopped by SST with Nexus and got 9 fps.  Not surprising I guess.  Maybe I need to do some more benchmarking under WinME.

Things that make you go hmmm...


Diggs
Title: Low FPS on Ubuntu - What to check/change?
Post by: FooBar on February 23, 2007, 10:22:27 pm
Boy, I don't know.  The only other two suggestions I have are both kind of extreme: (1) Upgrade to Ubuntu 6.10; and (2) try recompiling your kernel; maybe remove any kernel-throttling stuff, and make sure that the kernel is set with drivers for your CPU, motherboard, etc.  But that's a long shot.

Hmm... You might just try double-checking that you're really using the nvidia driver and that you don't accidentally have something else running.  Also, you might actually try using an OLDER version of the nvidia driver; you can get it from the same page, look for an archive link or something.

For the record, I'm using a Thinkpad G41 with a P4 3.2 GHz, NVIDIA Go5200 and 1.5 GB RAM, and I get a higher fps in Linux than in Windows.  With my current settings I get about 60 fps in the Human base in Transit.

When I first switched over to Linux I thought my fps was slower because the game felt slower.  It took me a while to realize the fps was actually faster, and I was just playing poorly.  :P
Title: Low FPS on Ubuntu - What to check/change?
Post by: TinMan on February 23, 2007, 10:41:55 pm
nvidia-glx

Code: [Select]
# Beryl (binaries/sources)
# wget http://ubuntu.beryl-project.org/root@lupine.me.uk.gpg -O- | sudo apt-key add -

deb http://ubuntu.beryl-project.org dapper main
deb-src http://ubuntu.beryl-project.org dapper main


sudo apt-get install nvidia-glx
sudo nvidia-xconfig

Try those?
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 24, 2007, 12:38:20 am
hmm... and maby if you posted the tremulous output we could find something in there?

Code: [Select]
tremulous > output
will write the output to a file named 'output' - just post the contents of the file.

what comes to my mind is that maby it is caused by something else, not by the gfx driver. maby the audio driver?
AFAIK using the SDL-audio makes the game run slower than using the OpenAL. Am I right?
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 24, 2007, 01:02:04 am
OpenAL runs better than libSDL. However, OpenAL uses a bit of sound card acceleration so if you have an integrated card don't expect it to work 100%. I had to get an offboard card just so I could get OpenAL to work. libSDL was a bit out of sync for me so I had little choice.
Title: Low FPS on Ubuntu - What to check/change?
Post by: FooBar on February 24, 2007, 08:57:48 am
Oh, that reminds me: if you're running something -- a window manager or desktop like Beryl -- that's fairly graphics-intensive, that will definitely cut down your fps a lot.  Try getting rid of that stuff and see if it helps...?
Title: Low FPS on Ubuntu - What to check/change?
Post by: Diggs on February 24, 2007, 01:54:48 pm
@Odin-
Unfortunately it does have an AC97 integrated chip set for sound.

@FooBar-
No graphical desktop running either.  Just the default.

@tomek-
I will try to capture and post the log today since it appears it is to be a day at home with a bit of snow (8" last night and 10" more today).  Not a big deal, but is a good reason to stay home for the day.
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 24, 2007, 03:14:27 pm
Quote from: "FooBar"
Oh, that reminds me: if you're running something -- a window manager or desktop like Beryl -- that's fairly graphics-intensive, that will definitely cut down your fps a lot.
No it doesn't. (http://tremulous.net/phpBB2/viewtopic.php?t=3700) There is a problem with the SDL mouse if you use Beryl though.
Title: Low FPS on Ubuntu - What to check/change?
Post by: TinMan on February 24, 2007, 03:31:08 pm
Quote from: "Odin"
Quote from: "FooBar"
Oh, that reminds me: if you're running something -- a window manager or desktop like Beryl -- that's fairly graphics-intensive, that will definitely cut down your fps a lot.
No it doesn't. (http://tremulous.net/phpBB2/viewtopic.php?t=3700) There is a problem with the SDL mouse if you use Beryl though.

With default settings it does though, and many people don't tweak all of its settings.
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 24, 2007, 04:09:29 pm
It's one setting. On or off.
Title: Low FPS on Ubuntu - What to check/change?
Post by: TinMan on February 24, 2007, 05:26:12 pm
By all of its settings I meant Beryl, not that single option.  XD
Title: Low FPS on Ubuntu - What to check/change?
Post by: Diggs on February 24, 2007, 05:40:48 pm
Quote from: "tomek-k"
hmm... and maby if you posted the tremulous output we could find something in there?

Code: [Select]
tremulous > output
will write the output to a file named 'output' - just post the contents of the file.

what comes to my mind is that maby it is caused by something else, not by the gfx driver. maby the audio driver?
AFAIK using the SDL-audio makes the game run slower than using the OpenAL. Am I right?


Since the log is so long, I posted a link rather than the text.  

 Tremluous log here (http://www.nieting.org/images/tremlog1.txt)

As you can see, the graphic settings are turned way down and I don't see any problems.  The driver is current.  You can also see that I joined a balance server without the patch/mod installed.

I appreciate the help and ideas and I continue to learn the nooks and crannies of Linux by pursuing the problem.

Maybe this is as good as it get (?).


Diggs
Title: Low FPS on Ubuntu - What to check/change?
Post by: next_ghost on February 24, 2007, 05:55:54 pm
Also try r_ext_compressed_textures 1 in Tremulous.
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 25, 2007, 12:34:07 am
I'm not an expert if it comes to the tremulous' log, but I don't see anything suspicious.

I would suggest you to set the sound to use OpenAL - I have also an integrated Realtek AC97 sound card and I can use it (don't remember, but I think I had to install the OpenAL libraries (from the distro's packages of course)).

As for the settings - not always the lowest settings mean the best performance - it depends on the gfx hardware and it's driver. For example once I've read that some graphics chips/GPUs are optimised for resolutions higher than 640x480 and bit depths greater than 16. There may be other settings that may help.

It would be good idea to set everything the same way it was set on the WinME, so if you remember that settings then try them out.
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 25, 2007, 02:36:04 am
sudo apt-get install libopenal0

And you're done!
The AC'97 chipset does a lot on the software side, and does a lot of sound computing with the CPU, causing a minor drop(as in, unnoticeable) in performance. If you get a cheap PCI sound card you can easily solve the OpenAL problem, as well as have some hardware mixing. OpenAL on an AC'97 chipset can result in extremely garbled sound.
Title: Low FPS on Ubuntu - What to check/change?
Post by: tomek-k on February 25, 2007, 03:07:59 pm
Quote from: "Odin"
sudo apt-get install libopenal0

And you're done!
The AC'97 chipset does a lot on the software side, and does a lot of sound computing with the CPU, causing a minor drop(as in, unnoticeable) in performance. If you get a cheap PCI sound card you can easily solve the OpenAL problem, as well as have some hardware mixing. OpenAL on an AC'97 chipset can result in extremely garbled sound.


hmm... sometimes my sound is a little choppy, but not so often
Title: Low FPS on Ubuntu - What to check/change?
Post by: Odin on February 25, 2007, 05:15:48 pm
I guess it depends on other things as well, like your processor.