Hair interpolated children recalculation on every frame when attached onto an alembic imported mesh #56408

Closed
opened 2018-08-15 18:20:20 +02:00 by Yegor · 17 comments

System Information
Debian, Nvidia GTX 1080ti

Blender Version
Broken: 2.79b, latest b993e8a17a

Short description of error
While using hair particles with interpolated children on imported alembic we get children hairs recalculated on every frame on rendering, but not in the viewport.
What's more, we get children hairs recalculated even in the viewport if "use clump noise" enabled.
But i'm much more concerned about the first issue, because it is so crucial to me right now. I need a lot of fur and hair on alembics.

Exact steps for others to reproduce the error

  1. Open up the attached blend file
  2. The alembic is loaded on the second layer (hope it's picked up automatically, if not, just reload the alembic)
  3. Check that the alembic mesh has a hair particle system. If not, copy from the object on the first layer or create your own
  4. Render out the sequence

On the first layer we have a source object which alembic is written from.
Rendering object with hairs on the first layer gives correct results.

This is only related to interpolated children. No children or simple are being rendered just fine.

abc_hair_test.blend

abc_hair_test.abc

**System Information** Debian, Nvidia GTX 1080ti **Blender Version** Broken: 2.79b, latest b993e8a17a0 **Short description of error** While using hair particles with interpolated children on imported alembic we get children hairs recalculated on every frame on rendering, but not in the viewport. What's more, we get children hairs recalculated even in the viewport if "use clump noise" enabled. But i'm much more concerned about the first issue, because it is so crucial to me right now. I need a lot of fur and hair on alembics. **Exact steps for others to reproduce the error** 1. Open up the attached blend file 2. The alembic is loaded on the second layer (hope it's picked up automatically, if not, just reload the alembic) 3. Check that the alembic mesh has a hair particle system. If not, copy from the object on the first layer or create your own 4. Render out the sequence On the first layer we have a source object which alembic is written from. Rendering object with hairs on the first layer gives correct results. This is only related to interpolated children. No children or simple are being rendered just fine. [abc_hair_test.blend](https://archive.blender.org/developer/F4237045/abc_hair_test.blend) [abc_hair_test.abc](https://archive.blender.org/developer/F4237044/abc_hair_test.abc)
Author

Added subscriber: @YegorSmirnov

Added subscriber: @YegorSmirnov

#63534 was marked as duplicate of this issue

#63534 was marked as duplicate of this issue

Added subscribers: @dr.sybren, @mont29

Added subscribers: @dr.sybren, @mont29
Sybren A. Stüvel was assigned by Bastien Montagne 2018-08-16 10:45:31 +02:00

@dr.sybren care to check? Thanks.

@dr.sybren care to check? Thanks.
Author

Sorry for reminding, but would you check it? It is very important for fur rendering. Thanks.

Sorry for reminding, but would you check it? It is very important for fur rendering. Thanks.

Added subscriber: @evantryan

Added subscriber: @evantryan
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

Since @dr.sybren asked in #63534: here is the updated example file in 2.81

And here are the resulting output sequences (rendered in todays buildbot build):

@dr.sybren: mind checking again? (can you reproduce now?)

Since @dr.sybren asked in #63534: here is the updated example file in 2.81 - I have added a third collection (this time the object has a .pc2 Mesh Cache modifier on it -- which renders just fine) [meshcache_hair_test_interpolatedchildren_281.blend](https://archive.blender.org/developer/F7656004/meshcache_hair_test_interpolatedchildren_281.blend) [abc_hair_test.abc](https://archive.blender.org/developer/F7656008/abc_hair_test.abc) [pc2_hair_test.pc2](https://archive.blender.org/developer/F7656005/pc2_hair_test.pc2) And here are the resulting output sequences (rendered in todays buildbot build): - from .abc (wrong, jitters) [abc_hair_test_281.zip](https://archive.blender.org/developer/F7656010/abc_hair_test_281.zip) - from .pc2 (correct, stable) [pc2_hair_test_281.zip](https://archive.blender.org/developer/F7656016/pc2_hair_test_281.zip) @dr.sybren: mind checking again? (can you reproduce now?)
Author

Hairs on mdd cache work just fine as well. It's alembic only issue, I guess.

Hairs on mdd cache work just fine as well. It's alembic only issue, I guess.
Member

In #56408#749257, @YegorSmirnov wrote:
Hairs on mdd cache work just fine as well. It's alembic only issue, I guess.

Yes, can confirm that (also mentioned in #63534)

> In #56408#749257, @YegorSmirnov wrote: > Hairs on mdd cache work just fine as well. It's alembic only issue, I guess. Yes, can confirm that (also mentioned in #63534)
Added subscribers: @LiborBatek, @brecht, @CarlosPuebla, @SerjMaiorov

I discussed this with Brecht, and it's probably due to the way hair is distributed over the mesh. This is done using the tesselated faces (which are tris or quads), which in turn are based on the original mesh coordinates. Blender loads deforming meshes from Alembic into its own memory, so the current frame is always seen as "the original". This means a potential change in tesselation, which means a potential change in hair positions.

To determine the original mesh coordinates, we cannot simply look at the first frame. Alembic supports changing mesh topologies, so the mesh could simply not be there at the first frame. From the RenderMan for Maya release notes it looks like they support the export of "reference primvars", which would include reference coordinates for the mesh. I've posted a question on the Alembic discussion list about this to gain more information on how other software deals with this.

I discussed this with Brecht, and it's probably due to the way hair is distributed over the mesh. This is done using the tesselated faces (which are tris or quads), which in turn are based on the original mesh coordinates. Blender loads deforming meshes from Alembic into its own memory, so the current frame is always seen as "the original". This means a potential change in tesselation, which means a potential change in hair positions. To determine the original mesh coordinates, we cannot simply look at the first frame. Alembic supports changing mesh topologies, so the mesh could simply not be there at the first frame. From the [RenderMan for Maya release notes](https:*rmanwiki.pixar.com/display/RFM22/RenderMan+for+Maya+22.5) it looks like they support the export of "reference primvars", which would include reference coordinates for the mesh. I've posted [a question on the Alembic discussion list](https:*groups.google.com/forum/#!forum/alembic-discussion) about this to gain more information on how other software deals with this.

It's not just a change in tessellation, changing vertex position and face areas can lead to a different child particle distribution even if the tessellation is the same.

It's not just a change in tessellation, changing vertex position and face areas can lead to a different child particle distribution even if the tessellation is the same.
Author

In #56408#752139, @brecht wrote:
It's not just a change in tessellation, changing vertex position and face areas can lead to a different child particle distribution even if the tessellation is the same.

Yes, it occurs even with a constant tessellation. But how come that mdd cache and pc2 work fine with hairs?

> In #56408#752139, @brecht wrote: > It's not just a change in tessellation, changing vertex position and face areas can lead to a different child particle distribution even if the tessellation is the same. Yes, it occurs even with a constant tessellation. But how come that mdd cache and pc2 work fine with hairs?

With mdd cache there is an original mesh with fixed coordinates that are being deformed, with Alembic there are only the deformed coordinates.

With mdd cache there is an original mesh with fixed coordinates that are being deformed, with Alembic there are only the deformed coordinates.

This issue was referenced by ee8aad79c1

This issue was referenced by ee8aad79c1590cd0e98ba67961909ebfa8f6a803

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
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
7 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#56408
No description provided.