4 <meta charset="utf-8" />
6 <script src="list.js"></script>
7 <script src="page.js"></script>
8 <link type="text/css" rel="stylesheet" href="page.css" />
11 [page:BufferGeometry] →
15 <div class="desc">Generate geometry representing a parametric surface.</div>
17 <iframe id="scene" src="scenes/geometry-browser.html#ParametricBufferGeometry"></iframe>
21 // iOS iframe auto-resize workaround
23 if ( /(iPad|iPhone|iPod)/g.test( navigator.userAgent ) ) {
25 var scene = document.getElementById( 'scene' );
27 scene.style.width = getComputedStyle( scene ).width;
28 scene.style.height = getComputedStyle( scene ).height;
29 scene.setAttribute( 'scrolling', 'no' );
38 var geometry = new THREE.ParametricBufferGeometry( THREE.ParametricGeometries.klein, 25, 25 );
39 var material = new THREE.MeshBasicMaterial( { color: 0x00ff00 } );
40 var cube = new THREE.Mesh( geometry, material );
48 <h3>[name]([page:Function func], [page:Integer slices], [page:Integer stacks])</h3>
50 func — A function that takes in a [page:Float u] and [page:Float v] value each between 0 and 1 and returns a [page:Vector3]<br />
51 slices — The count of slices to use for the parametric function <br />
52 stacks — The count of stacks to use for the parametric function
58 [link:https://github.com/mrdoob/three.js/blob/master/src/geometries/ParametricGeometry.js src/geometries/ParametricGeometry.js]