Is it possible to override or disable blending per pixel I'm rendering transparent objects in separate framebuffer then compositing it with opaque one to get final image. 

The transparent pass has additive blending:

glBlendFunci(0, GL_ONE,  GL_ONE);


so transpareny seems work perfect (I used weighted, blended OIT). Now I have problem if I set all surfaces' alpha to 1. Transparency works if alpha is between 0 and &lt; 1 but not work as expected if alpha = 1. In this case (alpha=1) transparency surface seems opaque on opaque surface[s], but it also appears as semi-transparent on transparent surface[s].

I think additive blending causes this issue/artifact, how can I fix this? I want to transparent surfaces appear opaque if alpha is set to 1 in fragment shader. I can't disable blending because it will disable whole transparency process. 

What I want to do is control blending in fragment shader or per-fragment blending; is this possible? Overriding old values of some fragments in framebuff e.g. to zero (0,0,0,0) could also help to fix/control blending, because I can put some values in blend equation to get what I want. 

I'm asking this because maybe there is a way to simulate this which I don't know yet. Maybe I can fix this with another rendering passes/targets, I will give a try, any help would be appreciated  

EDIT:

The first image is rendered with alpha = 0.5 and the second one is rendered with alpha = 1.0. As you can see transparency is still active among transparent objects. The pink plane overrides Suzanne mesh and bottom plane but not sphere :( Both sphere and pink plane are rendered in transparency pass.
You seem to be using additive blending against its purpose. Additive blending is supposed to represent light from multiple sources being combined. It is not physically possible for one source of light to eclipse another.

Furthermore, even if you hack an alpha of exactly 1 to mean "opaque", you will get a strange circumstance where an alpha of 0.99 is quite far from "nearly opaque". So if you're animating "opacity", then you're going to get a sudden jump from appearing to be transparent to completely opaque.

Lastly, opacity with blending can only be achieved if you render the objects in the correct order. So even if you use this hack on the pink square, it will only eclipse the sphere if the sphere is rendered before the square. Using this hack will lose you the order-independency of additive blending.

That last part makes what you want essentially impossible.

However, if you wish to persist in this, there is a way to do what you've asked for. You need to use dual-source blending (which means you can only be rendering to a single render target). This is a technique whereby you output two values from the FS to the same render target:

layout(location = 0, index = 0) out vec4 outputColor0;
layout(location = 0, index = 1) out vec4 outputColor1;


Both values can be used in the blending equation. This means there are two source colors. The index zero source color is the source color used directly in the additive blending equation. The index one source color is how you turn off the destination color and achieve opacity:

glBlendFunci(0, GL_ONE,  GL_SRC1_ALPHA);


With this blend function, if you want a fragment shader's output to be opaque, you set outputColor1.a to 0. Otherwise you set it to 1. The other components are irrelevant.

Of course, you must still suffer the limitations of dual-source blending. Namely, that you can only render to a single render target on most hardware.