Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
UPBGE: Fix Parallax texture size centered.
The texture coordinate output by the parallax mapping should use a texture centered in (0.5, 0.5). To do this we use the following calcul: (texuv * size) + (vec2(1.0) - size) / 2.0; Because this calcul is pretty long it was putted in a separated GLSL function : parallax_scale(vec2 texuvn vec2 size)
- Loading branch information
1 parent
8fb3304
commit 95d6e40
Showing
1 changed file
with
8 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters