Regression: Instanced NURBs or CURVES on mesh vertices are not visible in 3.2+ #100706

Closed
opened 5 months ago by OmarEmaraDev · 23 comments
Collaborator

System Information
Operating system: Linux-5.19.2-arch1-1-x86_64-with-glibc2.36 64 Bits
Graphics card: AMD CEDAR (DRM 2.50.0 / 5.19.2-arch1-1, LLVM 14.0.6) X.Org 4.3 (Core Profile) Mesa 22.1.6

Blender Version
Broken: version: 3.2, 3.3, 3.4.0
Worked: 3.1

NURBS issue caused by edcbf741df
Same for curves if they have geometry, that is broken b9febb54a4

Short description of error

When instancing surfaces like NURB sphere on mesh vertices through parenting, the surfaces are not visible.

instancedNURBS.blend

In 3.1:

20220830-115318.png

In 3.2+:

20220830-115334.png

**System Information** Operating system: Linux-5.19.2-arch1-1-x86_64-with-glibc2.36 64 Bits Graphics card: AMD CEDAR (DRM 2.50.0 / 5.19.2-arch1-1, LLVM 14.0.6) X.Org 4.3 (Core Profile) Mesa 22.1.6 **Blender Version** Broken: version: 3.2, 3.3, 3.4.0 Worked: 3.1 NURBS issue caused by edcbf741df Same for curves if they have geometry, that is broken b9febb54a4 **Short description of error** When instancing surfaces like NURB sphere on mesh vertices through parenting, the surfaces are not visible. [instancedNURBS.blend](https://archive.blender.org/developer/F13433908/instancedNURBS.blend) In 3.1: ![20220830-115318.png](https://archive.blender.org/developer/F13433909/20220830-115318.png) In 3.2+: ![20220830-115334.png](https://archive.blender.org/developer/F13433910/20220830-115334.png)
Poster
Collaborator

Added subscriber: @OmarEmaraDev

Added subscriber: @OmarEmaraDev
Collaborator

blender/blender-addons#100566 was marked as duplicate of this issue

blender/blender-addons#100566 was marked as duplicate of this issue
Collaborator

blender/blender-addons#100553 was marked as duplicate of this issue

blender/blender-addons#100553 was marked as duplicate of this issue
Poster
Collaborator

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'
OmarEmaraDev changed title from Instanced NURB on mesh vertices are not visible in 3.2+ to Regression: Instanced NURB on mesh vertices are not visible in 3.2+ 5 months ago
Poster
Collaborator

Added subscriber: @Zhaoxu-Li

Added subscriber: @Zhaoxu-Li
Poster
Collaborator

Added subscriber: @fzm

Added subscriber: @fzm
Collaborator

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Collaborator

Same for curves if they have geometry (actually think this has been reported before and was ruled a Known Issue, let me dig that up)

Same for curves if they have geometry (actually think this has been reported before and was ruled a Known Issue, let me dig that up)
Collaborator

works with Geometry Nodes:
instancedNURBS_GN.blend

works with Geometry Nodes: [instancedNURBS_GN.blend](https://archive.blender.org/developer/F13434056/instancedNURBS_GN.blend)
Collaborator

Added subscriber: @HooglyBoogly

Added subscriber: @HooglyBoogly
Collaborator

Caused by edcbf741df

Reading the commit message it is not totally clear if this was expected, will raise prio here to get an answer shortterm.
Would assume this ends up as a Known Issue though.

CC @HooglyBoogly

Caused by edcbf741df Reading the commit message it is not totally clear if this was expected, will raise prio here to get an answer shortterm. Would assume this ends up as a `Known Issue` though. CC @HooglyBoogly
Collaborator

related: #93159 (Particle don't emit curves/text in 3.0 beta )
The same thing for curves is broken since b9febb54a4 btw.

related: #93159 (Particle don't emit curves/text in 3.0 beta ) The same thing for curves is broken since b9febb54a4 btw.
lichtwerk changed title from Regression: Instanced NURB on mesh vertices are not visible in 3.2+ to Regression: Instanced NURBs or CURVES on mesh vertices are not visible in 3.2+ 5 months ago

Added subscriber: @Blendphys

Added subscriber: @Blendphys

Dear all:

I can confirm this bug because it quite strongly affects the [Atomic Blender add-on ]] (NURB balls are used to represent the atoms and are inside an [ https:*docs.blender.org/manual/en/dev/addons/import_export/mesh_atomic.html#the-instancing-vertex-structure | instancing vertex structure , with the vertices being the atom positions). With version 3.1.2 it works but starting with version 3.2.x it started to not work. It is not working with the current exp. version 3.4.0.
Note that there is no such an issue with Mesh balls ... .

Operating system: Ubuntu 22.04, 64Bit

Dear all: I can confirm this bug because it quite strongly affects the [Atomic Blender add-on ]] (NURB balls are used to represent the atoms and are inside an [[ https:*docs.blender.org/manual/en/dev/addons/import_export/mesh_atomic.html#the-instancing-vertex-structure | instancing vertex structure ](https:*docs.blender.org/manual/en/dev/addons/import_export/mesh_atomic.html#atomic-blender-pdb-xyz), with the vertices being the atom positions). With version 3.1.2 it works but starting with version 3.2.x it started to not work. It is not working with the current exp. version 3.4.0. Note that there is no such an issue with Mesh balls ... . Operating system: Ubuntu 22.04, 64Bit
HooglyBoogly self-assigned this 5 months ago
Collaborator

I'll try to look into this one tomorrow. Can't say for sure how fixable it is yet though.

I'll try to look into this one tomorrow. Can't say for sure how fixable it is yet though.
Collaborator

Added subscriber: @brecht

Added subscriber: @brecht
Collaborator

It turns out the instances are being created properly, but the dependency graph iterator skips them because of deg_object_hide_original.
I don't really understand that function. I guess it's hiding instances when the instance of type OB_DUPLIVERTS | OB_DUPLIFACES but the parent object did have one of those types turned on?

That said, the comment doesn't make much sense to me: Automatic hiding if this object is being instanced on verts/faces/frames by its parent.
"Being instanced on verts" seems like a typical situation, I'm not sure why it has special attention here.

@brecht, do you remember adding that function in D4109? I'm curious if the issue it's working around is related to missing depsgraph relations or just plain visibility handling.

It turns out the instances are being created properly, but the dependency graph iterator skips them because of `deg_object_hide_original`. I don't really understand that function. I guess it's hiding instances when the instance of type `OB_DUPLIVERTS | OB_DUPLIFACES` but the parent object did have one of those types turned on? That said, the comment doesn't make much sense to me: `Automatic hiding if this object is being instanced on verts/faces/frames by its parent`. "Being instanced on verts" seems like a typical situation, I'm not sure why it has special attention here. @brecht, do you remember adding that function in [D4109](https://archive.blender.org/developer/D4109)? I'm curious if the issue it's working around is related to missing depsgraph relations or just plain visibility handling.
Owner

This is logic has existed forever, but was lost in the new depsgraph and then restored again in D4109. The idea is that if you instance an object on vertices/faces, you automatically hide the original object. We don't want to hide the instances, only the original.

The logic is a bit more complicated for the case where you instance a collection containing a setup like this. In that case the instance of the original object that comes in through the collection should be hidden, but the instances from the vertices/faces should be visible.

The easiest way to keep backwards compatibility may be to set dob->type to the same value it would have had if there were was no geometry set. I also see some code in OBJECT_OT_duplicates_make_real checking dob->type, for that case it may also be better if geometry sets didn't change it.

This is logic has existed forever, but was lost in the new depsgraph and then restored again in [D4109](https://archive.blender.org/developer/D4109). The idea is that if you instance an object on vertices/faces, you automatically hide the original object. We don't want to hide the instances, only the original. The logic is a bit more complicated for the case where you instance a collection containing a setup like this. In that case the instance of the original object that comes in through the collection should be hidden, but the instances from the vertices/faces should be visible. The easiest way to keep backwards compatibility may be to set `dob->type` to the same value it would have had if there were was no geometry set. I also see some code in `OBJECT_OT_duplicates_make_real` checking `dob->type`, for that case it may also be better if geometry sets didn't change it.
Collaborator

This issue was referenced by e508de0417

This issue was referenced by e508de041712cc31588cbc8d63f81970eedf3be0
Collaborator

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
HooglyBoogly closed this issue 3 months ago

Dear Hans, thanks for your kind support!

I tried out the instancing, and see what I get (2 example files). It seems that the instancing only works for 2 vertices so far? ;-) Or is it me who is doing something wrong? Thanks for some comments ... . Cle.

System: 64Bit Ubuntu, Blender Info see last image

Example_cube.blend

Example_KBr_crystal.blend

Blender_info.png

Dear Hans, thanks for your kind support! I tried out the instancing, and see what I get (2 example files). It seems that the instancing only works for 2 vertices so far? ;-) Or is it me who is doing something wrong? Thanks for some comments ... . Cle. System: 64Bit Ubuntu, Blender Info see last image [Example_cube.blend](https://archive.blender.org/developer/F13911341/Example_cube.blend) [Example_KBr_crystal.blend](https://archive.blender.org/developer/F13911342/Example_KBr_crystal.blend) ![Blender_info.png](https://archive.blender.org/developer/F13911351/Blender_info.png)
Collaborator

Thanks for testing @blendphys. It looks like that was broken by a follow-up fix to this fix.
Now I committed another fix for that, your file works for me now: 0e6d893d07

Thanks for testing @blendphys. It looks like that was broken by a follow-up fix to this fix. Now I committed another fix for that, your file works for me now: 0e6d893d07

Yep, now it works, thanks a lot, @HooglyBoogly !

Yep, now it works, thanks a lot, @HooglyBoogly !
Sign in to join this conversation.
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/Collada
Interest/Compositing
Interest/Core
Interest/Cycles
Interest/Dependency Graph
Interest/Development Management
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/Modeling
Interest/Modifiers
Interest/Motion Tracking
Interest/Nodes & Physics
Interest/Overrides
Interest/Performance
Interest/Performance
Interest/Physics
Interest/Pipeline, Assets & I/O
Interest/Platforms, Builds, Tests & Devices
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
legacy module/Animation & Rigging
legacy module/Core
legacy module/Development Management
legacy module/Eevee & Viewport
legacy module/Grease Pencil
legacy module/Modeling
legacy module/Nodes & Physics
legacy module/Pipeline, Assets & IO
legacy module/Platforms, Builds, Tests & Devices
legacy module/Python API
legacy module/Rendering & Cycles
legacy module/Sculpt, Paint & Texture
legacy module/Triaging
legacy module/User Interface
legacy module/VFX & Video
legacy project/1.0.0-beta.2
legacy project/Asset Browser (Archived)
legacy project/BF Blender: 2.8
legacy project/BF Blender: After Release
legacy project/BF Blender: Next
legacy project/BF Blender: Regressions
legacy project/BF Blender: Unconfirmed
legacy project/Blender 2.70
legacy project/Code Quest
legacy project/Datablocks and Libraries
legacy project/Eevee
legacy project/Game Animation
legacy project/Game Audio
legacy project/Game Data Conversion
legacy project/Game Engine
legacy project/Game Logic
legacy project/Game Physics
legacy project/Game Python
legacy project/Game Rendering
legacy project/Game UI
legacy project/GPU / Viewport
legacy project/GSoC
legacy project/Infrastructure: Websites
legacy project/LibOverrides - Usability and UX
legacy project/Milestone 1: Basic, Local Asset Browser
legacy project/Nodes
legacy project/OpenGL Error
legacy project/Papercut
legacy project/Pose Library Basics
legacy project/Retrospective
legacy project/Tracker Curfew
legacy project/Wintab High Frequency
Meta/Good First Issue
Meta/Papercut
migration/requires-manual-verification
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 & Devices
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 Information 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
6 Participants
Notifications
Due Date

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#100706
Loading…
There is no content yet.