The source code to VVVVVV! http://thelettervsixtim.es/
Find a file
NyakoFox 0e31253876 Fix mouse coordinates being wrong on HiDPI displays
When writing the initial stretch mode code, the existence of HiDPI
displays completely slipped my mind -- or at least I didn't realize
that they'd be a problem.

We implement scaling modes ourselves, so transforming the mouse
coordinates to our 320x240 viewport is done manually. Unfortunately,
that code did not take into account HiDPI scaling whatsoever, meaning
that all of the math which assumes the window size and the renderer
size is wrong.

To fix this, we use `SDL_GetWindowSizeInPixels` and `SDL_GetWindow` to
find the scaling factor, and then apply that to the mouse coordinates
to get the mouse coordinates in the pixel-space instead, and then we do
all of our normal logic after.

Due to our usage of `SDL_GetWindowSizeInPixels`, this bumps the minimum
SDL version to 2.26.0.

Closes #1235.
2025-05-03 15:15:03 -04:00
.github Fix mouse coordinates being wrong on HiDPI displays 2025-05-03 15:15:03 -04:00
desktop_version Fix mouse coordinates being wrong on HiDPI displays 2025-05-03 15:15:03 -04:00
mobile_version Update readme.MD 2024-01-02 22:27:05 +01:00
third_party Update to latest FAudio 2024-02-01 11:08:02 -05:00
tools Update readme.MD 2024-01-02 22:27:05 +01:00
.gitattributes fix actionscript misclassified as angelscript 2020-01-12 15:18:45 -05:00
.gitmodules Add SheenBidi submodule 2024-01-08 19:17:44 -08:00
License exceptions.md Added license exception for Recalbox project 2024-05-02 17:12:36 +01:00
LICENSE.md Update LICENSE.md 2024-01-02 22:27:05 +01:00
logo.gif Update logo.gif 2024-01-02 22:27:05 +01:00
README.md Added a link in the readme directly to the desktop_version folder 2024-01-02 22:27:05 +01:00

logo

This is the source code to VVVVVV, the 2010 indie game by Terry Cavanagh, with music by Magnus Pålsson. You can read the announcement of the source code release on Terry's blog!

The source code for the desktop version is in this folder.

VVVVVV is still commerically available at thelettervsixtim.es if you'd like to support it, but you are completely free to compile the game for your own personal use. If you're interested in distributing a compiled version of the game, see LICENSE.md for more information.

Discussion about VVVVVV updates mainly happens on the "unofficial" VVVVVV discord, in the vvvvvv-code channel.

Credits