-
Notifications
You must be signed in to change notification settings - Fork 2
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
Add Pixel Scaling & Allow Setting UPS #2
Conversation
67eae1c
to
80cda28
Compare
Cargo.toml
Outdated
@@ -13,6 +13,6 @@ unstable = [] | |||
[dependencies] | |||
|
|||
rand = "0.6.5" | |||
piston_window = "0.87.0" | |||
image = "0.21.0" | |||
piston_window = "0.64.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These downgrades are pretty severe.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, I need to spend a few minutes looking into why things render at the wrong scale with the latest versions. As things are with this PR (at least on my setups) at SCALE = 1
each cell is exactly one pixel. Which is what I want.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it seems it's just my laptop screen that's blurry with the latest versions. I wouldn't be at all surprised if this is a bug (or some half worked feature) in piston, or glutin.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just pushed with a patch to the underlying window in 1e6bf29. I'm not 100% sure why there's a draw_size
and size
to be perfectly honest, so I'll need to dig more into this still.
80cda28
to
aae420b
Compare
65bc862
to
1e6bf29
Compare
This makes the pixels nice and crispy. Supercedes #2.
This makes the pixels nice and crispy. Supercedes #2.
This makes the pixels nice and crispy. Supercedes #2.
Fixed by #7. |
This fixes two main issues I had with this implementation of Conway's Game of Life and makes a few other small changes. Mainly:
for
loops to draw extra pixels instead. This means thatSCALE
is now au32
.EventSettings
to allow setting theUPS
, aka updates per second. This makes high scale games much more fun to watch.I've had to downgrade the version of
image
to still render at 1920x1080 correctly. When I get some more time I can look into what's changes with the latest versions.P.S. Playing this game at 1920x1080 is very very fun, thanks for making this.