#extension GL_EXT_clip_cull_distance : enable // Vertex shader out highp float gl_ClipDistance[2]; out highp float gl_CullDistance[2]; void main(){ // Compute the clip and cull distances for this vertex gl_ClipDistance[0] = ...; gl_CullDistance[0] = ...; gl_ClipDistance[1] = ...; gl_CullDistance[1] = ...; }