EngineeringPlan: Vertex Painting in Sculpt Mode #72866
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
10 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#72866
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This task will describe the engineering parts of vertex painting in sculpt mode.
My first impression was that the current patch is bloating and IMO that was not necessary. After discussing this, my second thought was that the scope that I had in mind for this patch was different.
The goal of this patch is to come to a clear design/scope/phasing, so it is clear what the changes entails. This is useful for code review, bug fixing, bug triaging and future developments.
The state of this design is still in progress.
Issues
The current patch has several issues in how the original design was translated into code. To name a few:
Architectural Decisions
The project makes a distinction between painting for display/rendering (vertex painting) and painting for modifiers and other parts (color attribute painting). I am not familiar with any designs for attribute painting so it could be that the patch is making assumptions that might be changed in the near future. The project wants to rename the current vertex painting to something else. This is might eventually be the case, but is this the right moment to do this as the future design is still unclear.
Technical Decisions
** [RENDER]: Vertex Color Node will only allow the selection for Sculpt Vertex Groups. To use the attribute vertex colors use the attribute node. Migration code could convert old files using the Vertex Color Node. Other alternative would be to support both Vertex colors in the Vertex color node, but that introduces UX complexity.
** [DRAWING]: Should we support per vertex transparency in the workbench engine? The workbench engine is optimized for animation playback speed, adding actual transparency in more detail than materials would in the right way would need more preprocessing to determine if alpha values are used in the vertex buffer.
Process Issues
During the code review the patch received new features on a regular basis, making the code review process totally not efficient. People are spending a lot of time in reviewing and all needs to reviewed the week after, where new features are added, where it is unclear if the issues that were addressed in the previous review are handled correctly.
It is unclear what the scope of the patch is. In the original discussion it was mentioned that after this project a attribute painting project should start. This patch somehow already tried to take this future project into account. Currently we need to reverse engineer the patch and try to understand what might be the scope of the project. This seems like lacking documentation.
The current patch scope is perhaps too limited as it can crash when you want to do for example attribute vertex painting.
Implementation Issues
Alternatives
Personally I miss the information why the Sculpt Vertex Painting cannot use the
MLoopCol
. If this is possible the workflow for the user is more clear and the implementation does not have so many issues/limitations.Alternative 1: current sculpt patch
The above gives an description of the current sculpt patch, after reverse engineering and discussions.
Alternative 2: expectation how I expected the original design to be implemented
Current design is a goal implementation where attribute painting has been added. As we currently don't have a clear understanding how attribute painting will look like this we should not make any assumptions yet on the implementation. Therefore my expectation was a hard separation between
MVertCol
andMLoopCol
. Both could be used during rendering and an operation to sync between the activeMVertCol
andMLoopCol
.Current patch has parts of it, but as the current development is limiting functionality it is unclear if this alternative is actually what is the goal for
Roadmap
It is unclear what the scope is of Sculpt Vertex Painting. What makes it hard to describe a roadmap at this time. Below mentioned the initial idea I had when starting on reviewing the patch.
Long term road map
A sculptor wants to paint during sculpting. A modeller/lighter wants to use vertex painting as it can hold more precise data.
Will merge current vertex painting into attribute paintingWhat should be done in the current patch**
This part of the design isn't finished and will change when more and more gets clear in the current design.
Focus on the bare minimum and the stuff that has been agreed upon. Don't add fancy stuff on top of it, before we settle on the basics.
As in the initial design is mentioned that sculpt vertex painting is an implementation for an edge case, so should not take control of the other implementations as it currently does.
MLoopCol
this isn't a problem, but as we are not storing the data here this limitation introduces some edge cases with incorrect feedback to users. The later could also be solved by user documentation, but as there isn't any design or user documentation at all...** Activate vertex painting mode (No vcol layer available in vertpaint, but batches requested anyway!)
MVertCol
layer, a default needs to be added.If this is the case, than we should also find better names for Sculpt Vertex Color...
Changed status from 'Needs Triage' to: 'Confirmed'
Added subscribers: @Jeroen-Bakker, @PabloDobarro
(WIP) EngineeringPlan: Vertex Painting in Sculpt Modeto EngineeringPlan: Vertex Painting in Sculpt ModeSome initial notes
Whatever design or naming convention we choose, the most important thing is that we need to make sure the users know they should never use MLoopCol (the current vertex paint mode) for painting after merging the patch. The new implementation with the new tools is superior in every single way when it comes to painting and the current vertex paint mode will be obsolete. There won't be any use cases for painting in the old vertex paint mode.
The only benefit the current vertex paint has (MLoopCol) is per face colors, which are not important for painting and that mode has a big number of issues and design limitations for supporting proper painting. They are only important when users need to store custom data into the mesh (as we saw in the Ubisoft talk in the Blender Conference). We still not have any tools for it (that is what the attribute paint mode should solve). Until final attribute paint is done, we will have a half-finished attribute paint mode by renaming the old vertex paint and MLoopCols, which should be fine because that is what people were using for that use case.
So, the situation is:
For these reasons, I think that the new implementation based on MVertCol should take precedence over the old vertex paint mode. The old Vertex Paint, Vertex Colors and MLoopCols should be renamed to something that does not suggest painting to avoid user confusion (color data? custom color data?...) and leave that mode there for compatibility and to support the minimum requirements of attribute painting until we have the full mode.
That is still the idea but I'm not changing the name of the modes/attributes in that patch to avoid making it bigger. In the release after merging the patch, the idea would be to have the modes/data renamed:
Yes, that is the idea. After merging the patch MVertCol should be the main datalayer to deal with mesh colors inside Blender, so it should have direct connection to the renderers. The current MLoopCol would be another mesh attribute that can store colors/ID/vectors/masks... so it does not make sense to render that by default. That is why I made the vertex colors node to output MVertCol, but the attribute node can output both (this way we can keep compatibility with old files without converting the datalayer)
Agree, but I think we can solve this by changing the name of the current vertex painting tools to something that does not tell the users that it is a "painting" mode.
I made it like that because the sculpt mask is also rendered that way and it is another vertex attribute. I don't think that there are cases where this is going to be a problem. In this case, we need to choose whatever is faster.
I did not test cycles, but EEVEE works for me.
It should not, last time I checked everything was working fine when using only MVertCol layers.
This is why I'm adding the full paint brush to the patch. We need to test that the main brush actually works for painting and the color math of all its properties is correct. If we don't get the behavior of the brush exactly right from the beggining, it does not matter how many time we spend working on this because nobody will want to use this mode.
After changing the way MVertCols render, my idea was to render MLoopCols using the overlay in the "attribute paint" mode, but that was removed in a recent commit. Can we bring that overlay back?
When attribute paint is fully implemented, my idea would be to make that overlay customizable to display any attribute data (render the data as colors, as a gradient, as an ID map...)
Totally not sure about what you say as there are many usecases that just cannot be done with MVertCol implementation. Just look at requirements from gaming modellers where you can have a fully red and a fully blue face against each other. This can be done with the current vertex painting.
Environment artist that use vertex colors for material blending. Low poly artists. Just to name a few of usecases that will be limited if this patch will be added in the current state.
Your patch breaks rendering, current files and can only be accepted when they will not break. Or when it has been discussed to be a acceptable consequence. Many file formats also uses MLoopCols to store colors.
I never heard of a decision to remove vertex paint , before adding a replacement system. If I read it correctly you want to remove or at least limit users to use them with this patch.
Looking at the original design it is mentioned totally differently so I would like to see when and who made that decision.
Ps don’t see this as criticism. I just think that in the end most high dense modellers would use a sculpt based vertex painting. I just think that this patch tries to do things in the wrong timing.
Those use cases are related to using MLoopCol as data (material masks, for example). All those "painting" options are still going to be supported as the current vertex paint mode is only going to be renamed. Also, using brushes for painting low poly models or material mask is not the ideal solution. For that tasks it would be better to have proper precision tools (similar to edit mode selections) than a brush. With this change we should not loose any functionality, we are just redirecting users to a more advanced painting mode if they want to paint.
When I'm talking about painting I'm referring to the functionality of dedicated painting/texturing/illustration software, not to the fact that a mode uses a brush to modify the data. Modes can still have a brush tool for some task, but that does not mean they are painting modes. Something like this https://twitter.com/pablodp606/status/1213250893199613952 is just impossible to do in the current vertex paint mode, but it is doable with the new sculpt vertex colors and tools because it was designed for that. When users try to use vertex paint (or texture paint) for actual painting, they often get frustrated because the current modes lack a lot of feature and have so many design limitation related to painting. We just need to add a way to differentiate the two things:
Painting modes features: Wet paint, dynamic brush tip shape, advanced color mix modes, noise generators, particle brushes, image/color filters... this is what the sculpt vertex colors patch tries to introduce and what should be added to texture painting in the future.
Modes that "can use a brush" features: Mesh element selections, custom overlays, select and assign operators, value gradients based on topology, smoothing element selections... This is what modes like weight paint, the future attribute paint or the renamed MLoopCol vertex colors should have. And, on top of that, they can have a basic brush. This is were the use cases you mentioned should be supported, but it does not make sense to add wet paint or particle brushes to paint a low poly model, a material mask or the weights of a rig.
I think the only change required in previous files with the patch is to change the vertex colors node for the attribute node with the layer name (is this possible to do in versioning?). After that, I think it should render exactly the same.
The ideas you described are nowhere mentioned and discussed. When misinterpreted/understood this leads to a huge amount of regression failures (by design or understanding) around Blender. It also introduces a different workflow then described in the original design task. We just need to be clear that what will be delivered is well designed, discussed agreed upon and won't leave unsolvable regressions. This is my biggest concern as this project lacks written down vision/design.
Have you tested the current implementation already with modifiers, particles/hair, physics, python api etc, here the vertex colors are related to actual colors, what do users and developers expect here. Also professional used file formats needs to be addressed. This is what I mean that the patch might get bloated. My proposal is to take smaller steps and start with a design and feasible short term goals as 1) attribute painting is still unclear, 2) there are workflows that we have missed and might introduce regressions.
What do you think why Sculpt mode vertex painting is mentioned to be an edge case in the original design? The implementation seems like to imply something differently. hence my proposal was to limit the implementation to be more in line with an edge case. Can you start with the UI/UX design?
Added subscriber: @Frozen_Death_Knight
@PabloDobarro @Jeroen-Bakker I just wanted to come in quickly and give my 2 cents. After having followed the development and dicussion surrounding this new painting workflow for some time, I believe it is about time that the patch got its own experimental Blender branch just like the old sculpting branch. I feel like this feature has ballooned up to the point that it needs more testers before being allowed on any Alpha master branch. The regular branches don't seem suited to deal with design issues like these and the sculpt branch ended up being a great success considering the amount of features that ended up in the official releases.
I think it would be a lot easier to figure out a solid plan that all parties would agree on if more 3D artists got to test and leave more feedback on the new features.
Added subscriber: @riceart
If possible, please bring back Size and Strenght Widget from 2.80 for all modes Sculpt/Paint/Vertex Paint. It can be somwhere as optional behavior i dont mind if its not default anymore. The new one is unusable on screen tablets.
And, second please bring back cursor (round circle) behavior from 2.80. RIght now when im making stroke it disapears. Its happening in sculpt mode so please do not add this to paint mode.
best regards, Paul
Added subscriber: @Ko
What about weight painting? Its integration will be more straightforward than with colors as weights assigned per vertex and cant be rendered.
@Jeroen-Bakker The ideas were discussed the first time I went to the studio with Brecht and Sergey and they mentioned in #67520. That task is about splitting painting functionality into a "artistic painting" mode and a "technical painting mode", which is what I'm trying to do in D5975. This is probably a misunderstanding because of the weird names that are used in the UI and the patch description, but the intention is not to include any compatibility breaking change and it is not trying to implement anything that wasn't already discussed. I think that if we keep the "vertex color" node to keep outputing MLoopCol, everything should work the same as before. The whole "sculpt vertex colors" workflow was introduced in the sculpt branch, where it is more complete (the UI is more polished and most features are complete and well integrated), so it already was tested for a while by a lot of users. We can use the sculpt branch to discuss UI/UX design while testing it on something that "works" instead of discussing it on paper.
I can split the patches into smaller steps if that makes the review process easier. The problem with that is that we can easily break things or make design mistakes during the merge process because we never tested if the thing works as a whole before starting adding code to master. I already have most the code ready for all the initial features of this new paint mode to support a properly designed painting workflow, but they are split into multiple patches with a lot of shared code and dependencies between them. I personally would prefer adding everything to a single patch to make sure we have a fully functional feature from the first commit. It may also help to make the process less confusing as we would avoid intermediate stages with weird unfinished features and mode naming that does not make sense for what it is trying to do.
It is not about the patch, this is about the lack of documentation and transparency of the project. I want to come to an understanding what will be part of the first release. Currently during review the patch too small as it didn't address the scope of the first release. Also there is nowhere described what the scope is and if multiple releases are needed.
The only written information I have is a limited patch, a list of one liners that could be well thought of, or not and a very global idea of the project. During testing I find limitations and the patch is increased. This tells me that the way how this project is handled and and we should fix that.
I also miss the decisions and alternatives that have been evaluated. As you see all documentation.
Doing reverse engineering of a patch to come to an understanding of the decisions that have been made is bad, as this means that after release trianging, bug fixing, feature development will be lacking.
@PabloDobarro I updated the description with your feedback. I think that the project documentation is lacking and that that needs to be addressed. Current lack of documentation leads to misunderstanding the scope of the patch vs the scope of this project vs the scope of several projects.
A patch should ideally be a minimum change, but should always be complete on user level. If this project needs more patches, these patches should be planned/described so during review we know what the scope of a current in review patch is, and that some parts will be addressed in a next patch. Currently I am spending hours per week just to understand the scoping, this is not the way how projects should be executed. Any professional developer knows that. I am only asking you as you are executing this project to come up with this documentation. I can help out (in guidance), but the actual writing should be done by the project.
Check how other projects do this. For example UDIM.
Added subscriber: @Wesley-Rossi
Added subscriber: @Vyach
This issue was referenced by
f7bbc7cdbb
Added subscriber: @lichtwerk
Just want to add here that since we can bake to vertex colors, it can now happen that if you have the experimental feature turned OFF but still have a sculpt vertex color layer on your mesh, baking will take place to that sculpt vertex color layer with no way to look at it, see #86455 (Baking to Vertex Colors bakes without result to look at (if sculpt vertex color layer is present but experimental option is disabled))
Added subscriber: @brecht
Changed status from 'Confirmed' to: 'Archived'
This task is outdated, specific tasks regarding vertex colors are now in #97101 (Color attribute improvements).