In a WebGL I'd like to send a screen space quad through that gets processed by a fragment shader, but have the fragment shader only write out a pixel under certain conditions (say... that it was within a circle, or that the pixel belonged to the positive side of a halfspace defined by a curve equation or something).
Is it possible within a fragment shader to say "don't write a pixel"?
I know this could be accomplished using various other methods like alpha blending, rendering this first and having it put the background color where it doesn't want to draw a pixel, or maybe doing some trick with the depth or stencil buffers. I also know i could create a bunch of geometry to match what it is that I want to render.
Is there a way though to make the fragment shader choose not to write a pixel at all?