Page MenuHome

TexturePaint: Force Workbench Texture Color Mode

Authored by Jeroen Bakker (jbakker) on Jul 5 2019, 12:50 PM.



Big 5-to-12 change; think I have solved all code paths.

When in texture paint mode and in solid mode the object that is being
texture painted will be rendered by the workbench engine with textures.
All other objects would render the same. For other cases the texture paint
draw engine will still draw the texture.

The texture mode draw engine now only drawn the masks. The opacity
sliders influences the texture mask.

This change has been implemented conserably. In the future we need to
look into making this better, like adding support that every object
can be colored differently. Currently when rendering in the workbench
we can have up to 3 different color types active (what the user selected,
the fallback in case no materials have been configured and this one,
forcing textures)

Diff Detail

rB Blender

Event Timeline

Behavior of all this looks good to me, will leave review of implementation to @Clément Foucault (fclem).


Remove comment

I'm happy with the behavior and the code seems good overall.

I can accept it as it is. But if you can clean the codestyle a bit that would be perfect.


I don't really like having this function and using it as test to continue drawing. I think it should be a case inside workbench_deferred_solid_cache_populate to avoid some code duplication and increase readability.


Remove draw variable and use return true here.


Safe issue here.


I'm not really a fan of this, but I can let that pass.

This revision is now accepted and ready to land.Jul 5 2019, 2:48 PM
Jeroen Bakker (jbakker) marked 2 inline comments as done.Jul 5 2019, 3:43 PM