Geometry Nodes: Extend add modifier menu with node group assets #111717
No reviewers
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Code Documentation
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
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
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
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
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
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
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#111717
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "HooglyBoogly/blender:geometry-nodes-is-modifier-trait"
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?
Implements part of #111538.
Change the modifier add button to create a menu with submenus.
Extend the submenus dynamically with geometry node group assets.
This makes it much simpler to share and use custom modifiers.
Node groups get a new "Is Modifier" property, which is controllable
in a popover in the node editor header when the group is an asset.
The built in modifier can be rearranged in different categories in
a next step. For now the existing organization is used, except for
the geometry nodes modifier, which is called "Empty Modifier" and
put in the root menu.
The changes in !110855 and !110828 will be important to improve
interaction speed with the new UI. Those are planned for 4.0 as well.
@ -29,0 +32,4 @@
def draw(self, context):
layout = self.layout
ob_type = context.object.type
if ob_type in {'MESH', 'CURVE', 'FONT', 'SURFACE', 'VOLUME', 'POINTCLOUD'}:
All these if statements are pretty ugly, but since we're not going to be adding more of them in the future, I think it's better to keep things simple and not abstract it.
Hans Goudey referenced this pull request2023-08-31 04:45:03 +02:00
Quick Feedback:
I'm all for consistency, but in this case the UX is not as optimal...
Proposed UX:
Previous UX:
We have slowed things down by +60% for every day use of modifiers.
Alternative:
You missed the part that mentions two other patches related to this, that add search in menus and recent items to search.
Plus the re-organization of this menu so modifiers are easier to find. Much better than the current wall of options that are just as hard to scan.
Yeh, saw the others. I am ok with this patch and will swallow that pill in the name of consistency, but thought to voice the feedback none-the-less. There was some knee-jerk kickback in discord from other users.
🟢 Green lit - for consistency sake
Great! Works as expected.
The only small thing that bothers me is the name
Empty
, which can be confused with the object type.How about:
Procedural
Procedural Modifier
Custom
Empty Modifier
I'm not sure if it should be part of this patch but making
Shift+A
(with the mouse over the Modifier properties) bring up this menu would be great :DHans Goudey referenced this pull request2023-09-01 15:28:51 +02:00
@ -225,4 +229,20 @@ PointerRNA persistent_catalog_path_rna_pointer(const bScreen &owner_screen,
const_cast<asset_system::AssetCatalogPath *>(&path)};
}
void draw_menu_for_catalog(const bScreen &owner_screen,
This seems placed a bit arbitrarily here. The file provides high level catalog editing functions, while this is a UI layout utility. Could be a template even.
@ -44,0 +143,4 @@
}
/** \note Does not check asset type or meta data. */
const asset_system::AssetRepresentation *operator_asset_reference_props_get_asset(
The function names should make it more clear that they trigger loading of all asset libraries. This is a rather significant operation.
Previously these were local scope functions, if they become generalized for reuse we need to be more thoughtful with naming.
It also needs to be clear that this triggers loading in the background, so there may not be a result immediately.
@ -44,0 +152,4 @@
&ptr, "asset_library_identifier", nullptr, 0, nullptr);
weak_ref.relative_asset_identifier = RNA_string_get_alloc(
&ptr, "relative_asset_identifier", nullptr, 0, nullptr);
return find_asset_from_weak_ref(C, weak_ref, reports);
Isn't this leaking memory? Where are the identifier strings freed?
No, because the struct has a destructor that frees the strings:
~AssetWeakReference();
Thanks for the review. I made a new include and cc file for the common code between the place we've extended menus. It may not be the perfect abstraction but it's definitely better than scattering this stuff around like it was.
One copy & paste error to fix, otherwise looks good on a quick glance.
@ -0,0 +5,4 @@
/** \file
* \ingroup edasset
*
* UI/Editor level API for catalog operations, creating richer functionality than the asset system
This comment should not be copied over.