DataTexture3D.html 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <base href="../../../" />
  6. <script src="list.js"></script>
  7. <script src="page.js"></script>
  8. <link type="text/css" rel="stylesheet" href="page.css" />
  9. </head>
  10. <body>
  11. [page:Texture] &rarr;
  12. <h1>[name]</h1>
  13. <p class="desc">Creates a three-dimensional texture. This type of texture can only be used with a WebGL 2 rendering context.</p>
  14. <h2>Constructor</h2>
  15. <h3>[name]( [param:TypedArray data], [param:Number width], [param:Number height], [param:Number depth] )</h3>
  16. <p>
  17. [page:Object data] -- data of the texture.<br />
  18. [page:Number width] -- width of the texture.<br />
  19. [page:Number height] -- height of the texture.<br />
  20. [page:Number depth] -- depth of the texture.
  21. </p>
  22. <h2>Examples</h2>
  23. <p>
  24. [example:webgl2_materials_texture3d WebGL2 / materials / texture3d]<br />
  25. [example:webgl2_materials_texture2darray WebGL2 / materials / texture2darray]
  26. </p>
  27. <h2>Properties</h2>
  28. <p>
  29. See the base [page:Texture Texture] class for common properties.
  30. </p>
  31. <h3>[property:number wrapR]</h3>
  32. <p>
  33. This defines how the texture is wrapped in the depth direction.<br />
  34. The default is [page:Textures THREE.ClampToEdgeWrapping], where the edge is clamped to the outer edge texels.
  35. The other two choices are [page:Textures THREE.RepeatWrapping] and [page:Textures THREE.MirroredRepeatWrapping].
  36. See the [page:Textures texture constants] page for details.
  37. </p>
  38. <h2>Methods</h2>
  39. <p>
  40. See the base [page:Texture Texture] class for common methods.
  41. </p>
  42. <h2>Source</h2>
  43. <p>
  44. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  45. </p>
  46. </body>
  47. </html>