Segfault (missing MTFace cdlayer from SubSurf DM). #45749

Closed
opened 2015-08-10 18:38:32 +02:00 by Zauber Paracelsus · 14 comments

System Information
System 1: 64bit Manjaro Linux 3.19.8.4
System 2: 64bit Windows 8.1

Blender Version
Broken: 2.76-devel 65c3207
Worked: 2.75-release d6b042b

Short description of error
This issue has pretty much stopped me in my tracks. If I use any kind of image texture in a hair or fur shader, then Blender will crash while trying to syncronize the object which has the fur or hair system.

The issue occurs on both Windows and Linux, with CPU and GPU rendering, and with both the Supported and Experimental feature sets. I have also tried doing a complete factory reset (delete config/blender, open file with "Load UI" disabled), and the issue still occurs.

Only Image Textures (both packed and not packed) appear to reproduce the issue. Other types of textures (such as noise) appear to work correctly.

Exact steps for others to reproduce the error
Attempt to render the following file: Test.blend

Crash Log: Test.crash.txt

**System Information** System 1: 64bit Manjaro Linux 3.19.8.4 System 2: 64bit Windows 8.1 **Blender Version** Broken: 2.76-devel 65c3207 Worked: 2.75-release d6b042b **Short description of error** This issue has pretty much stopped me in my tracks. If I use any kind of image texture in a hair or fur shader, then Blender will crash while trying to syncronize the object which has the fur or hair system. The issue occurs on both Windows and Linux, with CPU and GPU rendering, and with both the Supported and Experimental feature sets. I have also tried doing a complete factory reset (delete config/blender, open file with "Load UI" disabled), and the issue still occurs. Only Image Textures (both packed and not packed) appear to reproduce the issue. Other types of textures (such as noise) appear to work correctly. **Exact steps for others to reproduce the error** Attempt to render the following file: [Test.blend](https://archive.blender.org/developer/F222898/Test.blend) Crash Log: [Test.crash.txt](https://archive.blender.org/developer/F222901/Test.crash.txt)

Changed status to: 'Open'

Changed status to: 'Open'

Added subscriber: @ZauberParacelsus

Added subscriber: @ZauberParacelsus

After posting this, I ran a quick test. It appears that when the viewport is set to Preview rendering mode, the crash does not occur. It only seems to happen when I execute a final render.

After posting this, I ran a quick test. It appears that when the viewport is set to Preview rendering mode, the crash does not occur. It only seems to happen when I execute a final render.

This comment was removed by @ZauberParacelsus

*This comment was removed by @ZauberParacelsus*

Further info: the fur in the example file I gave was not actually using the material with the texture. Setting the correct material to the hair system still reproduces the issue, and further testing reveals that simply having a textured material present in the object's materials will reproduce the issue, whether or not that material is used.

Further info: the fur in the example file I gave was not actually using the material with the texture. Setting the correct material to the hair system still reproduces the issue, and further testing reveals that simply having a textured material present in the object's materials will reproduce the issue, whether or not that material is used.

Added subscriber: @sindra1961

Added subscriber: @sindra1961

I think that a cause is not the matter that you pointed out.
blender crashes for EXCEPTION_ACCESS_VIOLATION when I use the file which you attached.
However, it does not crash when I change some items.
A change point.
I set a order of Subdivision Surface Modifier last.
Probably I think that it is caused by Subdivision Surface Modifier.
{F223137}A_Test.blend
version 2.75 (sub 4), branch b'master', commit date b'2015-08-09' b'17:17', hash b'65c3207', b'Release'

I think that a cause is not the matter that you pointed out. blender crashes for EXCEPTION_ACCESS_VIOLATION when I use the file which you attached. However, it does not crash when I change some items. A change point. I set a order of Subdivision Surface Modifier last. Probably I think that it is caused by Subdivision Surface Modifier. {[F223137](https://archive.blender.org/developer/F223137/A_Test.blend.png)}[A_Test.blend](https://archive.blender.org/developer/F223139/A_Test.blend) version 2.75 (sub 4), branch b'master', commit date b'2015-08-09' b'17:17', hash b'65c3207', b'Release'

Well, that's extra strange, then.

And yeah, EXCEPTION_ACCESS_VIOLATION is the error that gets reported on Windows systems. On Linux systems, the error reported is segmentation fault.

Well, that's extra strange, then. And yeah, EXCEPTION_ACCESS_VIOLATION is the error that gets reported on Windows systems. On Linux systems, the error reported is segmentation fault.

For some reason, I had the subsurf modifier disabled for preview render. After turning it on, the crash now begins to occur when the viewport is set to Rendered mode.

In any case, I did some further testing and found yet another condition for triggering this crash! This condition once again deals with the textured material, and the condition is that the texture is using UV inputs as the texture coordinates. If you instead plug in things like generated or normal Texture Coordinates, the crash does not occur.

This leads me to believe that UV mapping is the underlying problem since the subdivision modifier can change an object's UV mapping. However, toggling the the "Subdivide UVs" option under the subsurf modifier doesn't stop the issue from happening. So, not sure if that's the cause either.

For some reason, I had the subsurf modifier disabled for preview render. After turning it on, the crash now begins to occur when the viewport is set to Rendered mode. In any case, I did some further testing and found yet another condition for triggering this crash! This condition once again deals with the textured material, and the condition is that the texture is using UV inputs as the texture coordinates. If you instead plug in things like generated or normal Texture Coordinates, the crash does not occur. This leads me to believe that UV mapping is the underlying problem since the subdivision modifier can change an object's UV mapping. However, toggling the the "Subdivide UVs" option under the subsurf modifier doesn't stop the issue from happening. So, not sure if that's the cause either.

Added subscribers: @Sergey, @ideasman42, @mont29

Added subscribers: @Sergey, @ideasman42, @mont29

OK, so do not really understand why, but probably caused by recent looptri changes or subsurf changes, rna_ParticleSystem_uv_on_emitter() gets a NULL mtface data, which is not supposed to happen. This probably means DM_DIRTY_TESS_CDLAYERS is improperly cleared somewhere (or lack being set), but this code is rather hairy, @ideasman42, @Sergey will let you investigate further here, you probably can find the culprit much quicker than me.

OK, so do not really understand why, but probably caused by recent looptri changes or subsurf changes, `rna_ParticleSystem_uv_on_emitter()` gets a NULL mtface data, which is not supposed to happen. This probably means `DM_DIRTY_TESS_CDLAYERS` is improperly cleared somewhere (or lack being set), but this code is rather hairy, @ideasman42, @Sergey will let you investigate further here, you probably can find the culprit much quicker than me.
Bastien Montagne changed title from Segfault when using any texture in strand shader to Segfault (missing MTFace cdlayer from SubSurf DM). 2015-08-12 14:21:26 +02:00

This issue seems to still be occuring as of build 19cc75d

This issue seems to still be occuring as of build 19cc75d

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Campbell Barton self-assigned this 2015-08-18 08:54:14 +02:00

this has been fixed - tested 92fe4e52fd which is working.

this has been fixed - tested 92fe4e52fd which is working.
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#45749
No description provided.