使用 Javascript 绘制 3D 元素
Drawing 3D elements with Javascript
我的应用程序 returns 两条线之间的相对位置,我想用 Javascript 绘制这条线。该线由一个方向向量、一个点定义,并且是 三维 。
有没有可用的图书馆可以做到这一点?我只找到 Victor.js 但对我的情况没有帮助
Three.js: "The aim of the project is to create a lightweight 3D library with a very low level of complexity — in other words, for dummies. The library provides canvas, svg, CSS3D and WebGL renderers."
Processing.js: "Processing.js is the sister project of the popular Processing visual programming language, designed for the web. Processing.js makes your data visualizations, digital art, interactive animations, educational graphs, video games, etc. work using web standards and without any plug-ins."
两者都非常成熟并且拥有活跃的社区。有很多资源可供学习,例如 three.js's Getting Started and Processing.js's Learning.
Here,你有一个非常简单的指南,可以在 2D 表面上绘制 3D 形状(使用 ProcessingJS)
这是可汗学院使用 ProcessingJS 制作 3D 形状的指南
您可能也想阅读 THIS。
这是原创文章,作者是 Peter Collingridge
在 html5 canvas
上绘制 3d 形状
我的应用程序 returns 两条线之间的相对位置,我想用 Javascript 绘制这条线。该线由一个方向向量、一个点定义,并且是 三维 。
有没有可用的图书馆可以做到这一点?我只找到 Victor.js 但对我的情况没有帮助
Three.js: "The aim of the project is to create a lightweight 3D library with a very low level of complexity — in other words, for dummies. The library provides canvas, svg, CSS3D and WebGL renderers."
Processing.js: "Processing.js is the sister project of the popular Processing visual programming language, designed for the web. Processing.js makes your data visualizations, digital art, interactive animations, educational graphs, video games, etc. work using web standards and without any plug-ins."
两者都非常成熟并且拥有活跃的社区。有很多资源可供学习,例如 three.js's Getting Started and Processing.js's Learning.
Here,你有一个非常简单的指南,可以在 2D 表面上绘制 3D 形状(使用 ProcessingJS)
这是可汗学院使用 ProcessingJS 制作 3D 形状的指南
您可能也想阅读 THIS。
这是原创文章,作者是 Peter Collingridge
在 html5 canvas