Efficient running of OpenTTD
Moderator: OpenTTD Developers
- Redirect Left
- Tycoon
- Posts: 7249
- Joined: 22 Jan 2005 19:31
- Location: Wakefield, West Yorkshire
Efficient running of OpenTTD
Howdy.
I tend to run my maps for (real life) months towards years, and its now got to the point where the game runs fairly sluggish and the speed up button has very little difference.
The first thing I did was turn off animation, which made a minor difference. I have tried disabling 'full detail' which made no noticeable effect on running speed.
Is there anything I can do as a player to run OpenTTD with largeish (usually 1024 x 1024 or 2048 x 2048) and a buttload (upwards of 1000) trains. I don't use buses, boats or planes in my map, sometimes i use trams to link stations together (i guess that's probably treated as a 'bus' or road vehicle anyway).
Side note, i'm planning on getting a new computer soon anyway, probably to an i9-7940X from my current i5-4690. As i understand it, it won't have much effect on OpenTTD as its single threaded and doesn't utilise the gorgeous pristine other <many> cores, is this correct? Furthermore, is there any intention on improving that situation if accurate?
I tend to run my maps for (real life) months towards years, and its now got to the point where the game runs fairly sluggish and the speed up button has very little difference.
The first thing I did was turn off animation, which made a minor difference. I have tried disabling 'full detail' which made no noticeable effect on running speed.
Is there anything I can do as a player to run OpenTTD with largeish (usually 1024 x 1024 or 2048 x 2048) and a buttload (upwards of 1000) trains. I don't use buses, boats or planes in my map, sometimes i use trams to link stations together (i guess that's probably treated as a 'bus' or road vehicle anyway).
Side note, i'm planning on getting a new computer soon anyway, probably to an i9-7940X from my current i5-4690. As i understand it, it won't have much effect on OpenTTD as its single threaded and doesn't utilise the gorgeous pristine other <many> cores, is this correct? Furthermore, is there any intention on improving that situation if accurate?
Re: Efficient running of OpenTTD
This is something id like to know as well.
I like the bigger maps, but even now with no trains on my max size map, the tile loop alone makes the ff button useless.
I like the bigger maps, but even now with no trains on my max size map, the tile loop alone makes the ff button useless.
Re: Efficient running of OpenTTD
Newer PCs lack the raw computing power of a single core, unless you specifically buy such a processor. The reason for this is that most consumers don't use the power, and less power means longer battery life, greener computing, etc. A second reason is that newer computers now have GPUs which don't talk to the CPU very fast (compared with directly accessing the video memory). Since OpenTTD renders the screen at the CPU, all video data must be sent to the GPU for display, which is slow.
A third reason is that OpenTTD does 32bpp rendering by default (configurable in openttd.cfg), which quadruples the amount of data that needs to be transferred. Finally, a fourth reason is that people buy screens with higher resolution, which means more pixels which means more data to send.
Mapsize has some influence, but the map size in itself is probably not that important. What's more important is that the number of industries and cities gets much much larger, and people run more trains to get a certain capacity between two points at the map. (300 tonnes / month 50 tiles away needs less trains than 300 tonnes / month 2000 tiles away).
A third reason is that OpenTTD does 32bpp rendering by default (configurable in openttd.cfg), which quadruples the amount of data that needs to be transferred. Finally, a fourth reason is that people buy screens with higher resolution, which means more pixels which means more data to send.
Mapsize has some influence, but the map size in itself is probably not that important. What's more important is that the number of industries and cities gets much much larger, and people run more trains to get a certain capacity between two points at the map. (300 tonnes / month 50 tiles away needs less trains than 300 tonnes / month 2000 tiles away).
Being a retired OpenTTD developer does not mean I know what I am doing.
Re: Efficient running of OpenTTD
The "blitter" option in the openttd.cfg.
The list available blitters can be queried by running openttd with a "-h" option, which produces around a page of output:
The list available blitters can be queried by running openttd with a "-h" option, which produces around a page of output:
Code: Select all
$ ./openttd -h
...
List of blitters:
32bpp-anim: 32bpp Animation Blitter (palette animation)
32bpp-optimized: 32bpp Optimized Blitter (no palette animation)
32bpp-simple: 32bpp Simple Blitter (no palette animation)
32bpp-sse2: 32bpp SSE2 Blitter (no palette animation)
32bpp-sse4: 32bpp SSE4 Blitter (no palette animation)
32bpp-sse4-anim: SSE4 Blitter (palette animation)
32bpp-ssse3: 32bpp SSSE3 Blitter (no palette animation)
8bpp-optimized: 8bpp Optimized Blitter (compression + all-ZoomLevel cache)
8bpp-simple: 8bpp Simple Blitter (relative slow, but never wrong)
null: Null Blitter (does nothing)
...
Being a retired OpenTTD developer does not mean I know what I am doing.
- Redirect Left
- Tycoon
- Posts: 7249
- Joined: 22 Jan 2005 19:31
- Location: Wakefield, West Yorkshire
Re: Efficient running of OpenTTD
and which of those is generally considered the 'best' for efficiency and good speed running on modern computers?
Re: Efficient running of OpenTTD
Well since it's been said 32bpp rendering quadruples the communication volume between GPU and CPU, I'd go for the optimized 8bpp one. Also sounds like you'd get better performance at an oldschool resolution like 800x600.
- Redirect Left
- Tycoon
- Posts: 7249
- Joined: 22 Jan 2005 19:31
- Location: Wakefield, West Yorkshire
Re: Efficient running of OpenTTD
I've set blitter to 8bpp-optimized, but notice no (maybe a tiny bit of difference, not sure if that is just willing myself to believe it).
Is there a console command to verify what openttd is currently using for its blitter?
Is there a console command to verify what openttd is currently using for its blitter?
Re: Efficient running of OpenTTD
I changed to 8bpp-optimized and all my station graphics disappeared...
Re: Efficient running of OpenTTD
Check openttd.cfg for this line too. I think it needs to be flipped to yes.
support8bpp = no
support8bpp = no
Re: Efficient running of OpenTTD
Some systems believe that 8bpp has no value, and dropped all support
Being a retired OpenTTD developer does not mean I know what I am doing.
- Redirect Left
- Tycoon
- Posts: 7249
- Joined: 22 Jan 2005 19:31
- Location: Wakefield, West Yorkshire
Re: Efficient running of OpenTTD
Is there anything OpenTTD can do to overcome that, or any pre-requisites that can be installed to bring back old support?Alberth wrote:Some systems believe that 8bpp has no value, and dropped all support
My game is really struggling, and its irritating me to the point where I'm considering a new map, even though in 6 month time i'll be back here and "uuugh!"
Re: Efficient running of OpenTTD
Would you mind sharing your save? I'm kind of curious what causes such troubles
Re: Efficient running of OpenTTD
It's the computer system itself that doesn't do 8bpp, as in, we ask "can you display 8bpp?" and the system says 'no'.Redirect Left wrote:Is there anything OpenTTD can do to overcome that, or any pre-requisites that can be installed to bring back old support?
We could refuse to run at such systems, so technically OpenTTD would run at systems that have old support, but that doesn't do much good either, is my guess.
Being a retired OpenTTD developer does not mean I know what I am doing.
Re: Efficient running of OpenTTD
But this error came from within openttd, not my operating system.Leanden wrote:invalid value "yes" for support8bpp... got an error
And it was only the graphics from auzstations that seemed to he effected by the change of blitter
What are the valid values for support8bpp in the cfg?
Re: Efficient running of OpenTTD
If it uses standard non-animated palette colours, conversion is done on the fly without you noticing, since 8bpp colours are a subset of 32bpp colours. Zoom calculations may make a mess here, but don't know (I use default size graphics or smaller only).Leanden wrote:And it was only the graphics from auzstations that seemed to he effected by the change of blitter
The table file suggests there are 3 different valuesLeanden wrote:What are the valid values for support8bpp in the cfg?
Code: Select all
static const char *_support8bppmodes = "no|system|hardware";
Of course "hardware" cant be used if your video card doesn't have a 8bpp mode.
Being a retired OpenTTD developer does not mean I know what I am doing.
Re: Efficient running of OpenTTD
Sylf wrote:Check openttd.cfg for this line too. I think it needs to be flipped to yes.
support8bpp = no
That sounds like one of the problem - I didn't know what the proper supported values were for that setting. I added the entry to the wiki page.Alberth wrote:Code: Select all
static const char *_support8bppmodes = "no|system|hardware";
- Redirect Left
- Tycoon
- Posts: 7249
- Joined: 22 Jan 2005 19:31
- Location: Wakefield, West Yorkshire
Re: Efficient running of OpenTTD
Just replying to this, as i'm still having issues.
I've tried all of the noted support8bpp, all of them worked (or maybe ignored if not compatible?) but there was never any sort of noticeable increase in speed.
I use JGR patchpack mostly, but I have recreated the same sort of general performance issues with similar games on trunk.
I've tried all of the noted support8bpp, all of them worked (or maybe ignored if not compatible?) but there was never any sort of noticeable increase in speed.
I use JGR patchpack mostly, but I have recreated the same sort of general performance issues with similar games on trunk.
Re: Efficient running of OpenTTD
What I miss in this discussion (and other likewise discussions) is the effect of the graphics card.
I like the artwork so I use mainly 32bpp by means of an older (cheap) gtx960 graphics card.
All sizes, all types games are running very smooth on a 4K-screen (3840x2160).
I'm not sure to which extend this is (also) caused by using the 64bit version of OpenTTD.
I like the artwork so I use mainly 32bpp by means of an older (cheap) gtx960 graphics card.
All sizes, all types games are running very smooth on a 4K-screen (3840x2160).
I'm not sure to which extend this is (also) caused by using the 64bit version of OpenTTD.
Who is online
Users browsing this forum: Amazon [Bot] and 17 guests