@doodle3d/clipper-lib

中文文档
6.4.2-b发布于 2017/09/13BSLCommonJS零依赖近 30 天下载 3.3万

Boolean operations and offsetting library in Javascript

原始使用文档
文档目录5 节
  1. Description
  2. Features
  3. Categories
  4. Links
  5. License

ClipperLib

forked from Javascript Clipper

Description

The Javascript Clipper library performs clipping and offsetting for both lines and polygons. All four boolean clipping operations are supported - intersection, union, difference and exclusive-or. Polygons can be of any shape including self-intersecting polygons.

Javascript Clipper is a port of Angus Johnson's Clipper library: https://sourceforge.net/projects/polyclipping/

LIVE DEMO: http://jsclipper.sourceforge.net/6.2.1.0/main_demo.html

Information and examples: http://jsclipper.sourceforge.net/6.2.1.0/

Donate Javascript Clipper Project: https://sourceforge.net/p/jsclipper/wiki/Donations/

Use cases:

Javascript Clipper Web Site

Features

  • Line and polygon clipping - intersection, union, difference & xor
  • Line and polygon offsetting with 3 types of joining - miter, square and round
  • Polygons can be of any shape, including self-intersecting polygons
  • Minkowski Addition and Minkowski Difference functions included
  • The library is written in Javascript
  • Comprehensive documentation
  • Demos use inline SVG and Canvas libraries
  • The library is significantly faster than commercial alternatives
  • Uses Tom Wu's fast big integer library
  • UMD support

Categories

Algorithms, Graphics

License

Boost Software License (BSL1.0)

版本与发布记录

@doodle3d/clipper-lib 共发布 3 个版本,首次发布于 2017/07/20;过去 12 个月发布了 0 个版本。

版本发布日期距今
6.4.2-blatest2017/09/139 年前
6.4.22017/09/139 年前
6.2.22017/07/209 年前

关于 @doodle3d/clipper-lib 的常见问题

@doodle3d/clipper-lib 是什么?

Boolean operations and offsetting library in Javascript

如何安装 @doodle3d/clipper-lib?

在项目目录运行 npm install @doodle3d/clipper-lib,或使用 pnpm add / yarn add / bun add。

@doodle3d/clipper-lib 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/doodle3d__clipper-lib 是否存在。

@doodle3d/clipper-lib 支持 ESM 还是 CommonJS?

以 CommonJS 形式发布,可以直接 require();在 ES Module 项目中也可以用 import 引入(Node.js 会把 module.exports 作为默认导出)。

@doodle3d/clipper-lib 可以商用吗?

@doodle3d/clipper-lib 使用 BSL 许可。声明的许可为 BSL,请阅读许可原文确认使用条件。以上为概括,不构成法律意见,请以许可原文为准。

@doodle3d/clipper-lib 的下载量有多少?

根据 npm 官方下载统计,@doodle3d/clipper-lib 在 2026/10/13 – 2026/11/11 这 30 天内被下载 32,969 次,日均约 1,099 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@doodle3d/clipper-lib 还在维护吗?

最新版本 6.4.2-b 发布于 2017/09/13(9 年前);至今共发布 3 个版本,其中过去 12 个月发布了 0 个;首次发布于 2017/07/20。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。