Using shader with duplicate padding setting

I have a shader that applies a filter between the nearest and the bilinear filter. This shader is properly applied to the texture regions drawn on the screen under normal conditions. But I use ‘duplicate padding’ setting when packing texture regions into atlas. Because of that the shader is not applied to the edges of the texture regions drawn on the screen.

How do I get the shader to apply to duplicate padding parts too? probably doesn’t matter but i’m using libgdx.


// this is default sb shader for libgdx
attribute vec4 a_position;
attribute vec4 a_color;
attribute vec2 a_texCoord0;
uniform mat4 u_projTrans;
varying vec4 v_color;
varying vec2 v_texCoords;

void main() {
    v_color = a_color;
    // fix for alpha rounding error
    v_color.a = v_color.a * (255.0/254.0);
    v_texCoords = a_texCoord0;
    gl_Position =  u_projTrans * a_position;