Crash/Assert with two modifiers that require normals data [e.g. DataTransfer] #84664

Closed
opened 2021-01-13 10:02:29 +01:00 by Rajendra Meena · 15 comments

System Information
Operating system: Windows-10-10.0.16299-SP0 64 Bits
Graphics card: GeForce MX150/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.87

Blender Version
Broken: version: 2.90.0, branch: master, commit date: 2020-08-31 11:26, hash: 0330d1af29
Worked: (newest version of Blender that worked as expected)

Short description of error
Crash/Assert with two modifiers that require custom normals data [e.g. DataTransfer]

Exact steps for others to reproduce the error
In a Debug build:

#84664.blend

  • Open File
  • add another modifier that requires normal data (e.g. Displace), or just duplicate the existing modifier

un2.blend

  • Try to go to edit mode of "Vert.011"
  • Blender will crash.
**System Information** Operating system: Windows-10-10.0.16299-SP0 64 Bits Graphics card: GeForce MX150/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.87 **Blender Version** Broken: version: 2.90.0, branch: master, commit date: 2020-08-31 11:26, hash: `0330d1af29` Worked: (newest version of Blender that worked as expected) **Short description of error** Crash/Assert with two modifiers that require custom normals data [e.g. DataTransfer] **Exact steps for others to reproduce the error** In a Debug build: [#84664.blend](https://archive.blender.org/developer/F9572075/T84664.blend) - Open File - add another modifier that requires normal data (e.g. Displace), or just duplicate the existing modifier [un2.blend](https://archive.blender.org/developer/F9562689/un2.blend) - Try to go to edit mode of "Vert.011" - Blender will crash.
Author

Added subscriber: @rajq123

Added subscriber: @rajq123

Added subscriber: @rjg

Added subscriber: @rjg

There appears to be a corrupt mesh in your file, it aborts when opening the project for me. We would need to know how you were able to create such a corruption. With the currently provided information we are not able to identify the source of the problem. Please keep in mind that 2.90.0 is not receiving updates and patches anymore, the current version is Blender 2.91.0.

libc.so.6!__GI_raise(int sig) (/build/glibc-ZN95T4/glibc-2.31/sysdeps/unix/sysv/linux/raise.c:50)
libc.so.6!__GI_abort() (/build/glibc-ZN95T4/glibc-2.31/stdlib/abort.c:79)
_BLI_assert_abort() (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/BLI_assert.c:50)
BKE_modifier_modify_mesh(ModifierData * md, const ModifierEvalContext * ctx, struct Mesh * me) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/modifier.c:1044)
modifier_modify_mesh_and_geometry_set(ModifierData * md, const ModifierEvalContext & mectx, Object * ob, Mesh * input_mesh, GeometrySet & geometry_set) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:902)
mesh_calc_modifiers(Depsgraph * depsgraph, Scene * scene, Object * ob, int useDeform, const bool need_mapping, const CustomData_MeshMasks * dataMask, const int index, const bool use_cache, const bool allow_shared_mesh, Mesh **r_deform, Mesh** r_final, GeometrySet ** r_geometry_set) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:1254)
mesh_build_data(Depsgraph * depsgraph, Scene * scene, Object * ob, const CustomData_MeshMasks * dataMask, const bool need_mapping) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:1872)
makeDerivedMesh(Depsgraph * depsgraph, Scene * scene, Object * ob, BMEditMesh * em, const CustomData_MeshMasks * dataMask) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:2020)
BKE_object_handle_data_update(Depsgraph * depsgraph, Scene * scene, Object * ob) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/object_update.c:193)
BKE_object_eval_uber_data(Depsgraph * depsgraph, Scene * scene, Object * ob) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/object_update.c:379)
std::__invoke_impl<void, void (*&)(Depsgraph*, Scene*, Object*), Depsgraph*, Scene*&, Object*&>(void (*&)(Depsgraph *, Scene *, Object *) __f) (/usr/include/c++/9/bits/invoke.h:60)
std::__invoke<void (*&)(Depsgraph*, Scene*, Object*), Depsgraph*, Scene*&, Object*&>(void (*&)(Depsgraph *, Scene *, Object *) __fn) (/usr/include/c++/9/bits/invoke.h:95)
std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)>::__call<void, Depsgraph*&&, 0ul, 1ul, 2ul>(std::tuple<Depsgraph*&&>&&, std::_Index_tuple<0ul, 1ul, 2ul>)(std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> * const this, std::tuple<Depsgraph*&&> && __args) (/usr/include/c++/9/functional:400)
std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)>::operator()<Depsgraph*, void>(Depsgraph*&&)(std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> * const this) (/usr/include/c++/9/functional:484)
std::_Function_handler<void (Depsgraph*), std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> >::_M_invoke(std::_Any_data const&, Depsgraph*&&)(const std::_Any_data & __functor,  __args#0) (/usr/include/c++/9/bits/std_function.h:300)
std::function<void (Depsgraph*)>::operator()(Depsgraph*) const(const std::function<void(Depsgraph*)> * const this,  __args#0) (/usr/include/c++/9/bits/std_function.h:688)
blender::deg::(anonymous namespace)::evaluate_node(const blender::deg::(anonymous namespace)::DepsgraphEvalState * state, blender::deg::OperationNode * operation_node) (/home/dev/01-data/01-git/blender-git/blender/source/blender/depsgraph/intern/eval/deg_eval.cc:113)
blender::deg::(anonymous namespace)::deg_task_run_func(TaskPool * pool, void * taskdata) (/home/dev/01-data/01-git/blender-git/blender/source/blender/depsgraph/intern/eval/deg_eval.cc:124)
Task::operator()() const::{lambda()#1}::operator()() const(const Task::<lambda()> * const __closure) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/task_pool.cc:118)
tbb::interface7::internal::delegated_function<Task::operator()() const::{lambda()#1} const, void>::operator()() const(const tbb::interface7::internal::delegated_function<const Task::operator()() const::<lambda()>, void> * const this) (/home/dev/01-data/01-git/blender-git/lib/linux_centos7_x86_64/tbb/include/tbb/task_arena.h:93)
There appears to be a corrupt mesh in your file, it aborts when opening the project for me. We would need to know how you were able to create such a corruption. ~~With the currently provided information we are not able to identify the source of the problem.~~ Please keep in mind that 2.90.0 is not receiving updates and patches anymore, the current version is Blender 2.91.0. ```lines libc.so.6!__GI_raise(int sig) (/build/glibc-ZN95T4/glibc-2.31/sysdeps/unix/sysv/linux/raise.c:50) libc.so.6!__GI_abort() (/build/glibc-ZN95T4/glibc-2.31/stdlib/abort.c:79) _BLI_assert_abort() (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/BLI_assert.c:50) BKE_modifier_modify_mesh(ModifierData * md, const ModifierEvalContext * ctx, struct Mesh * me) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/modifier.c:1044) modifier_modify_mesh_and_geometry_set(ModifierData * md, const ModifierEvalContext & mectx, Object * ob, Mesh * input_mesh, GeometrySet & geometry_set) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:902) mesh_calc_modifiers(Depsgraph * depsgraph, Scene * scene, Object * ob, int useDeform, const bool need_mapping, const CustomData_MeshMasks * dataMask, const int index, const bool use_cache, const bool allow_shared_mesh, Mesh **r_deform, Mesh** r_final, GeometrySet ** r_geometry_set) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:1254) mesh_build_data(Depsgraph * depsgraph, Scene * scene, Object * ob, const CustomData_MeshMasks * dataMask, const bool need_mapping) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:1872) makeDerivedMesh(Depsgraph * depsgraph, Scene * scene, Object * ob, BMEditMesh * em, const CustomData_MeshMasks * dataMask) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/DerivedMesh.cc:2020) BKE_object_handle_data_update(Depsgraph * depsgraph, Scene * scene, Object * ob) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/object_update.c:193) BKE_object_eval_uber_data(Depsgraph * depsgraph, Scene * scene, Object * ob) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenkernel/intern/object_update.c:379) std::__invoke_impl<void, void (*&)(Depsgraph*, Scene*, Object*), Depsgraph*, Scene*&, Object*&>(void (*&)(Depsgraph *, Scene *, Object *) __f) (/usr/include/c++/9/bits/invoke.h:60) std::__invoke<void (*&)(Depsgraph*, Scene*, Object*), Depsgraph*, Scene*&, Object*&>(void (*&)(Depsgraph *, Scene *, Object *) __fn) (/usr/include/c++/9/bits/invoke.h:95) std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)>::__call<void, Depsgraph*&&, 0ul, 1ul, 2ul>(std::tuple<Depsgraph*&&>&&, std::_Index_tuple<0ul, 1ul, 2ul>)(std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> * const this, std::tuple<Depsgraph*&&> && __args) (/usr/include/c++/9/functional:400) std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)>::operator()<Depsgraph*, void>(Depsgraph*&&)(std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> * const this) (/usr/include/c++/9/functional:484) std::_Function_handler<void (Depsgraph*), std::_Bind<void (*(std::_Placeholder<1>, Scene*, Object*))(Depsgraph*, Scene*, Object*)> >::_M_invoke(std::_Any_data const&, Depsgraph*&&)(const std::_Any_data & __functor, __args#0) (/usr/include/c++/9/bits/std_function.h:300) std::function<void (Depsgraph*)>::operator()(Depsgraph*) const(const std::function<void(Depsgraph*)> * const this, __args#0) (/usr/include/c++/9/bits/std_function.h:688) blender::deg::(anonymous namespace)::evaluate_node(const blender::deg::(anonymous namespace)::DepsgraphEvalState * state, blender::deg::OperationNode * operation_node) (/home/dev/01-data/01-git/blender-git/blender/source/blender/depsgraph/intern/eval/deg_eval.cc:113) blender::deg::(anonymous namespace)::deg_task_run_func(TaskPool * pool, void * taskdata) (/home/dev/01-data/01-git/blender-git/blender/source/blender/depsgraph/intern/eval/deg_eval.cc:124) Task::operator()() const::{lambda()#1}::operator()() const(const Task::<lambda()> * const __closure) (/home/dev/01-data/01-git/blender-git/blender/source/blender/blenlib/intern/task_pool.cc:118) tbb::interface7::internal::delegated_function<Task::operator()() const::{lambda()#1} const, void>::operator()() const(const tbb::interface7::internal::delegated_function<const Task::operator()() const::<lambda()>, void> * const this) (/home/dev/01-data/01-git/blender-git/lib/linux_centos7_x86_64/tbb/include/tbb/task_arena.h:93) ```
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

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

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

can confirm, will check.

can confirm, will check.

The problematic object is Plane.002. The Vert.001 mesh doesn't cause any issues for me and they also all pass validation. The file below has all objects except Plane.002 attached.

un2_backup.blend

The problematic object is `Plane.002`. The `Vert.001` mesh doesn't cause any issues for me and they also all pass validation. The file below has all objects except `Plane.002` attached. [un2_backup.blend](https://archive.blender.org/developer/F9562752/un2_backup.blend)

Changed status from 'Confirmed' to: 'Needs User Info'

Changed status from 'Confirmed' to: 'Needs User Info'
Member

Added subscriber: @mont29

Added subscriber: @mont29
Member

So, we have an assert that is triggered in the following situations:

  • a DataTransfer modifier with settings that require CD_NORMAL
    • Face Corner Data: Projected Face Interpolated, Nearest Corner and Best Matching Normal, Nearest Corner and Best Matching Face Normal
    • Face Data: Projected Face Interpolated, Best Normal Matching
  • such modifier is followed by another modifier that requires CD_NORMAL
    • Weighted Normal or
    • Displace or
    • copy of the first DataTransfer modifier

related:

So, we have an assert that is triggered in the following situations: - a DataTransfer modifier with settings that require CD_NORMAL - Face Corner Data: `Projected Face Interpolated`, `Nearest Corner and Best Matching Normal`, `Nearest Corner and Best Matching Face Normal` - Face Data: `Projected Face Interpolated`, `Best Normal Matching` - such modifier is followed by another modifier that requires CD_NORMAL - `Weighted Normal` or - `Displace` or - copy of the first `DataTransfer` modifier related: - #73941 (Custom normals from normal edit modifier ignored by further modifiers) - cfdb5b9a8b - 090b8c14d2
Philipp Oeser changed title from Blender closes unexpectedly to Crash/Assert with two modifiers that require normals data [e.g. DataTransfer] 2021-01-13 12:57:04 +01:00

Changed status from 'Needs User Info' to: 'Confirmed'

Changed status from 'Needs User Info' to: 'Confirmed'

Added subscriber: @ideasman42

Added subscriber: @ideasman42

I don't know why there are those asserts in the modifier code... @ideasman42 maybe you know more?

To me it make sense we re-use already computed normals if they exist, instead of nuking them and re-building them for each and every modifier?

I don't know why there are those asserts in the modifier code... @ideasman42 maybe you know more? To me it make sense we re-use already computed normals if they exist, instead of nuking them and re-building them for each and every modifier?

@lichtwerk not sure why you linked those commits, this has nothing to do with data-transfer modifier in particular, this is a general weirdness of modifier stack evaluation, afaict...

@lichtwerk not sure why you linked those commits, this has nothing to do with data-transfer modifier in particular, this is a general weirdness of modifier stack evaluation, afaict...
Philipp Oeser removed the
Interest
Modeling
label 2023-02-09 15:28:44 +01:00
Member

Not hitting the assert anymore (in neither of the two cases).

Will close (but of course feel free to comment gin if issues persist in fresh builds from https://builder.blender.org/download/daily/ -- we can always reopen in such case)

Not hitting the assert anymore (in neither of the two cases). Will close (but of course feel free to comment gin if issues persist in fresh builds from https://builder.blender.org/download/daily/ -- we can always reopen in such case)
Blender Bot added
Status
Archived
and removed
Status
Confirmed
labels 2024-03-05 13:38:00 +01:00
Philipp Oeser added
Status
Resolved
and removed
Status
Archived
labels 2024-03-05 13:47:26 +01:00
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
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
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#84664
No description provided.