WebGLMultipleRenderTargets.html 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <!DOCTYPE html>
  2. <html lang="zh">
  3. <head>
  4. <meta charset="utf-8" />
  5. <base href="../../../" />
  6. <script src="page.js"></script>
  7. <link type="text/css" rel="stylesheet" href="page.css" />
  8. </head>
  9. <body>
  10. [page:WebGLRenderTarget] &rarr;
  11. <h1>[name]</h1>
  12. <p class="desc">
  13. A special render target that enables a fragment shader to write to several textures.
  14. This approach is useful for advanced rendering techniques like post-processing or deferred rendering.
  15. Heads up: [name] can only be used with a WebGL 2 rendering context.
  16. </p>
  17. <h2>Examples</h2>
  18. <p>
  19. [example:webgl2_multiple_rendertargets webgl2 / multiple / rendertargets ]
  20. </p>
  21. <h2>Constructor</h2>
  22. <h3>[name]([param:Number width], [param:Number height], [param:Number count])</h3>
  23. <p>
  24. [page:Number width] - The width of the render target. <br />
  25. [page:Number height] - The height of the render target.<br />
  26. [page:Number count] - The number of render targets.
  27. </p>
  28. <h2>Properties</h2>
  29. <h3>[property:Array texture]</h3>
  30. <p>
  31. The texture property is overwritten in [name] and replaced with an array. This array holds the [page:WebGLRenderTarget.texture texture]
  32. references of the respective render targets.
  33. </p>
  34. <p>[page:WebGLRenderTarget WebGLRenderTarget] properties are available on this class.</p>
  35. <h2>Methods</h2>
  36. <p>[page:WebGLRenderTarget WebGLRenderTarget] methods are available on this class.</p>
  37. <h2>Source</h2>
  38. <p>
  39. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  40. </p>
  41. </body>
  42. </html>