Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Util.Civ3MediaPath Can Add Caching #379

Open
QuintillusCFC opened this issue Jan 16, 2023 · 0 comments
Open

Util.Civ3MediaPath Can Add Caching #379

QuintillusCFC opened this issue Jan 16, 2023 · 0 comments
Labels
low priority Not very important at this point performance make things fast

Comments

@QuintillusCFC
Copy link
Member

While debugging why our custom scenario graphics aren't working (again), I noticed via breakpints that Util.Civ3MediaPath does an awful lot of checking whether files exist, particularly files such as rolloverbuttons.pcx that are requested repeatedly. It checks with the file system whether they exist, and if not, checks additional locations until it finds them.

Optimizations should benchmark this to see if improvements are discernable. Testing with a nice slow hard drive is likely necessarily. With my 7200 RPM Toshiba desktop hard drive from 2013, loading a scenario is still pretty quick, so if I had it on a modern SSD I don't think we'd be able to tell much of a difference at all. That's part of why this is low-priority, but nonetheless it jumps out as "something inefficient we're doing unnecessarily".

I expect to eventually have a whole bunch of these "potential performance improvements" documented as they are discovered, so once we decide something is slow it's easy to look up possible ways to speed it up.

@QuintillusCFC QuintillusCFC added low priority Not very important at this point performance make things fast labels Jan 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
low priority Not very important at this point performance make things fast
Projects
None yet
Development

No branches or pull requests

1 participant