1
$\begingroup$

This may be a bit OCD from me, but whenever I see people mention the pink missing textures I yell magenta (and get strange looks from my family). I have looked in the manual, but can not find any reference to the color. There also does not seem to be a preference to change the default missing texture color. Finally I have also tried to get it from a Blender output itself, but this depends on the lighting/settings etc.

Does anyone know how to get the actual RGB values for the missing textures, ignoring lights, shadows etc? I need to know if I am a crazy or just crazy smart.

$\endgroup$
2
  • 1
    $\begingroup$ Hello :).You're right, it really is pure Magenta (rgb:255,0,255). Just plug the image texture node directly into the material output. And set color management to Standard to see it. $\endgroup$ Commented Feb 20, 2020 at 14:15
  • $\begingroup$ Thank you very much @JachymMichal - I wouls have accepted this as an answer if I could as I was not aware of that feature. $\endgroup$
    – Derrick
    Commented Feb 20, 2020 at 23:54

1 Answer 1

3
$\begingroup$

The color, that is used when a texture is not found, is defined by four macros in texture.h. The color is magenta with full alpha (no transparency).

#define TEX_IMAGE_MISSING_R 1
#define TEX_IMAGE_MISSING_G 0
#define TEX_IMAGE_MISSING_B 1
#define TEX_IMAGE_MISSING_A 1

Code is licensed under Apache 2.0

The macros are used whenever image data isn't available, e.g. in ImageManager::device_load_image() image.cpp when the loading of an image failed or in PointDensityTextureNode::compile() shader_nodes.cpp when no texture has been selected in the Image Texture node.

$\endgroup$
3
  • $\begingroup$ I changed the rgb values, but to no effect. Is there something else I've got to do? $\endgroup$ Commented Apr 30, 2021 at 13:34
  • 1
    $\begingroup$ @FatalBulletHit You have to compile Blender as described in the wiki. $\endgroup$ Commented Apr 30, 2021 at 13:59
  • $\begingroup$ ah, was hoping it'd read the file on every launch or so, thanks for the info! :) $\endgroup$ Commented Apr 30, 2021 at 15:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .