lottery
🎉🌟✨🎈年会抽奖程序,基于 Express + Three.js的 3D 球体抽奖程序,奖品🧧🎁,文字,图片,抽奖规则均可配置,😜抽奖人员信息Excel一键导入😍,抽奖结果Excel导出😎,给你的抽奖活动带来全新酷炫体验🚀🚀🚀
A Three.js mesh morph modifier
git clone https://github.com/drawcall/threejs-mesh-modifiers.gitdrawcall/threejs-mesh-modifiersA Three.js mesh morph modifier, including nearly ten modifiers, such as Bend, Bloat, Noise, Skew and Taper, etc. It is very lightweight and simple to use, using it can give you unexpected results.
Note: The latest version uses BufferGeometry to calculate, because three.js removes THREE.Geometry. If you are using a version earlier than three.js r125, please use three.modifiers v2.2.3
npm install three three.modifiers --save
These demos are real, you can click them! They contain the full code, too.
Download the build at dist/modifiers.min.js and include it as a script tag in a web page. You must include three.js as well.
<script src="./js/three.min.js"></script> <script src="./js/modifiers.min.js"></script>
Note you must also have three installed via npm.
import * as THREE from "three";
import {
ModifierStack,
Twist,
Noise,
Cloth,
UserDefined,
Taper,
Break,
Bloat,
Vector3,
ModConstant
} from "three.modifiers";
const modifier = new ModifierStack(mesh);
const bend = new Bend(1.5, 0.2, 0);
bend.constraint = ModConstant.LEFT;
const cloth = new Cloth(1, 0);
cloth.setForce(0.2, -0.2, -0.2);
const twist = new Twist(0);
twist.vector = new Vector3(0, 1, 0);
const taper = new Taper(1);
taper.setFalloff(0.1, 0.5);
modifier.addModifier(bend);
modifier.addModifier(cloth);
modifier.addModifier(twist);
modifier.addModifier(taper);
// animate func
function animate() {
requestAnimationFrame(animate);
renderer.render(scene, camera);
// modifier.apply
modifier && modifier.apply();
}
It is the typescript version of the ActionScript engine AS3Dmod. You can find the documentation here.
// DEVELOPMENT MODE npm install npm run demo // (vist http://localhost:8888/) // PRODUCTION MODE npm run build
This library is under the BSD License.
more like this
🎉🌟✨🎈年会抽奖程序,基于 Express + Three.js的 3D 球体抽奖程序,奖品🧧🎁,文字,图片,抽奖规则均可配置,😜抽奖人员信息Excel一键导入😍,抽奖结果Excel导出😎,给你的抽奖活动带来全新酷炫体验🚀🚀🚀
🎥🤟 8 minimalistic templates for tfjs mediapipe handpose and facemesh
A repository about starting from scratch for monorepo, fastify, Phaser, colyseus, and threejs.
search projects, people, and tags