Checker pattern problem

Hello. I had a problem with the generated texture checker.
I use it for the background layer in the program, like in Photoshop. Initially, it looks correct.
The problem is that when I zoom, the squares on the texture are shifted. Some become smaller, others more a little.
With zoom, I regenerate the texture so that the cells remain the same size regardless of the zoom value.

out vec4 FragColor;

in vec2 texCoord;


void main(void)
{
    float total = floor(texCoord.x*2.0f) + floor(texCoord.y*2.0f);
    bool isEven = mod(total, 2) == 0;

    vec4 col1 = vec4(0.76,0.76,0.76,1.0);
    vec4 col2 = vec4(0.92, 0.92, 0.92, 1.0);
    FragColor = (isEven)? col1:col2;
}

On the first image everything is right (view without zoom). The second picture shows how the squares moved.[ATTACH=CONFIG]1791[/ATTACH][ATTACH=CONFIG]1792[/ATTACH]

Sorry for bad english.

[QUOTE=SJerin;1291657]The problem is that when I zoom, the squares on the texture are shifted. Some become smaller, others more a little.
With zoom, I regenerate the texture so that the cells remain the same size regardless of the zoom value.
[/QUOTE]
Either you aren’t recalculating the texture coordinates correctly, or you’re getting rounding errors (the latter may be an issue with OpenGL ES).

If you want the texture scaling to remain constant in screen space, you might want to use gl_FragCoord.xy rather than using interpolated texture coordinates.