+1 vote

i want to know what "hint_normal" mathematically does. hints have been put in the documentaiton as a list but what they do is never clarified.

sometimes they do something like srgb conversion, sometimes they trigger reimport.

in Engine by (24 points)
edited by

2 Answers

0 votes

Feel free to disregard the following as it is based solely on my observations

hints are most likely a combination of export and type conversion so in gdscrip it might look something like this

export(Texture) var texture
export(TextureNormalMap) var normal #hint_normal since only the red and green channels are needed for normal maps

The question may be
What type of resource is being loaded? ...... hint normal, albedo, color

Then the internal working probably does

var input = (Type) input
by (4,564 points)
+1 vote

hint_normal triggers the reimport of a texture as a normal map when a texture is supplied using the inspector. This is done because normal maps only need the red and green channels to function (Godot reconstructs the blue channel in the shader). This makes it possible to use more better-looking and efficient RGTC compression for VRAM texture compression.

hint_albdo triggers the reimport of a texture to perform sRGB conversion. When using the GLES3 renderer, Godot performs rendering in linear space to allow for gamma-correct, HDR rendering.

by (10,950 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.