Geometry Nodes: Add option to hide input in modifier #104517

Merged
Jacques Lucke merged 6 commits from HooglyBoogly/blender:geometry-nodes-ui-hide-in-modifier into main 2023-02-11 16:11:13 +01:00
Member

When building a node group that's meant to be used directly in the
node editor as well as in the modifier, it's useful to be able to have
some inputs that are only meant for the node editor, like inputs that
only make sense when combined with other nodes.

In the future we might have the ability to only display certain assets
in the modifier and the node editor, but until then this simple solution
allows a bit more customization.

image

When building a node group that's meant to be used directly in the node editor as well as in the modifier, it's useful to be able to have some inputs that are only meant for the node editor, like inputs that only make sense when combined with other nodes. In the future we might have the ability to only display certain assets in the modifier and the node editor, but until then this simple solution allows a bit more customization. ![image](/attachments/d338a449-0c00-4276-8615-75aed1e0f468)
Hans Goudey added 2 commits 2023-02-09 14:56:31 +01:00
When building a node group that's meant to be used directly in the
node editor as well as in the modifier, it's useful to be able to have
some inputs that are only meant for the node editor, like inputs that
only make sense when combined with other nodes.

In the future we might have the ability to only display certain assets
in the modifier and the node editor, but until then this simple solution
allows a bit more customization.
Hans Goudey added this to the 3.5 milestone 2023-02-09 14:56:38 +01:00
Hans Goudey added the
Interest
Geometry Nodes
label 2023-02-09 14:56:47 +01:00
Hans Goudey requested review from Jacques Lucke 2023-02-09 14:56:53 +01:00
Hans Goudey requested review from Simon Thommes 2023-02-09 14:57:02 +01:00
Hans Goudey added this to the Nodes & Physics project 2023-02-09 14:57:08 +01:00
Jacques Lucke approved these changes 2023-02-09 15:43:49 +01:00
@ -1467,0 +1466,4 @@
const bNodeTree *node_tree = reinterpret_cast<const bNodeTree *>(ptr->owner_id);
if (sock->in_out == SOCK_IN && node_tree->type == NTREE_GEOMETRY) {
col = uiLayoutColumnWithHeading(col, false, IFACE_("Hide"));
uiItemR(col, ptr, "hide_value", DEFAULT_FLAGS, IFACE_("Default Value"), 0);
Member

Default Value seems wrong, it's just the value, has nothing to do with "default" really, does it?

`Default Value` seems wrong, it's just the value, has nothing to do with "default" really, does it?
Author
Member

Yeah, fair. I was thinking about the context of the "Default Value" term in the node editor, but "Value" is simpler and gets the same idea across.

Yeah, fair. I was thinking about the context of the "Default Value" term in the node editor, but "Value" is simpler and gets the same idea across.
HooglyBoogly marked this conversation as resolved
Hans Goudey added 2 commits 2023-02-09 16:11:42 +01:00
Jacques Lucke approved these changes 2023-02-09 16:27:06 +01:00
Simon Thommes requested changes 2023-02-10 12:05:01 +01:00
Simon Thommes left a comment
Member

Works great functionality wise!

I'm not sure about the restructuring of the checkboxes you've done. The fact that these inputs are defined as negative makes it a bit unintuitive, when the Hide part is displayed off to the side. It doesn't read well what the toggles actually do imo.

I would propose to Keep Hide in the names of the toggles, to make it clear. Though I do see that it looks more neat, imo that comes at the cost of readability.

Works great functionality wise! I'm not sure about the restructuring of the checkboxes you've done. The fact that these inputs are defined as negative makes it a bit unintuitive, when the `Hide` part is displayed off to the side. It doesn't read well what the toggles actually do imo. I would propose to Keep `Hide` in the names of the toggles, to make it clear. Though I do see that it looks more neat, imo that comes at the cost of readability.
Hans Goudey added 30 commits 2023-02-10 19:34:24 +01:00
As described in #95966, replace the `ME_EDGEDRAW` flag with a bit
vector in mesh runtime data. Currently the the flag is only ever set
to false for the "optimal display" feature of the subdivision surface
modifier. When creating an "original" mesh in the main data-base,
the flag is always supposed to be true.

The bit vector is now created by the modifier only as necessary, and
is cleared for topology-changing operations. This fixes incorrect
interpolation of the flag as noted in #104376. Generally it isn't
possible to interpolate it through topology-changing operations.

After this, only the seam status needs to be removed from edges before
we can replace them with the generic `int2` type (or something similar)
and reduce memory usage by 1/3.

Related:
- 10131a6f62
- 145839aa42

In the future `BM_ELEM_DRAW` could be removed as well. Currently it is
used and aliased by other defines in some non-obvious ways though.

Pull Request #104417
This was missed when doing the refactoring in #104500
It didn't seem to have any effect until I worked on clamping the view
Assets: Implement viewport drag and drop for geometry nodes
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
bfa7f9db0e
Currently there's no way to assign a geometry node group from the asset
browser to an object as a modifier without first appending/linking it
manually. This patch adds a drag and drop operator that adds a new
modifier and assigns the dragged tree.

Pull Request #104430
Geometry Nodes: Edges to Face Groups Node
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
50dfd5f501
Add a new node that groups faces inside of boundary edge regions.
This is the opposite action as the existing "Face Group Boundaries"
node. It's also the same as some of the "Initialize Face Sets"
options in sculpt mode.

Discussion in #102962 has favored "Group" for a name for these
sockets rather than "Set", so that is used here.

Pull Request #104428
Fix: Sequencer "Pan" label using incorrect keyword 'heading_ctxt'
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
1649921791
Oversight in db87e2a638

Reviewed By: ISS
Differential Revision: https://archive.blender.org/developer/D17213
Cleanup: Fix const correctness warning in recent commit
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
50918d44fb
Fixed #104435: Use correct conditional logic when testing if a new NLA strip can be added in the rna_NlaStrip_new method
Fix #104383: don't update declaration for clipboard copy
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
2cfc4d7644
When nodes are copied to the clipboard, they don't need their declaration.
For nodes with dynamic declaration that might depend on the node tree itself,
the declaration could not be build anyway, because the node-clipboard does
not have a node tree.

Pull Request #104432
Cleanup: Move 6 sculpt-session-related files and header to C++
Some checks failed
buildbot/vdev-code-daily-coordinator Build done.
5c8edbd99b
To allow further mesh data structure refactoring. See #103343

Pull Request #104540
GPU: Cleanup GPU_batch.h documentation and some of the API for consistency
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
7e0e07657c
Documented all functions, adding use case and side effects.

Also replace the use of shortened argument name by more meaningful ones.

Renamed `GPU_batch_instbuf_add_ex` and `GPU_batch_vertbuf_add_ex` to remove
the `ex` suffix as they are the main version used (removed the few usage
of the other version).

Renamed `GPU_batch_draw_instanced` to `GPU_batch_draw_instance_range` and
make it consistent with `GPU_batch_draw_range`.
Move the function for getting the language code associated with the
user manual into a utility function (from the generated
rna_manual_reference.py).

This allows other parts of Blender to create a manual URL based on the
current locale preferences and environment.

Ref !104494
Use bpy.utils.manual_language_code() create manual URL's instead of
assuming English.
- undeclared variable warning.
- unreachable-code-return warnings.
- array-parameter, mismatch bound.
- 'requires' is a keyword in C++20, (rename to requires_flag).
Cleanup: spelling in comments
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
4cbe0bff34
The generator now skips these with a warning, they will need to be
corrected in the user manual.

This caused tests/python/bl_rna_manual_reference.py to fail looking
up URL's.
RNA: return a dummy language value when WITH_INTERNATIONAL=OFF
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
c2c62c3618
Without this, every access to "language" would warn that the enum
value didn't match a value in the enum items.

This made the bl_rna_manual_reference.py test output practically
unusable.
Tests: minor updates to make bl_rna_manual_reference more useful
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
b77c82e2bb
- Avoid flooding the output with every match that succeeds.
- Report patterns listed in the manual that don't match anything in
  Blender.
- Disable external URL lookups, this is too slow.
  Instead use a LOCAL_PREFIX (a local build of the manual)
  or skip the test.
Cycles: Fix MetalRT checkbox not hooked up to device on AMD
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
01480229b1
(Follow on from D17043)
On AMD Navi2 devices the MetalRT checkbox was not hooked up properly and had no effect. This patch fixes it.

Co-authored-by: Michael Jones <michael_p_jones@apple.com>
Pull Request #104520
Fix #104026: Click-Drag to select graph editor channels no longer working
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
51ceeb506f
Box-Selecting channels in the dope sheet with click-drag was no longer possible as of Blender 3.2

Due to the removal of tweak events the box select operator was always shadowed by the click operator.

Original Phabricator discussion here: https://archive.blender.org/developer/D17065

Use `WM_operator_flag_only_pass_through_on_press` on click operator to fix it

Co-authored-by: Christoph Lendenfeld <chris.lenden@gmail.com>
Pull Request #104505
Sequencer: Don't create undo step when click-select does nothing
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
5d30c3994e
When the sequencer is empty (i.e., there are no sequences),
we would have the deselect_all variable set to true called
ED_sequencer_deselect_all to select any existing sequences.

Ref !104453
Fix #104514: GPencil merge down layer misses some frames
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
dc9f7fe64f
When merging two gpencil layers, if the destination layer had a keyframe
where the source layer did not, strokes of the previous keyframe
in source layer were lost in that frame.

This happened because the merge operator was looping through
frames of the source layer and appending strokes in the
corresponding destination layer, but never completing
other frames than the ones existing in the source layer.

This patch fixes it by first adding in source layer
all frames that are in destination layer.

Co-authored-by: Amelie Fondevilla <amelie.fondevilla@les-fees-speciales.coop>
Pull Request #104558
Sculpt: Fix Dyntopo Warnings
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
88f9c55f7f
Because of T95965, some attributes are stored as generic attributes
in Mesh but have special handling for the conversion to BMesh.

Expose a function to tell whether certain attribute names are handled
specially in the conversion, and refactor the error checking process
to use it. Also check for generic attributes on the face domain which
wasn't done before.

Author: Hans Goudey
Reviewed By: Joseph Eagar

Co-authored-by: Joseph Eagar <joeedh@gmail.com>
Pull Request #104567
Geometry Nodes: Experimental option for Volumes
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
bad2c3b9ef
Adds an experimental option under "New Features" in preferences,
which enables visibility of the new Volume Nodes.
Right now this option does nothing but will be used during development.
See #103248

Pull Request #104552
Cleanup: Use lambdas in mesh mapping callback, remove unused arguments
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
284cdbb6cf
Using callback functions didn't scale well as more arguments are added.
It got very confusing when to pass tehmarguments weren't always used.
Instead use a `FunctionRef` with indices for arguments. Also remove
unused edge arguments to topology mapping functions.
Fix: Inaccessible default for node group image sockets
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
0ea15a6fbb
The type was just skipped when drawing defaults for the image sockets.
This just adds `threading::parallel_for` and `threading::parallel_invoke` in a few
places where it can be added trivially. The run time of the `separate_geometry`
function changes from 830 ms to 413 ms in my test file.

Pull Request #104563
Revert "Un-ignore modules in .gitmodules configuration"
All checks were successful
buildbot/vdev-code-daily-coordinator Build done.
fae661a1ab
This reverts commit aab707ab70.

A different solution to the submodule problem is being considered in #104573.
Revert to the previous behavior that developers are familiar with for now.
Hans Goudey requested review from Simon Thommes 2023-02-10 19:35:53 +01:00
Simon Thommes approved these changes 2023-02-11 12:33:32 +01:00
Simon Thommes left a comment
Member

Thanks for the change, it's less confusing now, I think.

Is there a reason that you changed the order? To me it makes more sense to keep the setting that is exclusive to geometry nodes after the one that shows up for other nodegroup types.

Other than that this is good to go for me.

Thanks for the change, it's less confusing now, I think. Is there a reason that you changed the order? To me it makes more sense to keep the setting that is exclusive to geometry nodes after the one that shows up for other nodegroup types. Other than that this is good to go for me.
Jacques Lucke merged commit 158f809dcb into main 2023-02-11 16:11:13 +01:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
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
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
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 Assignees
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#104517
No description provided.