aboutsummaryrefslogtreecommitdiff
path: root/src/grid.rs
Commit message (Collapse)AuthorAgeLines
* Add previously missing docs where appropriateArne Dußin2020-12-21-10/+17
|
* Limit grid inaccuracy to half a pixelArne Dußin2020-11-28-18/+27
| | | | | | | | | | Before, the grid was calculated accumutatively, which was pretty alright. However, with some zoom levels towards the bottom of the screen there was a discrepancy between the grid and something drawn. This should be fixed now, since this update makes the grid use the same method of calculation for every grid cell that everything else uses to calculate points. Also, sub-pixel positions are rounded for the grid, while they were floored before, which should improve accuracy.
* Change to f64 as the preferred floating point numberArne Dußin2020-11-27-29/+9
|
* Add constant for the grid accuracyArne Dußin2020-11-10-0/+3
| | | | | 0.5 was used as a magical number throughout the code for that until now, which I now changed.
* Add icon toolArne Dußin2020-11-06-0/+10
|
* Make zoom-levels whole numbers to combat round-errArne Dußin2020-11-01-1/+22
| | | | | | | | The grid was offset at certain zoom-levels and lower positions, so for now I just made only whole zoom-levels possible, which removes the offset. However, I consider this a band-aid-solution. Maybe change from f32 to f64 and try out if that fixes it? Otherwise, a different algorithm might work.
* Rewrite project to use raylib instead of pistonArne Dußin2020-10-30-0/+38
Sorry piston.. I really tried liking you, but I just couldn't :/ It's not you, it's me. What am I saying? It's you, sorry not sorry.