Skip to content

Mcgode/three-js-edge-split-modifier

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

three.js edge split modifier

This library has been deprecated. It was added to three.js examples, and will only be maintained there.

This package is a geometry modifier for three.js

This modifier takes a geometry as input, and outputs an indexed BufferGeometry with faces split at sharp edges.

Example

We take a flat shaded model: Flat shading

Using the classic smooth shading doesn't give us the type of result we expect (the sharp edges are smoothed, while they shouldn't): Smooth shading

Using the edge split modifier, we split the faces sharp edges to achieve a better smooth shading: Edge split + smooth shading

Browser dependencies

If you want to use this package in a browser, you will need to import three.js along its BufferGeometryUtils example JS file.

About

A geometry modifier for generating an indexed THREE.BufferGeometry, with faces split on sharp edges

Resources

License

Stars

Watchers

Forks

Packages