renderer-native: Try to choose the first matching EGL config
As per regular
eglChooseConfig semantics, which means choosing the
highest color depth.
The reason why it was hard-coded to
GBM_FORMAT_XRGB8888 originates from
commit 712ec30c to fix #2 (closed)
However that entire problem was later removed by commit 14c706e5, so
we don't need to limit the GBM format any more.
In practice this means most systems should now get a 30-bit color mode set instead of 24-bit. This works on modern Intel systems (the 'iris' Mesa driver) for example. It doesn't work on Raspberry Pi FKMS though, which is one reason why we also need to check the pixel format support of the primary plane here...
For most drivers we would expect no change in memory bandwidth requirements since both the old and new formats are 4 bytes per pixel.
Compositing of native Wayland GL clients is made slightly more efficient using 30-bit because they already default to XR30 or AR30 formats when possible. Only legacy Xwayland clients and most SHM clients still using 24-bit color will see slightly slower compositing.