language
stringclasses
1 value
owner
stringlengths
2
15
repo
stringlengths
2
21
sha
stringlengths
45
45
message
stringlengths
7
36.3k
path
stringlengths
1
199
patch
stringlengths
15
102k
is_multipart
bool
2 classes
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-billboard-labels-w-sprites.html
@@ -57,13 +57,13 @@ const bodyRadiusBottom = .2; const bodyHeight = 2; const bodyRadialSegments = 6; - const bodyGeometry = new THREE.CylinderBufferGeometry( + const bodyGeometry = new THREE.CylinderGeometry( bodyRadiusTop, bodyRadiusBottom, bodyHeight, bodyRadialSegments); const headRadius = bodyRadiusTop * 0.8; const headLonSegments = 12; const headLatSegments = 5; - const headGeometry = new THREE.SphereBufferGeometry( + const headGeometry = new THREE.SphereGeometry( headRadius, headLonSegments, headLatSegments); function makeLabelCanvas(baseWidth, size, name) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-billboard-trees-no-billboards.html
@@ -58,13 +58,13 @@ const trunkRadius = .2; const trunkHeight = 1; const trunkRadialSegments = 12; - const trunkGeometry = new THREE.CylinderBufferGeometry( + const trunkGeometry = new THREE.CylinderGeometry( trunkRadius, trunkRadius, trunkHeight, trunkRadialSegments); const topRadius = trunkRadius * 4; const topHeight = trunkHeight * 2; const topSegments = 12; - const topGeometry = new THREE.ConeBufferGeometry( + const topGeometry = new THREE.ConeGeometry( topRadius, topHeight, topSegments); const trunkMaterial = new THREE.MeshPhongMaterial({color: 'brown'}); @@ -95,7 +95,7 @@ // add ground { const size = 400; - const geometry = new THREE.PlaneBufferGeometry(size, size); + const geometry = new THREE.PlaneGeometry(size, size); const material = new THREE.MeshPhongMaterial({color: 'gray'}); const mesh = new THREE.Mesh(geometry, material); mesh.rotation.x = Math.PI * -0.5;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-billboard-trees-static-billboards.html
@@ -57,13 +57,13 @@ const trunkRadius = .2; const trunkHeight = 1; const trunkRadialSegments = 12; - const trunkGeometry = new THREE.CylinderBufferGeometry( + const trunkGeometry = new THREE.CylinderGeometry( trunkRadius, trunkRadius, trunkHeight, trunkRadialSegments); const topRadius = trunkRadius * 4; const topHeight = trunkHeight * 2; const topSegments = 12; - const topGeometry = new THREE.ConeBufferGeometry( + const topGeometry = new THREE.ConeGeometry( topRadius, topHeight, topSegments); const trunkMaterial = new THREE.MeshPhongMaterial({color: 'brown'}); @@ -165,7 +165,7 @@ { const size = 400; - const geometry = new THREE.PlaneBufferGeometry(size, size); + const geometry = new THREE.PlaneGeometry(size, size); const material = new THREE.MeshPhongMaterial({color: 'gray'}); const mesh = new THREE.Mesh(geometry, material); mesh.rotation.x = Math.PI * -0.5;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-logarithmic-depth-buffer.html
@@ -89,7 +89,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -102,7 +102,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const numSpheres = 20; for (let i = 0; i < numSpheres; ++i) { const sphereMat = new THREE.MeshPhongMaterial();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-orthographic-2-scenes.html
@@ -117,7 +117,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -128,7 +128,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -138,7 +138,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-orthographic-canvas-top-left-origin.html
@@ -61,7 +61,7 @@ loader.load('resources/images/flower-6.jpg'), ]; const planeSize = 256; - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planes = textures.map((texture) => { const planePivot = new THREE.Object3D(); scene.add(planePivot);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-perspective-2-scenes.html
@@ -117,7 +117,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -128,7 +128,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -138,7 +138,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-perspective.html
@@ -87,7 +87,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -98,7 +98,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -108,7 +108,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-cameras-z-fighting.html
@@ -86,7 +86,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -99,7 +99,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const numSpheres = 20; for (let i = 0; i < numSpheres; ++i) { const sphereMat = new THREE.MeshPhongMaterial();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-canvas-textured-labels-one-canvas.html
@@ -57,16 +57,16 @@ const bodyRadiusBottom = .2; const bodyHeight = 2; const bodyRadialSegments = 6; - const bodyGeometry = new THREE.CylinderBufferGeometry( + const bodyGeometry = new THREE.CylinderGeometry( bodyRadiusTop, bodyRadiusBottom, bodyHeight, bodyRadialSegments); const headRadius = bodyRadiusTop * 0.8; const headLonSegments = 12; const headLatSegments = 5; - const headGeometry = new THREE.SphereBufferGeometry( + const headGeometry = new THREE.SphereGeometry( headRadius, headLonSegments, headLatSegments); - const labelGeometry = new THREE.PlaneBufferGeometry(1, 1); + const labelGeometry = new THREE.PlaneGeometry(1, 1); const ctx = document.createElement('canvas').getContext('2d'); @@ -103,7 +103,7 @@ const forceTextureInitialization = function() { const material = new THREE.MeshBasicMaterial(); - const geometry = new THREE.PlaneBufferGeometry(); + const geometry = new THREE.PlaneGeometry(); const scene = new THREE.Scene(); scene.add(new THREE.Mesh(geometry, material)); const camera = new THREE.Camera();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-canvas-textured-labels-scale-to-fit.html
@@ -57,16 +57,16 @@ const bodyRadiusBottom = .2; const bodyHeight = 2; const bodyRadialSegments = 6; - const bodyGeometry = new THREE.CylinderBufferGeometry( + const bodyGeometry = new THREE.CylinderGeometry( bodyRadiusTop, bodyRadiusBottom, bodyHeight, bodyRadialSegments); const headRadius = bodyRadiusTop * 0.8; const headLonSegments = 12; const headLatSegments = 5; - const headGeometry = new THREE.SphereBufferGeometry( + const headGeometry = new THREE.SphereGeometry( headRadius, headLonSegments, headLatSegments); - const labelGeometry = new THREE.PlaneBufferGeometry(1, 1); + const labelGeometry = new THREE.PlaneGeometry(1, 1); function makeLabelCanvas(baseWidth, size, name) { const borderSize = 2;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-canvas-textured-labels.html
@@ -57,16 +57,16 @@ const bodyRadiusBottom = .2; const bodyHeight = 2; const bodyRadialSegments = 6; - const bodyGeometry = new THREE.CylinderBufferGeometry( + const bodyGeometry = new THREE.CylinderGeometry( bodyRadiusTop, bodyRadiusBottom, bodyHeight, bodyRadialSegments); const headRadius = bodyRadiusTop * 0.8; const headLonSegments = 12; const headLatSegments = 5; - const headGeometry = new THREE.SphereBufferGeometry( + const headGeometry = new THREE.SphereGeometry( headRadius, headLonSegments, headLatSegments); - const labelGeometry = new THREE.PlaneBufferGeometry(1, 1); + const labelGeometry = new THREE.PlaneGeometry(1, 1); function makeLabelCanvas(size, name) { const borderSize = 2;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-debug-js-clearing-logger.html
@@ -64,7 +64,7 @@ const scene = new THREE.Scene(); scene.background = new THREE.Color('cyan'); - const geometry = new THREE.SphereBufferGeometry(); + const geometry = new THREE.SphereGeometry(); const material = new THREE.MeshBasicMaterial({color: 'red'}); const things = [];
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-debug-js-html-elements.html
@@ -51,7 +51,7 @@ const scene = new THREE.Scene(); scene.background = new THREE.Color('red'); - const geometry = new THREE.SphereBufferGeometry(); + const geometry = new THREE.SphereGeometry(); const material = new THREE.MeshBasicMaterial({color: 'yellow'}); const mesh = new THREE.Mesh(geometry, material);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-debug-js-params.html
@@ -113,7 +113,7 @@ const scene = new THREE.Scene(); scene.background = new THREE.Color('cyan'); - const geometry = new THREE.SphereBufferGeometry(); + const geometry = new THREE.SphereGeometry(); const material = new THREE.MeshBasicMaterial({color: 'red'}); const things = [];
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-debugging-mcve.html
@@ -78,7 +78,7 @@ } } - const geometry = new THREE.BoxBufferGeometry(100, 100, 300); + const geometry = new THREE.BoxGeometry(100, 100, 300); const material = new THREE.MeshBasicMaterial({color: 'cyan'}); const cars = []; for (let i = 0; i < 10; ++i) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-indexed-textures-picking-and-highlighting.html
@@ -123,7 +123,7 @@ { const loader = new THREE.TextureLoader(); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const indexTexture = loader.load('resources/data/world/country-index-texture.png', render); indexTexture.minFilter = THREE.NearestFilter;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-indexed-textures-picking-debounced.html
@@ -124,7 +124,7 @@ { const loader = new THREE.TextureLoader(); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const indexTexture = loader.load('resources/data/world/country-index-texture.png', render); indexTexture.minFilter = THREE.NearestFilter;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-indexed-textures-picking.html
@@ -88,7 +88,7 @@ { const loader = new THREE.TextureLoader(); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const indexTexture = loader.load('resources/data/world/country-index-texture.png', render); indexTexture.minFilter = THREE.NearestFilter;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-indexed-textures-random-colors.html
@@ -103,7 +103,7 @@ { const loader = new THREE.TextureLoader(); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const indexTexture = loader.load('resources/data/world/country-index-texture.png', render); indexTexture.minFilter = THREE.NearestFilter;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-ambient.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-directional-w-helper.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-directional.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-hemisphere.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-point-physically-correct.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -66,7 +66,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -76,7 +76,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-point.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-rectarea.html
@@ -57,7 +57,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshStandardMaterial({ map: texture, side: THREE.DoubleSide, @@ -68,7 +68,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshStandardMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -78,7 +78,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshStandardMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lights-spot-w-helper.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -65,7 +65,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.position.set(cubeSize + 1, cubeSize / 2, 0); @@ -75,7 +75,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.position.set(-sphereRadius - 1, sphereRadius + 2, 0);
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-animated-cars.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-car-path-fixed.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-car-path.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-dump-scenegraph-extra.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-dump-scenegraph.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-rotate-cars-fixed.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-rotate-cars.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf-shadows.html
@@ -56,7 +56,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-gltf.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-auto-camera-xz.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 200; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-auto-camera.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-materials-fixed.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-materials-windmill2.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 200; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-materials.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-no-materials.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-load-obj-wat.html
@@ -54,7 +54,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-animated.html
@@ -103,7 +103,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -177,7 +177,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-merged-vertexcolors.html
@@ -49,7 +49,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -123,7 +123,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-merged.html
@@ -49,7 +49,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -121,7 +121,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-morphtargets-w-colors.html
@@ -103,7 +103,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -186,7 +186,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-morphtargets.html
@@ -103,7 +103,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -186,7 +186,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-multiple-data-sets.html
@@ -70,7 +70,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -144,7 +144,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // adjust the helpers to point to the latitude and longitude lonHelper.rotation.y = THREE.MathUtils.degToRad(lonNdx + file.xllcorner) + lonFudge;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-lots-of-objects-slow.html
@@ -48,7 +48,7 @@ { const loader = new THREE.TextureLoader(); const texture = loader.load('resources/images/world.jpg', render); - const geometry = new THREE.SphereBufferGeometry(1, 64, 32); + const geometry = new THREE.SphereGeometry(1, 64, 32); const material = new THREE.MeshBasicMaterial({map: texture}); scene.add(new THREE.Mesh(geometry, material)); } @@ -95,7 +95,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); // make it so it scales away from the positive Z axis geometry.applyMatrix4(new THREE.Matrix4().makeTranslation(0, 0, 0.5));
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-controls.html
@@ -91,7 +91,7 @@ const sceneInitFunctionsByName = { 'box': (elem) => { const {scene, camera, controls} = makeScene(elem); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); scene.add(mesh); @@ -109,7 +109,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-copy-canvas.html
@@ -89,7 +89,7 @@ const sceneInitFunctionsByName = { 'box': (elem) => { const {scene, camera, controls} = makeScene(elem); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); scene.add(mesh); @@ -107,7 +107,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-generic.html
@@ -85,7 +85,7 @@ { const elem = document.querySelector('#box'); const {scene, camera} = makeScene(); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); scene.add(mesh); @@ -103,7 +103,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-selector.html
@@ -85,7 +85,7 @@ const sceneInitFunctionsByName = { 'box': () => { const {scene, camera} = makeScene(); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); scene.add(mesh); @@ -101,7 +101,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-v1.html
@@ -79,7 +79,7 @@ function setupScene1() { const sceneInfo = makeScene(document.querySelector('#box')); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); sceneInfo.scene.add(mesh); @@ -92,7 +92,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-v2.html
@@ -81,7 +81,7 @@ function setupScene1() { const sceneInfo = makeScene(document.querySelector('#box')); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); sceneInfo.scene.add(mesh); @@ -94,7 +94,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-multiple-scenes-v3.html
@@ -81,7 +81,7 @@ function setupScene1() { const sceneInfo = makeScene(document.querySelector('#box')); - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'red'}); const mesh = new THREE.Mesh(geometry, material); sceneInfo.scene.add(mesh); @@ -94,7 +94,7 @@ const radius = .8; const widthSegments = 4; const heightSegments = 2; - const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); + const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.MeshPhongMaterial({ color: 'blue', flatShading: true,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-picking-raycaster-complex-geo.html
@@ -51,7 +51,7 @@ camera.add(light); } - const geometry = new THREE.SphereBufferGeometry(.6, 100, 100); + const geometry = new THREE.SphereGeometry(.6, 100, 100); function rand(min, max) { if (max === undefined) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-postprocessing-3dlut-identity.html
@@ -101,7 +101,7 @@ { const loader = new THREE.TextureLoader(); bgTexture = loader.load('resources/images/beach.jpg'); - const planeGeo = new THREE.PlaneBufferGeometry(2, 2); + const planeGeo = new THREE.PlaneGeometry(2, 2); const planeMat = new THREE.MeshBasicMaterial({ map: bgTexture, depthTest: false,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-postprocessing-3dlut-prep.html
@@ -51,7 +51,7 @@ { const loader = new THREE.TextureLoader(); bgTexture = loader.load('resources/images/beach.jpg'); - const planeGeo = new THREE.PlaneBufferGeometry(2, 2); + const planeGeo = new THREE.PlaneGeometry(2, 2); const planeMat = new THREE.MeshBasicMaterial({ map: bgTexture, depthTest: false,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-postprocessing-3dlut-w-loader.html
@@ -189,7 +189,7 @@ { const loader = new THREE.TextureLoader(); bgTexture = loader.load('resources/images/beach.jpg'); - const planeGeo = new THREE.PlaneBufferGeometry(2, 2); + const planeGeo = new THREE.PlaneGeometry(2, 2); const planeMat = new THREE.MeshBasicMaterial({ map: bgTexture, depthTest: false,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-postprocessing-3dlut.html
@@ -172,7 +172,7 @@ { const loader = new THREE.TextureLoader(); bgTexture = loader.load('resources/images/beach.jpg'); - const planeGeo = new THREE.PlaneBufferGeometry(2, 2); + const planeGeo = new THREE.PlaneGeometry(2, 2); const planeMat = new THREE.MeshBasicMaterial({ map: bgTexture, depthTest: false,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-postprocessing-adobe-lut-to-png-converter.html
@@ -91,7 +91,7 @@ <h1>Adobe LUT to PNG converter</h1> idTexture.minFilter = THREE.NearestFilter; { - const planeGeo = new THREE.PlaneBufferGeometry(2, 2); + const planeGeo = new THREE.PlaneGeometry(2, 2); const planeMat = new THREE.MeshBasicMaterial({ map: idTexture, depthTest: false,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-primitives-text.html
@@ -92,7 +92,7 @@ async function doit() { const font = await loadFont('resources/threejs/fonts/helvetiker_regular.typeface.json'); /* threejsfundamentals: url */ - const geometry = new THREE.TextBufferGeometry('three.js', { + const geometry = new THREE.TextGeometry('three.js', { font: font, size: 3.0, height: .2,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-primitives.html
@@ -91,29 +91,29 @@ const width = 8; const height = 8; const depth = 8; - addSolidGeometry(-2, 2, new THREE.BoxBufferGeometry(width, height, depth)); + addSolidGeometry(-2, 2, new THREE.BoxGeometry(width, height, depth)); } { const radius = 7; const segments = 24; - addSolidGeometry(-1, 2, new THREE.CircleBufferGeometry(radius, segments)); + addSolidGeometry(-1, 2, new THREE.CircleGeometry(radius, segments)); } { const radius = 6; const height = 8; const segments = 16; - addSolidGeometry(0, 2, new THREE.ConeBufferGeometry(radius, height, segments)); + addSolidGeometry(0, 2, new THREE.ConeGeometry(radius, height, segments)); } { const radiusTop = 4; const radiusBottom = 4; const height = 8; const radialSegments = 12; - addSolidGeometry(1, 2, new THREE.CylinderBufferGeometry(radiusTop, radiusBottom, height, radialSegments)); + addSolidGeometry(1, 2, new THREE.CylinderGeometry(radiusTop, radiusBottom, height, radialSegments)); } { const radius = 7; - addSolidGeometry(2, 2, new THREE.DodecahedronBufferGeometry(radius)); + addSolidGeometry(2, 2, new THREE.DodecahedronGeometry(radius)); } { const shape = new THREE.Shape(); @@ -136,22 +136,22 @@ bevelSegments: 2, }; - addSolidGeometry(-2, 1, new THREE.ExtrudeBufferGeometry(shape, extrudeSettings)); + addSolidGeometry(-2, 1, new THREE.ExtrudeGeometry(shape, extrudeSettings)); } { const radius = 7; - addSolidGeometry(-1, 1, new THREE.IcosahedronBufferGeometry(radius)); + addSolidGeometry(-1, 1, new THREE.IcosahedronGeometry(radius)); } { const points = []; for (let i = 0; i < 10; ++i) { points.push(new THREE.Vector2(Math.sin(i * 0.2) * 3 + 3, (i - 5) * .8)); } - addSolidGeometry(0, 1, new THREE.LatheBufferGeometry(points)); + addSolidGeometry(0, 1, new THREE.LatheGeometry(points)); } { const radius = 7; - addSolidGeometry(1, 1, new THREE.OctahedronBufferGeometry(radius)); + addSolidGeometry(1, 1, new THREE.OctahedronGeometry(radius)); } { /* @@ -203,14 +203,14 @@ const slices = 25; const stacks = 25; - addSolidGeometry(2, 1, new THREE.ParametricBufferGeometry(klein, slices, stacks)); + addSolidGeometry(2, 1, new THREE.ParametricGeometry(klein, slices, stacks)); } { const width = 9; const height = 9; const widthSegments = 2; const heightSegments = 2; - addSolidGeometry(-2, 0, new THREE.PlaneBufferGeometry(width, height, widthSegments, heightSegments)); + addSolidGeometry(-2, 0, new THREE.PlaneGeometry(width, height, widthSegments, heightSegments)); } { const verticesOfCube = [ @@ -227,13 +227,13 @@ ]; const radius = 7; const detail = 2; - addSolidGeometry(-1, 0, new THREE.PolyhedronBufferGeometry(verticesOfCube, indicesOfFaces, radius, detail)); + addSolidGeometry(-1, 0, new THREE.PolyhedronGeometry(verticesOfCube, indicesOfFaces, radius, detail)); } { const innerRadius = 2; const outerRadius = 7; const segments = 18; - addSolidGeometry(0, 0, new THREE.RingBufferGeometry(innerRadius, outerRadius, segments)); + addSolidGeometry(0, 0, new THREE.RingGeometry(innerRadius, outerRadius, segments)); } { const shape = new THREE.Shape(); @@ -246,17 +246,17 @@ shape.bezierCurveTo(x + 6, y + 7.7, x + 8, y + 4.5, x + 8, y + 3.5); shape.bezierCurveTo(x + 8, y + 3.5, x + 8, y, x + 5, y); shape.bezierCurveTo(x + 3.5, y, x + 2.5, y + 2.5, x + 2.5, y + 2.5); - addSolidGeometry(1, 0, new THREE.ShapeBufferGeometry(shape)); + addSolidGeometry(1, 0, new THREE.ShapeGeometry(shape)); } { const radius = 7; const widthSegments = 12; const heightSegments = 8; - addSolidGeometry(2, 0, new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments)); + addSolidGeometry(2, 0, new THREE.SphereGeometry(radius, widthSegments, heightSegments)); } { const radius = 7; - addSolidGeometry(-2, -1, new THREE.TetrahedronBufferGeometry(radius)); + addSolidGeometry(-2, -1, new THREE.TetrahedronGeometry(radius)); } { const loader = new THREE.FontLoader(); @@ -269,7 +269,7 @@ async function doit() { const font = await loadFont('resources/threejs/fonts/helvetiker_regular.typeface.json'); /* threejsfundamentals: url */ - const geometry = new THREE.TextBufferGeometry('three.js', { + const geometry = new THREE.TextGeometry('three.js', { font: font, size: 3.0, height: .2, @@ -295,7 +295,7 @@ const tubeRadius = 2; const radialSegments = 8; const tubularSegments = 24; - addSolidGeometry(0, -1, new THREE.TorusBufferGeometry(radius, tubeRadius, radialSegments, tubularSegments)); + addSolidGeometry(0, -1, new THREE.TorusGeometry(radius, tubeRadius, radialSegments, tubularSegments)); } { const radius = 3.5; @@ -304,7 +304,7 @@ const tubularSegments = 64; const p = 2; const q = 3; - addSolidGeometry(1, -1, new THREE.TorusKnotBufferGeometry(radius, tube, tubularSegments, radialSegments, p, q)); + addSolidGeometry(1, -1, new THREE.TorusKnotGeometry(radius, tube, tubularSegments, radialSegments, p, q)); } { class CustomSinCurve extends THREE.Curve { @@ -325,22 +325,22 @@ const radius = 1; const radialSegments = 8; const closed = false; - addSolidGeometry(2, -1, new THREE.TubeBufferGeometry(path, tubularSegments, radius, radialSegments, closed)); + addSolidGeometry(2, -1, new THREE.TubeGeometry(path, tubularSegments, radius, radialSegments, closed)); } { const width = 8; const height = 8; const depth = 8; const thresholdAngle = 15; addLineGeometry(-1, -2, new THREE.EdgesGeometry( - new THREE.BoxBufferGeometry(width, height, depth), + new THREE.BoxGeometry(width, height, depth), thresholdAngle)); } { const width = 8; const height = 8; const depth = 8; - addLineGeometry(1, -2, new THREE.WireframeGeometry(new THREE.BoxBufferGeometry(width, height, depth))); + addLineGeometry(1, -2, new THREE.WireframeGeometry(new THREE.BoxGeometry(width, height, depth))); } function resizeRendererToDisplaySize(renderer) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-car.html
@@ -54,15 +54,15 @@ const carHeight = 1; const carLength = 8; - const bodyGeometry = new THREE.BoxBufferGeometry(carWidth, carHeight, carLength); + const bodyGeometry = new THREE.BoxGeometry(carWidth, carHeight, carLength); const bodyMaterial = new THREE.MeshPhongMaterial({color: 0x6688AA}); const bodyMesh = new THREE.Mesh(bodyGeometry, bodyMaterial); scene.add(bodyMesh); const wheelRadius = 1; const wheelThickness = .5; const wheelSegments = 6; - const wheelGeometry = new THREE.CylinderBufferGeometry( + const wheelGeometry = new THREE.CylinderGeometry( wheelRadius, // top radius wheelRadius, // bottom radius wheelThickness, // height of cylinder
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth-moon-axes-grids.html
@@ -78,7 +78,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const solarSystem = new THREE.Object3D();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth-moon-axes.html
@@ -50,7 +50,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const solarSystem = new THREE.Object3D();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth-moon.html
@@ -50,7 +50,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const solarSystem = new THREE.Object3D();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth-orbit-fixed.html
@@ -50,7 +50,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const solarSystem = new THREE.Object3D();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth-orbit.html
@@ -50,7 +50,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const sunMaterial = new THREE.MeshPhongMaterial({emissive: 0xFFFF00});
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun-earth.html
@@ -50,7 +50,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const sunMaterial = new THREE.MeshPhongMaterial({emissive: 0xFFFF00});
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-sun.html
@@ -51,7 +51,7 @@ const radius = 1; const widthSegments = 6; const heightSegments = 6; - const sphereGeometry = new THREE.SphereBufferGeometry( + const sphereGeometry = new THREE.SphereGeometry( radius, widthSegments, heightSegments); const sunMaterial = new THREE.MeshPhongMaterial({emissive: 0xFFFF00});
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-scenegraph-tank.html
@@ -75,7 +75,7 @@ scene.add(light); } - const groundGeometry = new THREE.PlaneBufferGeometry(50, 50); + const groundGeometry = new THREE.PlaneGeometry(50, 50); const groundMaterial = new THREE.MeshPhongMaterial({color: 0xCC8866}); const groundMesh = new THREE.Mesh(groundGeometry, groundMaterial); groundMesh.rotation.x = Math.PI * -.5; @@ -89,7 +89,7 @@ const tank = new THREE.Object3D(); scene.add(tank); - const bodyGeometry = new THREE.BoxBufferGeometry(carWidth, carHeight, carLength); + const bodyGeometry = new THREE.BoxGeometry(carWidth, carHeight, carLength); const bodyMaterial = new THREE.MeshPhongMaterial({color: 0x6688AA}); const bodyMesh = new THREE.Mesh(bodyGeometry, bodyMaterial); bodyMesh.position.y = 1.4; @@ -106,7 +106,7 @@ const wheelRadius = 1; const wheelThickness = .5; const wheelSegments = 6; - const wheelGeometry = new THREE.CylinderBufferGeometry( + const wheelGeometry = new THREE.CylinderGeometry( wheelRadius, // top radius wheelRadius, // bottom radius wheelThickness, // height of cylinder @@ -136,7 +136,7 @@ const domePhiEnd = Math.PI * 2; const domeThetaStart = 0; const domeThetaEnd = Math.PI * .5; - const domeGeometry = new THREE.SphereBufferGeometry( + const domeGeometry = new THREE.SphereGeometry( domeRadius, domeWidthSubdivisions, domeHeightSubdivisions, domePhiStart, domePhiEnd, domeThetaStart, domeThetaEnd); const domeMesh = new THREE.Mesh(domeGeometry, bodyMaterial); @@ -147,7 +147,7 @@ const turretWidth = .1; const turretHeight = .1; const turretLength = carLength * .75 * .2; - const turretGeometry = new THREE.BoxBufferGeometry( + const turretGeometry = new THREE.BoxGeometry( turretWidth, turretHeight, turretLength); const turretMesh = new THREE.Mesh(turretGeometry, bodyMaterial); const turretPivot = new THREE.Object3D(); @@ -162,7 +162,7 @@ turretCamera.position.y = .75 * .2; turretMesh.add(turretCamera); - const targetGeometry = new THREE.SphereBufferGeometry(.5, 6, 3); + const targetGeometry = new THREE.SphereGeometry(.5, 6, 3); const targetMaterial = new THREE.MeshPhongMaterial({color: 0x00FF00, flatShading: true}); const targetMesh = new THREE.Mesh(targetGeometry, targetMaterial); const targetOrbit = new THREE.Object3D();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadertoy-basic-x40.html
@@ -37,7 +37,7 @@ 1, // far ); const scene = new THREE.Scene(); - const plane = new THREE.PlaneBufferGeometry(2, 2); + const plane = new THREE.PlaneGeometry(2, 2); const fragmentShader = ` #include <common>
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadertoy-basic.html
@@ -37,7 +37,7 @@ 1, // far ); const scene = new THREE.Scene(); - const plane = new THREE.PlaneBufferGeometry(2, 2); + const plane = new THREE.PlaneGeometry(2, 2); const fragmentShader = ` #include <common>
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadertoy-bleepy-blocks.html
@@ -37,7 +37,7 @@ 1, // far ); const scene = new THREE.Scene(); - const plane = new THREE.PlaneBufferGeometry(2, 2); + const plane = new THREE.PlaneGeometry(2, 2); const fragmentShader = ` #include <common>
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadertoy-prep.html
@@ -37,7 +37,7 @@ 1, // far ); const scene = new THREE.Scene(); - const plane = new THREE.PlaneBufferGeometry(2, 2); + const plane = new THREE.PlaneGeometry(2, 2); const material = new THREE.MeshBasicMaterial({ color: 'red', });
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-directional-light-shadow-acne.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize, planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize, planeSize, planeSize); const positionAttribute = planeGeo.attributes.position; for (let i = 0; i < positionAttribute.count; ++i) { positionAttribute.setZ(i, Math.random() * .2); @@ -81,7 +81,7 @@ const phiLength = Math.PI * 2; const thetaStart = Math.PI * .5; const thetaLength = Math.PI * .5; - const sphereGeo = new THREE.SphereBufferGeometry( + const sphereGeo = new THREE.SphereGeometry( sphereRadius, sphereWidthDivisions, sphereHeightDivisions, @@ -105,7 +105,7 @@ const sphereRadius = 4; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry( + const sphereGeo = new THREE.SphereGeometry( sphereRadius, sphereWidthDivisions, sphereHeightDivisions,
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-directional-light-with-camera-gui.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -67,7 +67,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -79,7 +79,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-directional-light-with-camera-helper.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -67,7 +67,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -79,7 +79,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-directional-light.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -67,7 +67,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -79,7 +79,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-fake.html
@@ -51,7 +51,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshBasicMaterial({ map: texture, side: THREE.DoubleSide, @@ -68,10 +68,10 @@ const sphereRadius = 1; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const planeSize = 1; - const shadowGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const shadowGeo = new THREE.PlaneGeometry(planeSize, planeSize); const numSpheres = 15; for (let i = 0; i < numSpheres; ++i) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-point-light.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -67,7 +67,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -77,7 +77,7 @@ } { const cubeSize = 30; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({ color: '#CCC', side: THREE.BackSide, @@ -91,7 +91,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-spot-light-with-camera-gui.html
@@ -55,7 +55,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -67,7 +67,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -79,7 +79,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-shadows-spot-light-with-shadow-radius.html
@@ -56,7 +56,7 @@ const repeats = planeSize / 2; texture.repeat.set(repeats, repeats); - const planeGeo = new THREE.PlaneBufferGeometry(planeSize, planeSize); + const planeGeo = new THREE.PlaneGeometry(planeSize, planeSize); const planeMat = new THREE.MeshPhongMaterial({ map: texture, side: THREE.DoubleSide, @@ -68,7 +68,7 @@ } { const cubeSize = 4; - const cubeGeo = new THREE.BoxBufferGeometry(cubeSize, cubeSize, cubeSize); + const cubeGeo = new THREE.BoxGeometry(cubeSize, cubeSize, cubeSize); const cubeMat = new THREE.MeshPhongMaterial({color: '#8AC'}); const mesh = new THREE.Mesh(cubeGeo, cubeMat); mesh.castShadow = true; @@ -80,7 +80,7 @@ const sphereRadius = 3; const sphereWidthDivisions = 32; const sphereHeightDivisions = 16; - const sphereGeo = new THREE.SphereBufferGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); + const sphereGeo = new THREE.SphereGeometry(sphereRadius, sphereWidthDivisions, sphereHeightDivisions); const sphereMat = new THREE.MeshPhongMaterial({color: '#CA8'}); const mesh = new THREE.Mesh(sphereGeo, sphereMat); mesh.castShadow = true;
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-textured-cube-6-textures.html
@@ -39,7 +39,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); const cubes = []; // just an array we can use to rotate the cubes const loader = new THREE.TextureLoader();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-textured-cube-wait-for-all-textures.html
@@ -64,7 +64,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); const cubes = []; // just an array we can use to rotate the cubes const loadManager = new THREE.LoadingManager();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-transparency-intersecting-planes-alphatest.html
@@ -55,7 +55,7 @@ const planeWidth = 1; const planeHeight = 1; - const geometry = new THREE.PlaneBufferGeometry(planeWidth, planeHeight); + const geometry = new THREE.PlaneGeometry(planeWidth, planeHeight); const loader = new THREE.TextureLoader();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-transparency-intersecting-planes-fixed.html
@@ -54,7 +54,7 @@ const planeWidth = 0.5; const planeHeight = 1; - const geometry = new THREE.PlaneBufferGeometry(planeWidth, planeHeight); + const geometry = new THREE.PlaneGeometry(planeWidth, planeHeight); const loader = new THREE.TextureLoader();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-transparency-intersecting-planes.html
@@ -54,7 +54,7 @@ const planeWidth = 1; const planeHeight = 1; - const geometry = new THREE.PlaneBufferGeometry(planeWidth, planeHeight); + const geometry = new THREE.PlaneGeometry(planeWidth, planeHeight); const loader = new THREE.TextureLoader();
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-voxel-geometry-merged.html
@@ -60,7 +60,7 @@ const height = (Math.sin(x / cellSize * Math.PI * 4) + Math.sin(z / cellSize * Math.PI * 6)) * 20 + 60; //if (y < height) { if (height > y && height < y + 1) { - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); geometry.applyMatrix4((new THREE.Matrix4()).makeTranslation(x, y, z)); geometries.push(geometry); }
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-voxel-geometry-separate-cubes.html
@@ -67,7 +67,7 @@ } } - const geometry = new THREE.BoxBufferGeometry(1, 1, 1); + const geometry = new THREE.BoxGeometry(1, 1, 1); const material = new THREE.MeshPhongMaterial({color: 'green'}); for (let y = 0; y < cellSize; ++y) {
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-webvr-look-to-select-selector.html
@@ -60,14 +60,14 @@ //const innerRadius = 0.4; //const outerRadius = 0.5; //const segments = 64; - //const cursorGeometry = new THREE.RingBufferGeometry( + //const cursorGeometry = new THREE.RingGeometry( // innerRadius, outerRadius, segments); const ringRadius = 0.4; const tubeRadius = 0.1; const tubeSegments = 4; const ringSegments = 64; - const cursorGeometry = new THREE.TorusBufferGeometry( + const cursorGeometry = new THREE.TorusGeometry( ringRadius, tubeRadius, tubeSegments, ringSegments); const cursorColors = new Uint8Array([
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-webvr-look-to-select-w-cursor.html
@@ -70,10 +70,10 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const boxGeometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const boxGeometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); const sphereRadius = 0.5; - const sphereGeometry = new THREE.SphereBufferGeometry(sphereRadius); + const sphereGeometry = new THREE.SphereGeometry(sphereRadius); function makeInstance(geometry, color, x) { const material = new THREE.MeshPhongMaterial({color}); @@ -121,7 +121,7 @@ const tubeRadius = 0.1; const tubeSegments = 4; const ringSegments = 64; - const cursorGeometry = new THREE.TorusBufferGeometry( + const cursorGeometry = new THREE.TorusGeometry( ringRadius, tubeRadius, tubeSegments, ringSegments); const cursorMaterial = new THREE.MeshBasicMaterial({
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-webvr-look-to-select.html
@@ -62,7 +62,7 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const geometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const geometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); function makeInstance(geometry, color, x) { const material = new THREE.MeshPhongMaterial({color});
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-webvr-point-to-select-w-move.html
@@ -62,10 +62,10 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const boxGeometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const boxGeometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); const sphereRadius = 0.5; - const sphereGeometry = new THREE.SphereBufferGeometry(sphereRadius); + const sphereGeometry = new THREE.SphereGeometry(sphereRadius); function makeInstance(geometry, color, x) { const material = new THREE.MeshPhongMaterial({color});
true
Other
mrdoob
three.js
99e1625bfbaee81e7abc6506222eaaec4bb08535.json
Change all XXXBufferGeometry to XXXGeometry
threejs/threejs-webvr-point-to-select.html
@@ -62,10 +62,10 @@ const boxWidth = 1; const boxHeight = 1; const boxDepth = 1; - const boxGeometry = new THREE.BoxBufferGeometry(boxWidth, boxHeight, boxDepth); + const boxGeometry = new THREE.BoxGeometry(boxWidth, boxHeight, boxDepth); const sphereRadius = 0.5; - const sphereGeometry = new THREE.SphereBufferGeometry(sphereRadius); + const sphereGeometry = new THREE.SphereGeometry(sphereRadius); function makeInstance(geometry, color, x) { const material = new THREE.MeshPhongMaterial({color});
true
Other
mrdoob
three.js
fbac88d731b85fc9b25c69ce7161edd2566ed40c.json
remove references to XXXBufferGeometry
threejs/lessons/fr/threejs-primitives.md
@@ -26,26 +26,26 @@ La plupart des primitives ci-dessous ont des valeurs par défaut pour certains ou tous leurs paramètres. Vous pouvez donc les utiliser en fonction de vos besoins. -<div id="Diagram-BoxBufferGeometry" data-primitive="BoxBufferGeometry">Une Boîte</div> -<div id="Diagram-CircleBufferGeometry" data-primitive="CircleBufferGeometry">Un Cercle plat</div> -<div id="Diagram-ConeBufferGeometry" data-primitive="ConeBufferGeometry">Un Cône</div> -<div id="Diagram-CylinderBufferGeometry" data-primitive="CylinderBufferGeometry">Un Cylindre</div> -<div id="Diagram-DodecahedronBufferGeometry" data-primitive="DodecahedronBufferGeometry">Un Dodécaèdre (12 côtés)</div> -<div id="Diagram-ExtrudeBufferGeometry" data-primitive="ExtrudeBufferGeometry">Une forme 2D extrudée avec un biseautage optionnel. Ici, nous extrudons une forme de cœur. Notez qu'il s'agit du principe de fonctionnement pour les <code>TextBufferGeometry</code> et les <code>TextGeometry</code>.</div> -<div id="Diagram-IcosahedronBufferGeometry" data-primitive="IcosahedronBufferGeometry">Un Icosaèdre (20 côtés)</div> -<div id="Diagram-LatheBufferGeometry" data-primitive="LatheBufferGeometry">Une forme généré par la rotation d'une ligne pour, par exemple, dessiner une lampe, une quille, bougies, bougeoirs, verres à vin, verres à boire, etc. Vous fournissez une silhouette en deux dimensions comme une série de points et vous indiquez ensuite à three.js combien de subdivisions sont nécessaires en faisant tourner la silhouette autour d'un axe.</div> -<div id="Diagram-OctahedronBufferGeometry" data-primitive="OctahedronBufferGeometry">Un Octaèdre (8 côtés)</div> -<div id="Diagram-ParametricBufferGeometry" data-primitive="ParametricBufferGeometry">Une surface générée en fournissant à la fonction un point 2D d'une grille et retourne le point 3D correspondant.</div> -<div id="Diagram-PlaneBufferGeometry" data-primitive="PlaneBufferGeometry">Un plan 2D</div> -<div id="Diagram-PolyhedronBufferGeometry" data-primitive="PolyhedronBufferGeometry">Prend un ensemble de triangles centrés autour d'un point et les projette sur une sphère</div> -<div id="Diagram-RingBufferGeometry" data-primitive="RingBufferGeometry">Un disque 2D avec un trou au centre</div> -<div id="Diagram-ShapeBufferGeometry" data-primitive="ShapeBufferGeometry">Un tracé 2D qui se triangule</div> -<div id="Diagram-SphereBufferGeometry" data-primitive="SphereBufferGeometry">une sphère</div> -<div id="Diagram-TetrahedronBufferGeometry" data-primitive="TetrahedronBufferGeometry">Un tétraèdre (4 côtés)</div> -<div id="Diagram-TextBufferGeometry" data-primitive="TextBufferGeometry">Texte 3D généré à partir d'une police 3D et d'une chaîne de caractères</div> -<div id="Diagram-TorusBufferGeometry" data-primitive="TorusBufferGeometry">Un tore (donut)</div> -<div id="Diagram-TorusKnotBufferGeometry" data-primitive="TorusKnotBufferGeometry">Un nœud torique</div> -<div id="Diagram-TubeBufferGeometry" data-primitive="TubeBufferGeometry">Extrusion contrôlée d'un cercle le long d'un tracé</div> +<div id="Diagram-BoxGeometry" data-primitive="BoxGeometry">Une Boîte</div> +<div id="Diagram-CircleGeometry" data-primitive="CircleGeometry">Un Cercle plat</div> +<div id="Diagram-ConeGeometry" data-primitive="ConeGeometry">Un Cône</div> +<div id="Diagram-CylinderGeometry" data-primitive="CylinderGeometry">Un Cylindre</div> +<div id="Diagram-DodecahedronGeometry" data-primitive="DodecahedronGeometry">Un Dodécaèdre (12 côtés)</div> +<div id="Diagram-ExtrudeGeometry" data-primitive="ExtrudeGeometry">Une forme 2D extrudée avec un biseautage optionnel. Ici, nous extrudons une forme de cœur. Notez qu'il s'agit du principe de fonctionnement pour les <code>TextGeometry</code> et les <code>TextGeometry</code>.</div> +<div id="Diagram-IcosahedronGeometry" data-primitive="IcosahedronGeometry">Un Icosaèdre (20 côtés)</div> +<div id="Diagram-LatheGeometry" data-primitive="LatheGeometry">Une forme généré par la rotation d'une ligne pour, par exemple, dessiner une lampe, une quille, bougies, bougeoirs, verres à vin, verres à boire, etc. Vous fournissez une silhouette en deux dimensions comme une série de points et vous indiquez ensuite à three.js combien de subdivisions sont nécessaires en faisant tourner la silhouette autour d'un axe.</div> +<div id="Diagram-OctahedronGeometry" data-primitive="OctahedronGeometry">Un Octaèdre (8 côtés)</div> +<div id="Diagram-ParametricGeometry" data-primitive="ParametricGeometry">Une surface générée en fournissant à la fonction un point 2D d'une grille et retourne le point 3D correspondant.</div> +<div id="Diagram-PlaneGeometry" data-primitive="PlaneGeometry">Un plan 2D</div> +<div id="Diagram-PolyhedronGeometry" data-primitive="PolyhedronGeometry">Prend un ensemble de triangles centrés autour d'un point et les projette sur une sphère</div> +<div id="Diagram-RingGeometry" data-primitive="RingGeometry">Un disque 2D avec un trou au centre</div> +<div id="Diagram-ShapeGeometry" data-primitive="ShapeGeometry">Un tracé 2D qui se triangule</div> +<div id="Diagram-SphereGeometry" data-primitive="SphereGeometry">une sphère</div> +<div id="Diagram-TetrahedronGeometry" data-primitive="TetrahedronGeometry">Un tétraèdre (4 côtés)</div> +<div id="Diagram-TextGeometry" data-primitive="TextGeometry">Texte 3D généré à partir d'une police 3D et d'une chaîne de caractères</div> +<div id="Diagram-TorusGeometry" data-primitive="TorusGeometry">Un tore (donut)</div> +<div id="Diagram-TorusKnotGeometry" data-primitive="TorusKnotGeometry">Un nœud torique</div> +<div id="Diagram-TubeGeometry" data-primitive="TubeGeometry">Extrusion contrôlée d'un cercle le long d'un tracé</div> <div id="Diagram-EdgesGeometry" data-primitive="EdgesGeometry">Un objet d'aide qui prend une autre géométrie en entrée et génère des arêtes que si l'angle entre les faces est supérieur à un certain seuil. Par exemple, si vous regardez en haut de la boîte, elle montre une ligne passant par chaque @@ -61,36 +61,8 @@ n'y aurait que 3 points. Si vous essayez de le dessiner en utilisant un matéria triangulaire à un <code>WireframeGeometry</code> vous obtenez une nouvelle géométrie qui comporte 3 segments de lignes utilisant 6 points.</div> -Vous remarquerez que la plupart d'entre eux proviennent soit du type `Geometry` soit -du type `BufferGeometry`. Le choix entre ces deux types est question de compromis entre flexibilité et performance. - -Le choix des primitives basées sur le type `BufferGeometry` s'oriente sur le critère de la performance. Les -sommets de la géométrie sont générés directement dans un format de tableau typé efficace, prêt à -être envoyé au GPU pour le rendu. Cela signifie qu'ils sont plus rapides à démarrer et prennent -moins de mémoire, mais si vous voulez modifier leurs données, ils nécessitent ce qui est souvent -considéré comme une programmation plus ardue. - -Le choix des primitives basées sur le type `Geometry` s'oriente sur le critère de la flexiblité car elles sont les plus faciles à manipuler. -Elles sont construites à partir de classes JavaScript comme `Vector3` pour les points 3D et `Face3` -pour les triangles. -Elles demandent beaucoup de mémoire et avant de pouvoir être rendues à l'écran, three.js devra les convertir -en une représentation correspondante à `BufferGeometry`. - -Si vous savez que vous n'allez pas manipuler une primitive -ou si vous êtes à l'aise pour appliquer des calculs modifiant -leurs données internes, alors il est préférable d'opter pour les primitives -basées sur `BufferGeometry`. Si, par contre, vous -souhaitez modifier certaines choses avant le rendu, vous trouverez -peut-être les primitives basées sur la `Geometry` plus faciles à manipuler. - -Pour prendre un exemple simple, une `BufferGeometry` ne peut pas facilement -avoir de nouveaux sommets ajoutés. Le nombre de sommets utilisés -est décidé au moment de la création, le stockage est créé, puis les données -relatives aux sommets sont fournies. Alors que pour `Geometry`, vous -pouvez ajouter des sommets au fur et à mesure. - Nous reviendrons sur la création de géométrie personnalisée dans -[un autre article](threejs-custom-geometry.html). Pour l'instant, +[un autre article](threejs-custom-buffer-geometry.html). Pour l'instant, faisons un exemple en créant chaque type de primitive. Nous commencerons par les [exemples vus dans l'article précédent](threejs-responsive.html). @@ -167,7 +139,7 @@ qui constituent une forme. Pour un solide comme une sphère ou un cube, il n'y a généralement pas de raison de dessiner les côtés arrières des triangles car ils sont tous tournés ver l'intérieur de la forme. Dans notre cas, cependant, nous dessinons des objets -comme la `PlaneBufferGeometry` ou la `ShapeBufferGeometry` +comme la `PlaneGeometry` ou la `ShapeGeometry` qui sont bidimensionnnels et n'ont donc pas d'intérieur. Sans le paramètre `side: THREE.DoubleSide` elle disparaîtraient quand on regarderait leur dos. @@ -197,7 +169,7 @@ Par exemple, la création d'une boîte : const width = 8; // largeur const height = 8; // hauteur const depth = 8; // profondeur - addSolidGeometry(-2, -2, new THREE.BoxBufferGeometry(width, height, depth)); + addSolidGeometry(-2, -2, new THREE.BoxGeometry(width, height, depth)); } ``` @@ -208,7 +180,7 @@ Voici le résultat : {{{example url="../threejs-primitives.html" }}} Il y a quelques exceptions notables au modèle ci-dessus. -La plus grande est probablement le `TextBufferGeometry`. Il doit charger +La plus grande est probablement le `TextGeometry`. Il doit charger des données de police en 3D avant de pouvoir générer un maillage pour le texte. Ces données se chargent de manière asynchrone, nous devons donc attendre qu'elles soient chargées avant d'essayer de créer la géométrie. En "promettant" @@ -230,7 +202,7 @@ Et enfin, nous créons la géométrie et appelons `addObject` pour l'ajouter à async function doit() { const font = await loadFont('../resources/threejs/fonts/helvetiker_regular.typeface.json'); /* threejsfundamentals: url */ - const geometry = new THREE.TextBufferGeometry('three.js', { + const geometry = new THREE.TextGeometry('three.js', { font: font, size: 3.0, height: .2, @@ -317,7 +289,7 @@ prend une taille ([`size`](PointsMaterial.size)) pour la grosseur des points. const radius = 7; // rayon const widthSegments = 12; const heightSegments = 8; -const geometry = new THREE.SphereBufferGeometry(radius, widthSegments, heightSegments); +const geometry = new THREE.SphereGeometry(radius, widthSegments, heightSegments); const material = new THREE.PointsMaterial({ color: 'red', size: 0.2, // en unités du monde @@ -354,9 +326,9 @@ géométries des sphères prennant en paramètres le nombre de divisions à fair haut en bas. Par exemple : <div class="spread"> -<div data-diagram="SphereBufferGeometryLow"></div> -<div data-diagram="SphereBufferGeometryMedium"></div> -<div data-diagram="SphereBufferGeometryHigh"></div> +<div data-diagram="SphereGeometryLow"></div> +<div data-diagram="SphereGeometryMedium"></div> +<div data-diagram="SphereGeometryHigh"></div> </div> La première sphère a un tour de 5 segments et 3 de haut, soit 15 segments ou 30 triangles. @@ -368,9 +340,9 @@ ayez besoin d'un grand nombre de segments, mais si vous enlevez les lignes et le nous obtenons ceci : <div class="spread"> -<div data-diagram="SphereBufferGeometryLowSmooth"></div> -<div data-diagram="SphereBufferGeometryMediumSmooth"></div> -<div data-diagram="SphereBufferGeometryHighSmooth"></div> +<div data-diagram="SphereGeometryLowSmooth"></div> +<div data-diagram="SphereGeometryMediumSmooth"></div> +<div data-diagram="SphereGeometryHighSmooth"></div> </div> Il est moins perceptible que celle de droite avec 5000 triangles est meilleure que celle avec @@ -385,8 +357,8 @@ Parfois, il est facile de choisir. Par exemple, vous pouvez aussi choisir de subdiviser un plan. <div class="spread"> -<div data-diagram="PlaneBufferGeometryLow"></div> -<div data-diagram="PlaneBufferGeometryHigh"></div> +<div data-diagram="PlaneGeometryLow"></div> +<div data-diagram="PlaneGeometryHigh"></div> </div> Le plan à gauche est composé de 2 triangles. Le plan de droite est composé de 200 triangles. @@ -401,8 +373,7 @@ Vous devrez décider vous-même du compromis qui convient le mieux à cas d'util Si aucune des formes ci-dessus ne correspond à votre cas d'utilisation, vous pouvez charger la géométrie par exemple à partir d'un [fichier .obj](threejs-load-obj.html) ou d'un [fichier .gltf](threejs-load-gltf.html). -Vous pouvez également créer votre [Geometry](threejs-custom-geometry.html) -ou votre [BufferGeometry](threejs-custom-buffergeometry.html). +Vous pouvez également créer votre [BufferGeometry](threejs-custom-buffergeometry.html). Voyons maintenant l'article traitant sur [comment fonctionne un graphe de scène three.js et comment l'utiliser](threejs-scenegraph.html).
true