Custom buttons in OpenGL ES 2.0 on QOpenGLWindow

Hello,

I made custom buttons in OpenGL ES 2.0 on QOpenGLWidnows. I made a click detection using the color ID method + glReadPixels. It works without problems on Desktop:

button-click-desktop

But when I build it for Android emulator it works in wrong way. Maybe someone had the same problem and knows how to solve it:

button-click-android-emulator

It looks like buttons are here: