SphericalHarmonics3.html 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. <!DOCTYPE html>
  2. <html lang="it">
  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. <h1>[name]</h1>
  11. <p class="desc">
  12. Rappresenta un'armonica sferica del terzo ordine (SH). Le sonde luminose utilizzano questa classe per codificare le
  13. informazioni sull'illuminazione.
  14. </p>
  15. <h2>Costruttore</h2>
  16. <h3>[name]()</h3>
  17. <p>
  18. Crea una nuova istanza di [name].
  19. </p>
  20. <h2>Proprietà</h2>
  21. <h3>[property:Array coefficients]</h3>
  22. <p>Un array contenente i (9) coefficienti SH. Un singolo coefficiente è rappresentato come un'istanza di [page:Vector3].</p>
  23. <h3>[property:Boolean isSphericalHarmonics3]</h3>
  24. <p>
  25. Flag di sola lettura per verificare se l'oggetto dato è di tipo [name].
  26. </p>
  27. <h2>Metodi</h2>
  28. <h3>[method:this add]( [param:SphericalHarmonics3 sh] )</h3>
  29. <p>
  30. [page:SphericalHarmonics3 sh] - L'SH da aggiungere.<br /><br />
  31. Aggiunge l'SH dato a questa istanza.
  32. </p>
  33. <h3>[method:this addScaledSH]( [param:SphericalHarmonics3 sh], [param:Number scale] )</h3>
  34. <p>
  35. [page:SphericalHarmonics3 sh] - L'SH da aggiungere.<br />
  36. [page:Number scale] - Il fattore scale.<br /><br />
  37. Un metodo pratico per eseguire [page:.add]() e [page:.scale]() contemporaneamente.
  38. </p>
  39. <h3>[method:SphericalHarmonics3 clone]()</h3>
  40. <p>
  41. Restituisce una nuova istanza di [name] con i coefficienti uguali.
  42. </p>
  43. <h3>[method:this copy]( [param:SphericalHarmonics3 sh] )</h3>
  44. <p>
  45. [page:SphericalHarmonics3 sh] - L'SH da copiare.<br /><br />
  46. Copia l'SH dato per questa istanza.
  47. </p>
  48. <h3>[method:Boolean equals]( [param:SphericalHarmonics3 sh] )</h3>
  49. <p>
  50. [page:SphericalHarmonics3 sh] - L'SH con cui fare la comparazione.<br /><br />
  51. Restituisce true se l'SH dato e questa istanza hanno coefficienti uguali.
  52. </p>
  53. <h3>[method:this fromArray]( [param:Array array], [param:Number offset] )</h3>
  54. <p>
  55. [page:Array array] - L'array contiene i numeri dei coefficienti SH.<br />
  56. [page:Number offset] - (opzionale) L'offset dell'array.<br /><br />
  57. Imposta i coefficienti di questa istanza dall'array passato.
  58. </p>
  59. <h3>[method:Vector3 getAt]( [param:Vector3 normal], [param:Vector3 target] )</h3>
  60. <p>
  61. [page:Vector3 normal] - Il vettore normale (si assume che abbia lunghezza unitaria).<br />
  62. [page:Vector3 target] - Il vettore risultato.<br /><br />
  63. Restituisce la radianza nella direzione della normale data.
  64. </p>
  65. <h3>[method:Vector3 getIrradianceAt]( [param:Vector3 normal], [param:Vector3 target] )</h3>
  66. <p>
  67. [page:Vector3 normal] - Il vettore normale (si assume che abbia lunghezza unitaria).<br />
  68. [page:Vector3 target] - Il vettore risultato.<br /><br />
  69. Restituisce l'irradianza (radianza convoluta con il lobo del coseno) nella direzione della normale data.
  70. </p>
  71. <h3>[method:this lerp]( [param:SphericalHarmonics3 sh], [param:Number alpha] )</h3>
  72. <p>
  73. [page:SphericalHarmonics3 sh] - L'SH con cui interpolare.<br />
  74. [page:Number alpha] - Il fattore alfa.<br /><br />
  75. Interpolazioni lineari tra l'SH dato e questa istanza dal fattore alfa dato.
  76. </p>
  77. <h3>[method:this scale]( [param:Number scale] )</h3>
  78. <p>
  79. [page:Number scale] - Il fattore scale.<br /><br />
  80. Ridimensiona questo SH in base al fattore scale passato.
  81. </p>
  82. <h3>[method:this set]( [param:Array coefficients] )</h3>
  83. <p>
  84. [page:Array coefficients] - Un array di coefficienti SH.<br /><br />
  85. Imposta i coefficienti SH passati in questa istanza.
  86. </p>
  87. <h3>[method:Array toArray]( [param:Array array], [param:Number offset] )</h3>
  88. <p>
  89. [page:Array array] - (opzionale) L'array target.<br />
  90. [page:Number offset] - (opzionale) L'array offset.<br /><br />
  91. Restituisce un array con i coefficienti, o li copia nell'array fornito. I coefficienti
  92. sono rappresentati come numeri.
  93. </p>
  94. <h3>[method:this zero]()</h3>
  95. <p>
  96. Imposta tutti i coefficienti a 0.
  97. </p>
  98. <h2>Metodi Statici</h2>
  99. <h3>[method:undefined getBasisAt]( [param:Vector3 normal], [param:Array shBasis] )</h3>
  100. <p>
  101. [page:Vector3 normal] - Il vettore normale (si presume che abbia lunghezza unitaria).<br />
  102. [page:Array shBasis] - La base SH risultante.<br /><br />
  103. Calcola la base SH per il vettore normale passato.
  104. </p>
  105. <h2>Source</h2>
  106. <p>
  107. [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
  108. </p>
  109. </body>
  110. </html>