mirror of
https://github.com/yawut/SDL.git
synced 2026-04-15 21:36:05 -05:00
The only place angle is activated and causes effect is RenderCopyEx. All other methods which use vertex shader, leave angle disabled and cause useless sin/cos calculation in shader. To get around shader's interface is changed to a vector that contains results of sin and cos. To behave properly when disabled, cos value is set with offset -1.0 making 0.0 default when deactivated. As nice side effect it simplifies GLES2_UpdateVertexBuffer: All attributes are vectors now. Additional background: * On RaspberryPi it gives a performace win for operations. Tested with [1] numbers go down for 5-10% (not easy to estimate due to huge variation). * SDL_RenderCopyEx was tested with [2] * It works around left rotated display caused by low accuracy sin implemetation in RaspberryPi/VC4 [3] [1] https://github.com/schnitzeltony/sdl2box [2] https://github.com/schnitzeltony/sdl2rendercopyex [3] https://github.com/anholt/mesa/issues/110 Signed-off-by: Andreas M?ller <schnitzeltony@gmail.com> |
||
|---|---|---|
| .. | ||
| direct3d | ||
| direct3d11 | ||
| metal | ||
| opengl | ||
| opengles | ||
| opengles2 | ||
| psp | ||
| software | ||
| SDL_d3dmath.c | ||
| SDL_d3dmath.h | ||
| SDL_render.c | ||
| SDL_sysrender.h | ||
| SDL_yuv_sw_c.h | ||
| SDL_yuv_sw.c | ||