ui/sdl: try to instantiate the matching opengl renderer
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Wed, 15 Feb 2023 14:29:29 +0000 (18:29 +0400)
committerMarc-André Lureau <marcandre.lureau@redhat.com>
Mon, 13 Mar 2023 19:48:45 +0000 (23:48 +0400)
commitda3f7a3ab9ea0091955b58f8909dfcee01f4043e
tree2a3f88520350ee69cb37c2ce760a68bb50eb275c
parent82f483dd22c15277cea6047fd46671467eb289a9
ui/sdl: try to instantiate the matching opengl renderer

-display sdl,gl=es didn't actually use OpenGL ES.

Using OpenGL ES allows to use ANGLE, which works generally better than
Windows/OEM OpenGL driver.

(note: users can still bypass the QEMU choice with SDL_RENDER_DRIVER
environment variable)

(note: for some reason, specifying a driver disables batching and
breaks rendering, so enable it explicitly)

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
ui/sdl2.c