Hi,
I've always rendered my splines with Hair materials. After adding some custom modifiers, I simply cannot render anything anymore. Again, let's dive into old forum topics and start making tests to try and learn how things work.
At first I learned that the relationship between GetContour() and GetVirtualObjects() has always been a hot topic, not mentioned anywhere in the docs. I discovered that by sending nullptr to GetVirtualObjects(), it will eventually try GetContour(). Because I have OBJECT_GENERATOR and OBJECT_ISSPLINE defined, to generate either a poly or a spline, based on parameters chosen by the user.
About spline and deformers, here's what I discovered...
- SplineObject returned by GetContour(): OK (rendered by Hair material)
- SplineObject returned by GetVirtualObjects(): NOK (cannot be rendered by Hair material)
- SplineObject returned by GetContour() + C4D Deformer (Twist): NOK
- SplineObject returned by GetVirtualObjects() + C4D Deformer (Twist): NOK
- SplineObject returned by GetContour() + custom Deformer: NOK
- SplineObject returned by GetVirtualObjects() + custom Deformer: NOK
- Native spline object (Circle) + C4D Deformer (Twist): NOK
- Native spline object (Circle) + custom Deformer: NOK
- C4D Hair + C4D Deformer (Twist): Can render, but not deformed
- C4D Hair with the Deformers flag enabled + C4D Deformer (Twist): OK!!
So... looks like the Hair material does not render modified splines. Why? Is that a limitation or a bug?
But the C4D native hair has a Deformers flag that enables rendering of the deformed splines. How can it do it? I need that too!
EDIT: Some curious findings about C4D Hair object...
- When it has a deformer inside, instead of not rendering at all, it renders undeformed splines.
- There's an option in the Hair object (Generate, Type) that when set to Spline, will not render hair (deformed or not).
- There's actually nothing in the Hair Object cache looking at c4dsdk's Active Object Properties, unless we set it to Generate Splines. If it's not caching splines, then what?