Big News: Socket Selected for OpenAI's Cybersecurity Grant Program.Details
Socket
Book a DemoSign in
Socket

npmcad-resample

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

npmcad-resample

take a line (an array of vertices) and return a resampled at fixed steps along the line or an axis.

latest
Source
npmnpm
Version
1.0.1
Version published
Weekly downloads
42
75%
Maintainers
1
Weekly downloads
 
Created
Source

npmcad-resample

take a line (an array of vertices) and return a resampled at fixed steps along the line or an axis.

visualize

example.png

The grey curve is generated with cardinal-spline-js, the blue lines point to output of resample.steps and the green shows a resample.along line.

api

resample.steps (points, step)

resample a curve at even steps perpendicular to a vector.

step should be a csg Vector3D instance. points should be an array of Vector3D points, that define a curve you want to resample. The curve must not have more than one intersection on any plane perpendicular to a line through the first point in the direction of step. That is, if points is a mountain range and step points along the foot of the mountians (along the horizon) then the mountains can have steep cliffs but not fully vertical or caves or overhangs.

resample.along (points, size)

resample a curve at fixed size steps along it's own length.

License

MIT

FAQs

Package last updated on 03 Feb 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts