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

Screenshots saving is slow #473

Closed
DirtGamer301 opened this Issue Dec 9, 2015 · 2 comments

Comments

Projects
None yet
5 participants
@DirtGamer301

DirtGamer301 commented Dec 9, 2015

Description: The longer it took from the last time I've taken a screenshot and the more screenshots are saved in Own Documents/RoR the longer RoR needs to save a screeshot.

Reproducion (kinda hard to reproduce):
-Take a screenshot in RoR, let's say it took 1 second to save, you alredy had 1500 screenshots saved
-Wait 2 days without taking a screenshot (for example)
-Take a screenshot again, it took 60 seconds to save now
-Take another screenshot, it takes 1 second
-Exit RoR
-Delete your screenshots (or move them to somewhere else)
-Wait 2 days without taking a screenshot
-Take a screenshot, it'll take 30 second.

The numbers aren't real, I just needed them to explain that it'll take longer the longer you didn't save a screenshot and the more pics you have, maybe it can be better imagined with this:
There's a road which is being worked on by 1 meter a day -> 1 meter road will be finished every day. There's 1 meter added for every screenshot taken already. There's a man who has to walk the whole road when a new screenshot is taken. The more screenshots you have and the longer you wait, the more he has to walk.

I hope this explination is somewhat understandable :p
I'll try to give as much information as possible if needed, but as it's nothing you try to do, just something that happens I don't really know much either.

@Hiradur Hiradur added the bug label Dec 9, 2015

@only-a-ptr

This comment has been minimized.

Show comment
Hide comment
@only-a-ptr

only-a-ptr Dec 10, 2015

Member

@DirtGamer301 Thanks for reporting.
Makes sense, screenshots are named "screenshot#" where # is a number starting from 1.
RoR doesn't save the number anywhere, so it must determine next one by scanning existing screenshots. According to your observation, this is likely done upon first screenshot in a RoR session.

Possible solutions:

  • Find the next screenshot number on startup.
  • Change screenshot naming scheme to "RoR Screenshot 2015-12-10 10:54:22 ###.jpg" Where ### is a number starting 001 and it's only increased if somebody makes multiple screenshots in one second (i.e. mashes the screenshot key like crazy)
Member

only-a-ptr commented Dec 10, 2015

@DirtGamer301 Thanks for reporting.
Makes sense, screenshots are named "screenshot#" where # is a number starting from 1.
RoR doesn't save the number anywhere, so it must determine next one by scanning existing screenshots. According to your observation, this is likely done upon first screenshot in a RoR session.

Possible solutions:

  • Find the next screenshot number on startup.
  • Change screenshot naming scheme to "RoR Screenshot 2015-12-10 10:54:22 ###.jpg" Where ### is a number starting 001 and it's only increased if somebody makes multiple screenshots in one second (i.e. mashes the screenshot key like crazy)
@TheLonetrucker

This comment has been minimized.

Show comment
Hide comment
@TheLonetrucker

TheLonetrucker Jan 6, 2016

Could be due to the size of the screenshot I tested If you enable jpg It loads faster But Png is slower Might be just due to the Writing of the screenshot

TheLonetrucker commented Jan 6, 2016

Could be due to the size of the screenshot I tested If you enable jpg It loads faster But Png is slower Might be just due to the Writing of the screenshot

@only-a-ptr only-a-ptr assigned ulteq and unassigned only-a-ptr Jan 19, 2016

ulteq added a commit to ulteq/rigs-of-rods that referenced this issue Jan 30, 2016

[Codechange] Some screenshot taking improvements
* Reduced the screenshot key bounce time by half

* Auto hide active GUI notifications before a screenshot is taken

* Added timestamps to the screenshot filename

Fixes: RigsOfRods#360

Fixes: RigsOfRods#473
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment