Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Paint colour on colour texture while doing Object Space Normal Painting #235

Open
MJacred opened this issue Jan 17, 2025 · 3 comments
Open
Labels
enhancement New feature or request

Comments

@MJacred
Copy link

MJacred commented Jan 17, 2025

Version 2.1.5 added Object Space Normal Painting. If I understand the video correctly, then you can sample the normal map at some point and then paint over the same area to flatten it: https://www.youtube.com/watch?v=tYLXYEnAE6Q

Can you add the option to change paint the base colour texture with a different colour at the same time?
In other words: allowing the user to paint two different colours on two different textures at the same time. See here: https://www.youtube.com/watch?v=s8N00rjil_4&t=398s

P.S.: thank you so much for enhancing Blender's workflow with textures!

@ucupumar
Copy link
Owner

I don't think that's possible currently in Blender without using a hack. I saw someone do something like that in older Blender (https://github.com/kromar/blender_Material_Brush). I tried it before, but it never worked correctly. Maybe I did something wrong or used the wrong version of Blender.

@ucupumar ucupumar added the enhancement New feature or request label Jan 17, 2025
@MJacred
Copy link
Author

MJacred commented Jan 17, 2025

Thanks :)

Hm… I only skimmed over the code, but it looks doable. They basically track the mouse movements, build brush strokes, and apply them to images.
The performance might not be that good though… There seems to be an issue for that on Blender,, but dunno when that gets done

Currently, I don't have the time for this. Starting March this year I should have some more time, unless you want to tackle this?
If not, I can draft some design in March for you to check, before I attempt any integration into ucupaint


A hack I could think of earlier would be to make use of the normal map texture's alpha channel.
When painting to the normal map, we also write to the alpha channel, which will be used as a mask for the selected base colour to render on top of the current result. And when the user painted with that colour, and switches to another, flush the data in the alpha channel to the base colour texture. Then resetting the alpha channel.
That should bring about the same result with better performance

@ucupumar
Copy link
Owner

Yeah, sure. I'm still focusing on the UI-redesign branch so any help on other things would be appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants