Itoo Software Forum

RailClone => RailClone Pro (*) => Topic started by: Anthony Lester on October 09, 2017, 12:19:43 PM

Title: Starting a XSplinePosition at the beginning of a segment (or equivalent)
Post by: Anthony Lester on October 09, 2017, 12:19:43 PM
I am trying to set up a RC where the handrail of a bridge gradually grows over the length of a segment then maintains a height for another segment, then drops back to the original height over the length of the next segment.

Using an series of condition statements for segment ID's I am able to split up the spline, then I have used the expression: return ((XSplinePosition)*50)+100; to take the geometry z scale from 100 to 150 over the course of a specific segment id (I would use an inverse of the XSpline position to take it back down again.  The problem is the XSplinePosition is generated using the entire length of the spline not the individual segment, is there away of making the XSplineposition 'counter' start at the beginning of the segment and not the spline as a whole?
Title: Re: Starting a XSplinePosition at the beginning of a segment (or equivalent)
Post by: Michal KarmazĂ­n on October 09, 2017, 12:26:56 PM
Hi Anthony,

The XSectionPosition attribute can be used for these purposes. Hope that helps.

Best regards,
Title: Re: Starting a XSplinePosition at the beginning of a segment (or equivalent)
Post by: Anthony Lester on October 09, 2017, 01:44:29 PM
so it does :)

thanks
Title: Re: Starting a XSplinePosition at the beginning of a segment (or equivalent)
Post by: Anthony Lester on October 09, 2017, 05:27:50 PM
So as a follow up to the original question, the XsectionPosition attribute works fine, but when I introduce a distribute evenly rule the Section length is restarted at every iteration of the evenly distributed geometry, is there a work around?