GPv3: Overlay for Weight Paint mode #118273
No reviewers
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
4 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#118273
Loading…
Reference in New Issue
No description provided.
Delete Branch "SietseB/blender:gpv3-weight-paint-overlay"
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 PR implements the viewport overlay for Weight Paint mode in GPv3.
In Weight Paint mode the stroke points are colored depending on their
weights in the active vertex group.
@fclem I'm not sure about the approach of reusing the selection buffers to fill the weight values with. What's your opinion on that?
I guess that's fine. This patch is only making the edit point follow the edit strand shader.
The only issue I see with that is that you are loosing the selection state visibility. It is an issue with particle edit since only the selected points can be painted on. I don't know how it maps to GPencil on that subject. But I would rather see the behavior unified.
So I'm ok with the patch as it is, but consider the UX of different mode behaving differently.
Added a few comments.
@ -8,0 +9,4 @@
vec3 weight_to_rgb(float t)
{
if (t == no_active_weight) {
Couldn't this be
-1
instead ?IIRC This was specifically chosen to be a very uncommon value to be able to detect invalid weights around valid range of |0..1]. Maybe @angavrilov will remember exactly why.
But it's just used as "the color when there is no weight for this vertex". Seems weird to try and use a random value for this.
Anyway, since this is used the same way in other places, seems better to refactor it separately if at all.
@ -212,0 +297,4 @@
const int def_nr = BLI_findstringindex(
&curves.vertex_group_names, active_defgroup_name, offsetof(bDeformGroup, name));
const Span<MDeformVert> dverts = curves.deform_verts();
const VArray<float> weights = (def_nr < 0 || layer.is_locked()) ?
Hm I think we should just use the attributes API here.
@filedescriptor Not entirely sure about the status of this one... Should I give my two cents on the
no_active_weight
matter? Or change something in the PR?@SietseB No changes are needed. Because I'm working on changing the render engine, all the PRs that touch rendering are held hostage right now 😅
There is a complier warning
Looks like that line can just be removed.
I removed the bread crumb 😉
@blender-bot build
@blender-bot build
@blender-bot build