Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
texture_index [2013/05/03 15:47]
alancoelho created
texture_index [2013/05/13 05:33]
alancoelho
Line 1: Line 1:
-====== Texture Index from Spherical Harmonics Parameters ======+====== Texture Index from Spherical Harmonics Parameters ​- Version 5 ======
  
- macro Texture_Index(sh, ​tex+ macro Texture_Index(sh, ​t
-   ​+    
-      ​if Prm_There(sh##​_c20) ​ {} else {prm sh##​_c20 ​0;} +      prm = { 
-      if Prm_There(sh##​_c21p) ​{} else {prm sh##_c21p = 0;} +         fn f(c) { 
-      if Prm_There(sh##_c21m) {} else {prm sh##_c21m = 0;} +            def s Concat(sh,"​_",​c); 
-      if Prm_There(sh##​_c22p) {} else {prm sh##​_c22p ​0;} +            ​return If(Prm_There(s), s^2,0);  
-      if Prm_There(sh##_c22m{} else {prm sh##_c22m = 0;} +         ​
-      if Prm_There(sh##​_c40) ​ {} else {prm sh##_c40 = 0;} +         return 1  
-      if Prm_There(sh##_c41p{} else {prm sh##_c41p = 0;} +         +1/​5  ​(f(c20)+f(c21p)+f(c21m)+f(c22p)+f(c22m)) 
-      if Prm_There(sh##​_c41m{} else {prm sh##_c41m = 0;} +         +1/​9  ​(f(c40)+f(c41p)+f(c41m)+f(c42p)+f(c42m)+f(c43p)+f(c43m)+f(c44p)+f(c44m)) 
-      if Prm_There(sh##​_c42p) {} else {prm sh##_c42p = 0;+         +1/13 (f(c60)+f(c61p)+f(c61m)+f(c62p)+f(c62m)+f(c63p)+f(c63m)+f(c64p)+f(c64m)+f(c65p)+f(c65m)+f(c66p)+f(c66m)) 
-      if Prm_There(sh##​_c42m) {} else {prm sh##_c42m = 0;} +         ​+1/17 (f(c80)+f(c81p)+f(c81m)+f(c82p)+f(c82m)+f(c83p)+f(c83m)+f(c84p)+f(c84m)+f(c85p)+f(c85m)+f(c86p)+f(c86m)+f(c87p)+f(c87m)+f(c88p)+f(c88m)); 
-      if Prm_There(sh##_c43p) {} else {prm sh##_c43p = 0;} +      ​t
-      if Prm_There(sh##_c43m{} else {prm sh##_c43m = 0;} +
-      if Prm_There(sh##_c44p{} else {prm sh##_c44p = 0;} +
-      if Prm_There(sh##_c44m{} else {prm sh##_c44m = 0;} +
-      if Prm_There(sh##_c60 {} else {prm sh##_c60 = 0;} +
-      if Prm_There(sh##_c61p{} else {prm sh##_c61p = 0;} +
-      if Prm_There(sh##​_c61m{} else {prm sh##_c61m = 0;} +
-      if Prm_There(sh##_c62p) {} else {prm sh##_c62p = 0;} +
-      if Prm_There(sh##_c62m{} else {prm sh##_c62m = 0;} +
-      if Prm_There(sh##_c63p{} else {prm sh##_c63p = 0;} +
-      if Prm_There(sh##_c63m{} else {prm sh##_c63m = 0;} +
-      if Prm_There(sh##_c64p{} else {prm sh##_c64p = 0;} +
-      if Prm_There(sh##_c64m{} else {prm sh##_c64m = 0;} +
-      if Prm_There(sh##_c65p{} else {prm sh##_c65p = 0;} +
-      if Prm_There(sh##_c65m{} else {prm sh##_c65m = 0;} +
-      if Prm_There(sh##_c66p{} else {prm sh##_c66p = 0;} +
-      if Prm_There(sh##_c66m{} else {prm sh##_c66m = 0;} +
-      if Prm_There(sh##​_c80 {} else {prm sh##_c80 = 0;} +
-      if Prm_There(sh##_c81p) {} else {prm sh##_c81p = 0;} +
-      if Prm_There(sh##_c81m{} else {prm sh##_c81m = 0;} +
-      if Prm_There(sh##_c82p{} else {prm sh##_c82p = 0;} +
-      if Prm_There(sh##_c82m{} else {prm sh##_c82m = 0;} +
-      if Prm_There(sh##_c83p{} else {prm sh##_c83p = 0;} +
-      if Prm_There(sh##_c83m{} else {prm sh##_c83m = 0;} +
-      if Prm_There(sh##_c84p{} else {prm sh##_c84p = 0;} +
-      if Prm_There(sh##_c84m{} else {prm sh##_c84m = 0;} +
-      if Prm_There(sh##_c85p{} else {prm sh##_c85p = 0;} +
-      if Prm_There(sh##_c85m{} else {prm sh##_c85m = 0;} +
-      if Prm_There(sh##_c86p{} else {prm sh##_c86p = 0;} +
-      if Prm_There(sh##_c86m{} else {prm sh##_c86m = 0;} +
-      if Prm_There(sh##_c87p{} else {prm sh##_c87p = 0;} +
-      if Prm_There(sh##_c87m{} else {prm sh##_c87m = 0;} +
-      if Prm_There(sh##​_c88p{} else {prm sh##_c88p = 0;} +
-      if Prm_There(sh##​_c88m) {} else {prm sh##_c88m = 0;} +
-      prm = 1 (1/(sh##​_c20^2 ​sh##​_c21p^2 ​sh##​_c21m^2 ​sh##​_c22p^2 ​sh##_c22m^2'2nd order +
-      ​1/9 (sh##​_c40^2 ​sh##​_c41p^2 ​sh##​_c41m^2 ​sh##​_c42p^2 ​sh##​_c42m^2 ​sh##​_c43p^2 ​sh##​_c43m^2 ​sh##​_c44p^2 ​sh##_c44m^2 '​4th order +
-      ​1/13 (sh##​_c60^2 ​sh##_c61p^2 + sh##_c61m^2 + sh##_c62p^2 + sh##_c62m^2 + sh##_c63p^2 + sh##_c63m^2 + sh##_c64p^2 + sh##_c64m^2 + sh##_c65p^2 + sh##_c65m^2 + sh##_c66p^2 + sh##_c66m^2  '6th order +
-      ​1/17 (sh##_c80^2 + sh##_c81p^2 + sh##_c81m^2 + sh##_c82p^2 + sh##_c82m^2 + sh##_c83p^2 + sh##_c83m^2 + sh##_c84p^2 + sh##_c84m^2 + sh##_c85p^2 + sh##_c85m^2 + sh##_c86p^2 + sh##_c86m^2 + sh##_c87p^2 + sh##_c87m^2 + sh##_c88p^2 + sh##_c88m^2)); +
-      : tex+
    }    }
 +
  
  

Personal Tools