How to use the FrontSide function from three
Find comprehensive JavaScript three.FrontSide code examples handpicked from public code repositorys.
GitHub: zeesaas/Three-MapGL
101 102 103 104 105 106 107 108 109 110
let material = new THREE.MeshPhongMaterial({ color: mesh.pathColor, transparent: true, depthTest: true, depthWrite: true, side: THREE.FrontSide }) mesh.traverse((child) => { if (child instanceof THREE.Mesh){ child.material = material;
4
7
1
+ 7 other calls in file
GitHub: alan-wu/ZincJS
669 670 671 672 673 674 675 676 677 678
} if (materials && materials.length > 0) { if (json.materials[0].singleSided) { materials[0].side = THREE.FrontSide; } else if (json.materials[0].flipSided){ materials[0].side = THREE.BackSide; } else { materials[0].side = THREE.DoubleSide;
10
3
3
+ 23 other calls in file
GitHub: alan-wu/ZincJS
47 48 49 50 51 52 53 54 55 56
if (options) { if (options.vs && options.fs) { let transparent = true; if (options.transparent) transparent = options.transparent; let side = THREE.FrontSide; if (options.side) side = options.side; material = new THREE.ShaderMaterial( { transparent,
10
3
3
+ 7 other calls in file
GitHub: alan-wu/ZincJS
79 80 81 82 83 84 85 86 87 88 89
ZincObject.prototype.checkAndCreateTransparentMesh = function(options) { if (this.isGeometry && this.morph.material && this.morph.material.transparent) { if (!this.secondaryMesh) { let secondaryMaterial = this.morph.material.clone(); secondaryMaterial.side = THREE.FrontSide; this.secondaryMesh = new THREE.Mesh(this.morph.geometry, secondaryMaterial); this.secondaryMesh.renderOrder = this.morph.renderOrder + 1; this.secondaryMesh.userData = this; this.secondaryMesh.name = this.groupName;
10
3
3
+ 29 other calls in file
GitHub: audunsh/evince
291 292 293 294 295 296 297 298 299
vertexShader: vertexShader, blending: THREE.AdditiveBlending }); material.depthWrite = false; material.side = THREE.FrontSide; //console.log(THREE);
3
7
0
1357 1358 1359 1360 1361 1362 1363 1364 1365 1366
emissive: 0x000000, metalness: 1, roughness: 1, transparent: false, depthTest: true, side: three.FrontSide }); } return cache['DefaultMaterial']; }
2
7
0
GitHub: 52black/scratch-vm
220 221 222 223 224 225 226 227 228 229 230 231
this.materialsInfo = {}; this.materials = {}; this.materialsArray = []; this.nameLookup = {}; this.side = ( this.options && this.options.side ) ? this.options.side : THREE.FrontSide; this.wrap = ( this.options && this.options.wrap ) ? this.options.wrap : THREE.RepeatWrapping; };
3
6
1
+ 18 other calls in file
176 177 178 179 180 181 182 183 184 185 186 187
this.materialsInfo = {}; this.materials = {}; this.materialsArray = []; this.nameLookup = {}; this.side = this.options && this.options.side ? this.options.side : THREE.FrontSide; this.wrap = this.options && this.options.wrap ? this.options.wrap : THREE.RepeatWrapping; }; MTLLoader.MaterialCreator.prototype = {
0
2
1
1048 1049 1050 1051 1052 1053 1054 1055 1056
throw new Error("Unknown technique.states.enable: " + enable); } } if (enableCullFace) { materialParams.side = functions.cullFace !== undefined ? WEBGL_SIDES[functions.cullFace] : THREE.FrontSide; } else { materialParams.side = THREE.DoubleSide; }
0
1
1
+ 19 other calls in file
GitHub: VeinKowal/veins
1296 1297 1298 1299 1300 1301 1302 1303 1304 1305
emissive: 0x000000, metalness: 1, roughness: 1, transparent: false, depthTest: true, side: _three.FrontSide }); } return cache['DefaultMaterial'];
0
1
0
280 281 282 283 284 285 286 287 288 289
// 球面形状 mat.map = dotTexture; mat.depthWrite = false; mat.transparent = true; mat.opacity = 0; mat.side = THREE.FrontSide; // mat.blending = THREE.AdditiveBlending mat.blending = THREE.NormalBlending; let n = i / 2; mat.t_ = n * Math.PI * 2;
0
0
0
three.Vector3 is the most popular function in three (22341 examples)