TextureLoader.html 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <script src="../../list.js"></script>
  6. <script src="../../page.js"></script>
  7. <link type="text/css" rel="stylesheet" href="../../page.css" />
  8. </head>
  9. <body>
  10. <h1>[name]</h1>
  11. <div class="desc">Class for loading a [page:Texture texture].</div>
  12. <div class="desc">Unlike other loaders, this one emits events instead of using predefined callbacks. So if you're interested in getting notified when <em>things</em> happen, you need to add listeners to the object.</div>
  13. <h2>Constructor</h2>
  14. <h3>[name]()</h3>
  15. <h2>Events</h2>
  16. <h3>load</h3>
  17. <div class="desc">
  18. Dispatched when the texture has completed loading
  19. </div>
  20. <div>
  21. content — loaded texture object
  22. </div>
  23. <h3>error</h3>
  24. <div class="desc">
  25. Dispatched when the texture can't be loaded
  26. </div>
  27. <div>
  28. message — error message
  29. </div>
  30. <h2>Properties</h2>
  31. <h3>.[page:todo crossOrigin]</h3>
  32. <div>
  33. default — *null*.<br />
  34. If set, assigns the *crossOrigin* attribute of the image to the value of *crossOrigin*, prior to starting the load.
  35. </div>
  36. <h2>Methods</h2>
  37. <h3>.load( [page:String url] )</h3>
  38. <div>
  39. url — required
  40. </div>
  41. <div class="desc">Begin loading from <em>url</em></div>
  42. <h2>Source</h2>
  43. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  44. </body>
  45. </html>