Skip to content
项目

关于

在 WebGL 中渲染风格化线框

创作与媒体

这些数字如何统计

实测星标增长

24小时
0
7天
0
15天
正在收集历史
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

webgl-wireframes

banner

This is the code for a November 2017 net magazine tutorial, Stylized Wireframe Rendering in WebGL. Check out the article (when it's released) for more details.

Stylized Wireframe Rendering in WebGL

The code here uses barycentric coordinates to create stylized wireframes in ThreeJS and WebGL. Some features of the code and its shaders include:

  • Alpha to Coverage for crisp alpha cutouts and depth testing with Multisample Anti-Aliasing
  • Thick and anti-aliased single-pass wireframe rendering
  • Basic support for animated line dashes
  • Inner edge removal to render quads instead of triangles
  • A few other effects, such as noise, tapered lines, dual strokes and backface coloring

Demo

Click here to see a live demo.

Usage

To build & run this project locally, first clone the repository, then use npm to install and run it:

npm install
npm start

Now open localhost:9966 to see it in your browser.

To build:

npm run build

Further Reading

The technique here is just one approach to wireframe rendering. You may find these other articles interesting:

License

MIT, see LICENSE.md for details.

探索相关项目

加载中…