Rectangle.html 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  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">
  12. Mainly used internaly by [page:CanvasRenderer] for 2D clipping.
  13. </div>
  14. <h2>Constructor</h2>
  15. <h3>[name]()</h3>
  16. <h2>Methods</h2>
  17. <h3>.getX() [page:Float]</h3>
  18. <h3>.getY() [page:Float]</h3>
  19. <h3>.getWidth() [page:Float]</h3>
  20. <h3>.getHeight() [page:Float]</h3>
  21. <h3>.getLeft() [page:Float]</h3>
  22. <h3>.getTop() [page:Float]</h3>
  23. <h3>.getRight() [page:Float]</h3>
  24. <h3>.getBottom() [page:Float]</h3>
  25. <h3>.set( [page:Float left], [page:Float top], [page:Float right], [page:Float bottom] )</h3>
  26. <h3>.addPoint( [page:Float x], [page:Float y] )</h3>
  27. <h3>.add3Points( [page:Float x1], [page:Float y1], [page:Float x2], [page:Float y2], [page:Float x3], [page:Float y3] )</h3>
  28. <h3>.addRectangle( [page:Rectangle r] )</h3>
  29. <h3>.inflate( [page:Float v] )</h3>
  30. <h3>.minSelf( [page:Rectangle r] )</h3>
  31. <h3>.intersects( [page:Rectangle r] ) [page:Boolean]</h3>
  32. <div>
  33. Adapted from [link:http://gamemath.com/2011/09/detecting-whether-two-boxes-overlap/].
  34. </div>
  35. <h3>.empty()</h3>
  36. <h3>.isEmpty() [page:Boolean]</h3>
  37. <h2>Source</h2>
  38. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  39. </body>
  40. </html>