Godot Version
v4.4.1
Question
Is it possible to have specular highlights on otherwise transparent materials? I thought I could simply set the ALPHA to 1 and the ALBEDO to 0 and then use blend_add, but I see don’t see specular highlight when I shine a flashlight at my window. Is my direct specular being multiplied by my ALBEDO? My METALLIC is set to 0 so that shouldn’t happen, correct? (indeed the indirect specular created by my reflection probe comes through just fine).
More specifically, I’m trying to create a glass material. Originally I downloaded it from the assetlib, and while it has the right idea I’m pretty sure the implementation is incorrect (the fresnel term is being used backwards). (EDIT: nevermind I made a mistake) I have created a simplified version for testing purposes.
shader_type spatial;
render_mode blend_add, cull_back, diffuse_burley, specular_schlick_ggx;
void fragment() {
ALBEDO = vec3(0);
ALPHA = 1.;
METALLIC = 0.;
SPECULAR = 1.;
ROUGHNESS = 0.;
}
But alas, despite doing blend_add with alpha 1, direct specular is still nowhere to be seen.