Very simple question i hope. I just want to texture a simple quad with a grey scale texture: the result i’m looking for is that pixels alpha should follow the texture, i.e. trasparent where texture pixels are black, alpha=1 if are white, and so on for intermediate grey values.
Can you tell me how shouldi modify the actual fragment shader ? Thanks
Excuse me for poor explanation, i’ve two screenshot that will explain better, i hope, what i’d like to achieve. The shots show a sphere with a 3d noise texture applied on it. First shot shows what it looks like now, second shot what i’d like to get.
Here are the vertex and frag shaders code.
Alpha blending is done after the pixel shader is run. It works whether you’re in fixed pipeline or in programmable pipeline. You should have it enabled.