Drawings SDK Developer Guide > Working with .dwg Files > Working with Entities > Working with Specific Entitites > Working with Splines > Example of Working with Splines
Example of Working with Splines

Sample project of working with splines is located in the Drawing\Examples\DevGuide\OdSplinesEx subdirectory of the ODA installation folder (for example, C:\Program Files\Open Design Alliance).

The sample project demonstrates creating two identical splines, using NURBS data and using fit data, and setting and displaying its properties. The application creates a .dwg file, and then prints the following information about the created splines objects:

  • Type
  • Closed status
  • Periodic status
  • Plane
  • Area
  • Start parameter
  • End parameter
  • Start point
  • First derivative of the start point
  • Second derivative of the start point
  • End point
  • First derivative of the end point
  • Second derivative of the end point
  • Total length
  • Degree
  • Rational status
  • Control point tolerance
  • Knot tolerance
  • Control points
  • Knots
  • Fit points
  • Fit tolerance
  • Start tangent vector
  • End tangent vector

The application generates a .dwg file that contains two spline objects, which show two methods of creating the splines:

  • First spline is made using fit data.
  • Second spline is made using control points and knot vector.

See Also

Working with Splines

Overview of Splines

Specific Properties of Splines

Computed Properties of Splines

Working with NURBS Data

Working with Fit Data

Copyright © 2002 – 2021. Open Design Alliance. All rights reserved.