[texture][rlgl] DrawTexturePro()
rendering issues for rotated uneven textures (e.g. 3x3 pixels)
#4360
Labels
hacktoberfest
Hacktoberfest recommended issues
help needed - please!
I need help with this issue
platform: Windows
Windows platform
I'm experiencing graphical issues when using DrawTexturePro in Raylib for rendering uneven textures, specifically 3x3 textures. When rotating these textures at a center origin, particularly in 90-degree intervals, the output appears misaligned, leading to an incorrect rendering order (e.g., pixels are shifted, resulting in a display where pixels "abc" appear as "cab").
This issue is particularly noticeable with odd-sized textures. When the texture's origin is centered for rotation, the graphical glitches manifest as subpixel shifts that disrupt the intended visual alignment. It seems that anything other than 90-degree rotations can exacerbate these rendering issues, resulting in further misalignment.
Ensuring that all textures are evenly divisible by 2 helps avoid these graphical anomalies. However, this limitation may impact the flexibility of designing sprites and textures in the future.
I would appreciate any guidance on potential fixes or adjustments in Raylib's rendering approach to resolve these graphical inconsistencies.
(4X zoom)
(Same blue texture rotated - don't mind the positions still using the offset padding from example below)
(Fixed as shown with code below but rotates with a 1 pixel offset, which has been adjusted with position padding)
Windows 11, Nvidia 3060, default raylib settings.
The text was updated successfully, but these errors were encountered: