Page 1 of 4

Jerky Graphics

Posted: Sun Jun 24, 2007 6:53 pm
by davcefai
I am running v1.65 under Debian Linux on a 2.66GHz Celeron with 1GB of RAM

Over, say, the past couple of months I am tending to get "stuttering" graphics in OOlite. The screen will freeze for 1 to 3 seconds then jump to what it should be showing - ie it doesn't stop, then restart. It seems to skip over displaying those 1 to 3 seconds.

This happens most when I kill a ship but also while generally moving around.

During some sessions the game is pretty smooth. At others almost unplayable.

Increasing RAM from 512MB 1GB didn't help. Stripping out OXPs didn't either.

Can anybody help?

Posted: Sun Jun 24, 2007 6:58 pm
by JensAyton
It’s hard to know what the specific cause of stuttering in your case is, but gameplay has become significantly smoother in various ways in the test builds. Unfortunately getting a test build working under Linux is currently fiddly; I’m hoping we’ll have a better solution for 1.69.

I'm running

Posted: Sun Jun 24, 2007 7:41 pm
by Shade
I'm running debian unstable as well. Things here are as smooth as silk. I'm on an Athlon 2800+, 2 GB of RAM, ATI X700 AGP video card, with the open driver.

In my case with the open ATI driver I found that I had to use 'driconf' to 'disable low impact fallback' to run the game smoothly. You might want to try apt-get install driconf and playing. In my case, the low impact fallback, if I'm not mistaken, allows for supposedly 'low impact' software rendering of certain Open GL 'things'. This seems to work fin with iD engines, not so much with OoLite. Driconf options depend on your video card, so YMMV... Also, you could play with your xorg.conf settings. 'man your_video_card' and look for stuff labeled 'faster' and 'off by default'. But remember, if you hose your xserver or card, I'm just a random stranger on the interweb. :)

Also, if you get regular stutter, and are running, oh say, mldonkey as a server, you might want to nice that sucker up to 10... It's one of the nastiest things for generating CPU spikes I've ever seen... And I've used it for years across several distros. (Or take a look for anything that might be causing CPU spikes.)

Posted: Sun Jun 24, 2007 8:40 pm
by TGHC
Welcome aboard Shade, great first post.

@davcefai, most of these type of problems seem to be related to graphics cards and drivers , so make sure you have the most up to date driver, and if that doesn't help, you could try reinstalling Oolite, that often seems to fix it.

good luck.

Posted: Sun Jun 24, 2007 8:42 pm
by davcefai
Thanks Shade. Unfortunately I've tried just about everything you suggest but the fuel feed remained erratic.

The sad thing is that when I watch processes using KSysguard there does not appear to be anything else consuming significant resources.

It's almost as if backuppc is running while I'm playing. (No it's not but in the "good old days" this was how Oolite would perform if I was playing when backuppc kicked in)

Posted: Sun Jun 24, 2007 9:49 pm
by Frame
davcefai wrote:
Thanks Shade. Unfortunately I've tried just about everything you suggest but the fuel feed remained erratic.

The sad thing is that when I watch processes using KSysguard there does not appear to be anything else consuming significant resources.

It's almost as if backuppc is running while I'm playing. (No it's not but in the "good old days" this was how Oolite would perform if I was playing when backuppc kicked in)
Try a fresh install of oolite in another directory, i accidently updated ontop off another oolite version, which produced som odd bugs..

remeber to backup your commander save files, if you delete the old directory

Cheers Frame....

Posted: Mon Jun 25, 2007 12:26 am
by drdenim
I don't think it was mentioned...but I think there's a quality level option in the F2 menu in Oolite...I've never bothered it because I only get lags when I destroy something with a large amount of debris to be created...

Posted: Mon Jun 25, 2007 8:29 am
by TGHC
I assume you've tried playing it with all other programmes closed, the only thing I can think of is do you have anything else running hidden in the background, that could be slowing it down. I have a scanner that used to keep checking every few minutes if the lid was open, untill I disabled it, not that it was causing any problems, it was just annoying and uneccesarily using up resources, . Alternatively you could try running without any OXP's loaded and see if that makes a difference, and if none of that works buy a new computer! :wink:

<dives into foxhole>

Posted: Mon Jun 25, 2007 10:21 am
by davcefai
Tried all that (and more). I'm wondering if the problem is linked to the graphics system and driver. Xorg has been recently updated and the only NVidia driver which works is a Beta.

Posted: Mon Jun 25, 2007 12:31 pm
by TGHC
How annoying!

According to the big A 1.69 is just around the corner, praps that will help (might make it worse), I'd be inclined to follow the graphics card route, and try all the drivers you can find for it.

Good luck.

Posted: Wed Jun 27, 2007 6:28 am
by davcefai
I have partially solved the problem.

I think the root cause is that something else has been changed in Debian, maybe the new version of Xorg?

There is a process called "ksoftirqd/0" which runs at a priority of 19, ie it has the least possible priority. It handles "soft" Interrupt Requests. As far as I can tell it has always run at this priority under Linux.

You can see this process by launching KSysGuard and looking at the process table. It seems to always load as process #3 but anybody trying this fix should check.

Anyway, the fix:

Open a terminal. Become root. then enter the command:

Code: Select all

ps -A|grep ksoftirq
You will see something like:

Code: Select all

3 ?        00:00:00 ksoftirqd/0
Then enter the magic incantation:

Code: Select all

renice 0 3
To which your PC will reply:

Code: Select all

3: old priority 19, new priority 0
if the process number is not 3, replace 3 in the above.

This will improve matters a lot, until you reach a stage in the game where there are a lot of objects (you can see this by pressing Shift-F which shows Frame Rates, position and Objects). At this point performance deteriorates and is not restored even when the object count drops.

I hope that the Debian maintainer for Oolite reads this and releases a new package compiled against the latest versions where, hopefully, the problems will go away.

Thanks everybody for the suggestions in dealing with this problem.

Updated on 11th May 2008

Getafix has pointed out that on multicore or multiprocessor systems there will be a ksoftirqd process for each core. You may need to renice all of them

Posted: Wed Jun 27, 2007 4:09 pm
by TGHC
This thread should be moved to the Linux section.

Looks like you're getting close to a solution davcefai, and at least made the game more playable. If a high number of objects is a problem, you'd do well to avoid Assassins OXP, sometimes it has hundreds of objects! This would be a great shame because Assassins is virtually a whole game on its own.

Posted: Wed Jun 27, 2007 5:42 pm
by LittleBear
DF playtested the final (1.2) Version of assassins on Unix. :wink: From his posts, looks like the problem is somthing to do with some Unix settings rather than Oolite itself.

Posted: Wed Jun 27, 2007 6:57 pm
by davcefai
TGHC, You are right that this now belongs in the Linux section since the problem seems Linux specific.

I could repost there if that is desirable.

Regarding Assassins, I've played it and I know the Symbol Secret oops! I mean who Agent Wombat is.

However it would be sad if new Linux users could not play it.

Posted: Wed Jun 27, 2007 7:17 pm
by Rxke
I moved the topic, no need to repost. There's a 'shadow' topic in the original place too, so the best of both worlds :D