ztdep
ztdep

Reputation: 381

CGAL:how to divide a segment into many little segments and output the points into a file

I have a line segment defined by two points P1 and P2. I now need to divide its into many parts. For example, 50 Parts. and output the points into a file from P1 to P2.

Upvotes: 1

Views: 101

Answers (1)

Andreas Fabri
Andreas Fabri

Reputation: 1235

Honestly, it makes no sense to use CGAL, if that is really all what you want.

It's just: P1 + i * (P2 - P1)/50, for i=0..50

Upvotes: 1

Related Questions