OpenShadingLanguage 1.00 # Compiled by oslc 1.3.3 shader TriGAOVr param float AO_Angle 0.94999999 %read{19,25} %write{2147483647,-1} %derivs param float maxDistance 25 %read{31,31} %write{2147483647,-1} param int GreenAO 0 %meta{string,widget,"checkBox"} %read{34,34} %write{2147483647,-1} param float GreenAODistance 150 %read{35,35} %write{2147483647,-1} param int BlueAO 0 %meta{string,widget,"checkBox"} %read{39,39} %write{2147483647,-1} param float BlueAODistance 5 %read{40,40} %write{2147483647,-1} param float BoostExposure 1 %read{51,51} %write{2147483647,-1} param float OverSampling 4 %read{11,45} %write{2147483647,-1} oparam closure color TriAO %read{2147483647,-1} %write{1,51} global point P %read{15,40} %write{2147483647,-1} %derivs global normal N %read{18,18} %write{2147483647,-1} %derivs local int RTdiffuse %read{3,3} %write{2,2} local closure color ___352_NullClosure %read{5,5} %write{4,4} local color ___353_CoulOut %read{10,50} %write{6,49} local closure color ___353_closureIn %read{50,50} %write{7,7} local int ___353_Loopi %read{10,49} %write{8,49} %derivs local float ___353_LoopShift %read{10,49} %write{9,49} %derivs local vector ___355_VectorAO %read{10,49} %write{10,49} %derivs local vector ___356_bruitvector %read{10,49} %write{10,49} %derivs local float ___355_mixageRED %read{10,49} %write{10,49} local float ___355_mixageGreen %read{10,49} %write{10,49} local float ___355_mixageBlue %read{10,49} %write{10,49} local vector ___355_DirTrace %read{10,49} %write{10,49} %derivs local int ___355_DoTraceRED %read{10,49} %write{10,49} local int ___358_DoTraceGreen %read{10,49} %write{10,49} local int ___361_DoTraceBlue %read{10,49} %write{10,49} temp closure color $tmp1 %read{1,1} %write{0,0} const string $const1 "emission" %read{0,7} %write{2147483647,-1} const color $const2 1 1 1 %read{1,1} %write{2147483647,-1} const string $const3 "diffuse" %read{2,2} %write{2147483647,-1} const float $const4 0 %read{4,42} %write{2147483647,-1} const color $const5 0 0 0 %read{6,6} %write{2147483647,-1} const int $const6 0 %read{8,8} %write{2147483647,-1} const float $const7 0.00069999998 %read{9,9} %write{2147483647,-1} temp int $tmp3 %read{10,49} %write{10,49} const float $const8 0.001 %read{12,12} %write{2147483647,-1} temp vector $tmp4 %read{17,17} %write{16,16} %derivs const string $const9 "perlin" %read{16,24} %write{2147483647,-1} const float $const10 10000 %read{14,22} %write{2147483647,-1} temp float $tmp5 %read{15,15} %write{14,14} %derivs temp float $tmp6 %read{14,14} %write{13,13} %derivs temp point $tmp7 %read{16,16} %write{15,15} %derivs temp vector $tmp8 %read{18,18} %write{17,17} %derivs temp int $tmp9 %read{20,20} %write{19,19} temp vector $tmp10 %read{25,25} %write{24,24} %derivs temp float $tmp11 %read{23,23} %write{22,22} %derivs temp float $tmp12 %read{22,22} %write{21,21} %derivs temp vector $tmp13 %read{24,24} %write{23,23} %derivs const float $const11 1 %read{27,45} %write{2147483647,-1} const string $const12 "maxdist" %read{31,40} %write{2147483647,-1} temp color $tmp14 %read{46,46} %write{44,44} temp float $tmp15 %read{46,46} %write{45,45} temp color $tmp16 %read{47,47} %write{46,46} const int $const13 1 %read{49,49} %write{2147483647,-1} temp int $tmp17 %read{2147483647,-1} %write{48,48} temp closure color $tmp18 %read{51,51} %write{50,50} code TriAO # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:64 # ) closure $tmp1 $const1 %filename{"D:\\OSL\\VRAYscripts\\TriGAOVr.osl"} %line{64} %argrw{"wr"} mul TriAO $tmp1 $const2 %argrw{"wrr"} code ___main___ # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:68 # raytype RTdiffuse $const3 %filename{"D:\\OSL\\VRAYscripts\\TriGAOVr.osl"} %line{68} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:70 # { if RTdiffuse 6 52 %line{70} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:72 # TriAO = NullClosure ; assign ___352_NullClosure $const4 %line{72} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:73 # } else assign TriAO ___352_NullClosure %line{73} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:77 # closure color closureIn = emission() ; assign ___353_CoulOut $const5 %line{77} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:78 # closure ___353_closureIn $const1 %line{78} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:80 # float LoopShift = 0.0007 ; assign ___353_Loopi $const6 %line{80} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:81 # assign ___353_LoopShift $const7 %line{81} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:83 # { for $tmp3 11 12 48 50 %line{83} %argrw{"r"} lt $tmp3 ___353_Loopi OverSampling %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:86 # add ___353_LoopShift ___353_LoopShift $const8 %line{86} %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:89 # if ( AO_Angle != 0.0 ) assign $tmp6 ___353_Loopi %line{89} %argrw{"wr"} add $tmp5 $const10 $tmp6 %argrw{"wrr"} mul $tmp7 P $tmp5 %argrw{"wrr"} noise $tmp4 $const9 $tmp7 %argrw{"wrr"} mul $tmp8 ___353_LoopShift $tmp4 %argrw{"wrr"} add ___355_VectorAO N $tmp8 %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:90 # { neq $tmp9 AO_Angle $const4 %line{90} %argrw{"wrr"} if $tmp9 27 27 %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:92 # VectorAO += bruitvector ; assign $tmp12 ___353_Loopi %line{92} %argrw{"wr"} add $tmp11 $const10 $tmp12 %argrw{"wrr"} mul $tmp13 ___355_VectorAO $tmp11 %argrw{"wrr"} noise $tmp10 $const9 $tmp13 %argrw{"wrr"} mul ___356_bruitvector AO_Angle $tmp10 %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:93 # } add ___355_VectorAO ___355_VectorAO ___356_bruitvector %line{93} %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:97 # float mixageGreen = 1.0 ; assign ___355_mixageRED $const11 %line{97} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:98 # float mixageBlue = 1.0 ; assign ___355_mixageGreen $const11 %line{98} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:99 # vector DirTrace = VectorAO ; assign ___355_mixageBlue $const11 %line{99} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:100 # assign ___355_DirTrace ___355_VectorAO %line{100} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:102 # if ( DoTraceRED ) trace ___355_DoTraceRED P ___355_DirTrace $const12 maxDistance %line{102} %argrw{"wrrrr"} %argderivs{1,2} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:103 # { if ___355_DoTraceRED 34 34 %line{103} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:105 # } assign ___355_mixageRED $const4 %line{105} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:109 # { if GreenAO 38 39 %line{109} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:111 # if ( DoTraceGreen ) trace ___358_DoTraceGreen P ___355_DirTrace $const12 GreenAODistance %line{111} %argrw{"wrrrr"} %argderivs{1,2} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:112 # { if ___358_DoTraceGreen 38 38 %line{112} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:114 # } assign ___355_mixageGreen $const4 %line{114} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:119 # } assign ___355_mixageGreen ___355_mixageRED %line{119} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:122 # { if BlueAO 43 44 %line{122} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:124 # if ( DoTraceBlue ) trace ___361_DoTraceBlue P ___355_DirTrace $const12 BlueAODistance %line{124} %argrw{"wrrrr"} %argderivs{1,2} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:125 # { if ___361_DoTraceBlue 43 43 %line{125} %argrw{"r"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:127 # } assign ___355_mixageBlue $const4 %line{127} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:132 # } assign ___355_mixageBlue ___355_mixageRED %line{132} %argrw{"wr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:136 # color $tmp14 ___355_mixageRED ___355_mixageGreen ___355_mixageBlue %line{136} %argrw{"wrrr"} div $tmp15 $const11 OverSampling %argrw{"wrr"} mul $tmp16 $tmp14 $tmp15 %argrw{"wrr"} add ___353_CoulOut ___353_CoulOut $tmp16 %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:83 # { assign $tmp17 ___353_Loopi %line{83} %argrw{"wr"} add ___353_Loopi ___353_Loopi $const13 %argrw{"wrr"} # D:\\OSL\\VRAYscripts\\TriGAOVr.osl:141 # } mul $tmp18 ___353_closureIn ___353_CoulOut %line{141} %argrw{"wrr"} mul TriAO $tmp18 BoostExposure %argrw{"wrr"} end