Itoo Software Forum

Author Topic: Selector expression _ XSplineposition 0...1 for L1S  (Read 1119 times)

Dragan

  • Hero Member
  • *****
  • Posts: 1419
Selector expression _ XSplineposition 0...1 for L1S
« on: February 18, 2019, 12:11:31 PM »
Hi, is this work as expected?

iToo

  • Administrator
  • Hero Member
  • *****
  • Posts: 4388
    • iToo Software
Re: Selector expression _ XSplineposition 0...1 for L1S
« Reply #1 on: February 18, 2019, 12:33:17 PM »
Hi, it doesn't work because XSplinePosition returns the position where the Default segment is placed, not the end of the spline.
Probably the last segment is placed at 0.85 or so.

Also, for real values comparison, i suggest to not use == 0. It may fail because the rounding error.  Instead, < 0.001 is a better solution.
Carlos Quintero
iToo Software

Dragan

  • Hero Member
  • *****
  • Posts: 1419
Re: Selector expression _ XSplineposition 0...1 for L1S
« Reply #2 on: February 18, 2019, 12:57:37 PM »
Thank You Carlos,
I`ll do it with a compose operator. Since my start/end are fixed X-size and middle size should act as Default/Scale, I`ll calculate the middle X-size: XSplineLength-Start-End.

Dragan