OpenShadingLanguage 1.01
# Compiled by oslc 1.6.2
surface aachrome
param	float	Kr	1		%read{41,41} %write{2147483647,-1}
param	float	samples	1		%read{3,3} %write{2147483647,-1}
param	string	envmap	"raytrace"		%read{16,37} %write{2147483647,-1}
global	point	P	%read{25,37} %write{2147483647,-1} %derivs
global	vector	I	%read{5,9} %write{2147483647,-1} %derivs
global	normal	N	%read{5,8} %write{2147483647,-1} %derivs
global	color	C	%read{2147483647,-1} %write{41,41}
global	color	opacity	%read{2147483647,-1} %write{42,42}
local	int	___301_status	%read{31,31} %write{30,30}
local	color	___302_C	%read{39,39} %write{28,38}
local	point	___304_Pndc	%read{26,27} %write{25,25} %derivs
local	vector	___306_D	%read{2147483647,-1} %write{34,34}
local	color	Crefl	%read{41,41} %write{39,40}
local	float	s	%read{36,36} %write{3,4}
local	normal	___340_Nn	%read{11,13} %write{8,8} %derivs
local	vector	___340_In	%read{11,14} %write{9,9} %derivs
local	vector	___340_reflDir	%read{34,37} %write{14,14} %derivs
temp	int	$tmp1	%read{1,1} %write{0,0}
const	int	$const1	0		%read{1,40} %write{2147483647,-1}
temp	int	$tmp2	%read{2,2} %write{1,1}
const	int	$const2	1		%read{4,42} %write{2147483647,-1}
temp	float	$tmp3	%read{6,6} %write{5,5}
temp	int	$tmp4	%read{7,7} %write{6,6}
const	string	$const3	"reflect"		%read{10,10} %write{2147483647,-1}
temp	float	$tmp5	%read{12,12} %write{11,11} %derivs
temp	float	$tmp6	%read{13,13} %write{12,12} %derivs
const	float	$const5	2		%read{12,12} %write{2147483647,-1}
temp	vector	$tmp7	%read{14,14} %write{13,13} %derivs
const	string	$const6	""		%read{16,34} %write{2147483647,-1}
const	float	$const7	0		%read{28,37} %write{2147483647,-1}
const	float	$const8	1		%read{18,18} %write{2147483647,-1}
const	string	$const9	"Environment"		%read{15,15} %write{2147483647,-1}
temp	int	$tmp8	%read{17,21} %write{16,20}
temp	int	$tmp9	%read{19,19} %write{18,18}
temp	int	$tmp10	%read{20,20} %write{19,19}
const	string	$const10	"NDC"		%read{22,25} %write{2147483647,-1}
temp	int	$tmp11	%read{23,23} %write{22,22}
const	string	$const11	"transform"		%read{24,33} %write{2147483647,-1}
const	string	$const12	"common"		%read{25,34} %write{2147483647,-1}
temp	float	$tmp12	%read{28,28} %write{26,26} %derivs
temp	float	$tmp13	%read{28,28} %write{27,27} %derivs
const	string	$const13	"blur"		%read{28,37} %write{2147483647,-1}
temp	int	$tmp14	%read{32,32} %write{31,31}
const	string	$const14	"istexture"		%read{29,29} %write{2147483647,-1}
temp	int	$tmp15	%read{2147483647,-1} %write{30,30}
const	string	$const15	"exists"		%read{30,30} %write{2147483647,-1}
const	string	$const16	"samples"		%read{37,37} %write{2147483647,-1}
temp	int	$tmp16	%read{37,37} %write{36,36}
const	string	$const17	"traceset"		%read{37,37} %write{2147483647,-1}
code ___main___
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:19
# 
	raylevel	$tmp1 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl"} %line{19} %argrw{"w"}
	eq		$tmp2 $tmp1 $const1 	%argrw{"wrr"}
	if		$tmp2 4 5 	%argrw{"r"}
	assign		s samples 	%argrw{"wr"}
	assign		s $const2 	%argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:21
#         normal Nn = normalize(N);
	dot		$tmp3 N I 	%line{21} %argrw{"wrr"}
	lt		$tmp4 $tmp3 $const1 	%argrw{"wrr"}
	if		$tmp4 40 41 	%argrw{"r"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:22
#         vector In = normalize(I);
	normalize	___340_Nn N 	%line{22} %argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:23
#         vector reflDir = reflect(In,Nn);
	normalize	___340_In I 	%line{23} %argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:24
#         Crefl = Environment(envmap, reflDir, "", 0, s, 1);
	functioncall	$const3 15 	%line{24} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:198
# 
	dot		$tmp5 ___340_Nn ___340_In 	%filename{"D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h"} %line{198} %argrw{"wrr"}
	mul		$tmp6 $const5 $tmp5 	%argrw{"wrr"}
	mul		$tmp7 $tmp6 ___340_Nn 	%argrw{"wrr"}
	sub		___340_reflDir ___340_In $tmp7 	%argrw{"wrr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:25
#     } else { /* don't reflect inside object */
	functioncall	$const9 40 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl"} %line{25} %argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:205
# // Inputs are:
	neq		$tmp8 envmap $const6 	%filename{"D:/xrt.git\\src\\osl\\shaders\\material.h"} %line{205} %argrw{"wrr"}
	if		$tmp8 21 21 	%argrw{"r"}
	gt		$tmp9 $const8 $const1 	%argrw{"wrr"}
	neq		$tmp10 $tmp9 $const1 	%argrw{"wrr"}
	assign		$tmp8 $tmp10 	%argrw{"wr"}
	if		$tmp8 38 39 	%argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:206
# //    envname - filename of environment map, or name of geometry set
	eq		$tmp11 $const6 $const10 	%line{206} %argrw{"wrr"}
	if		$tmp11 29 38 	%argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:208
# //    R - direction of traced ray
	functioncall	$const11 26 	%line{208} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:249
# #define M_E        2.7182818284590452        /* e (Euler's number) */
	transform	___304_Pndc $const12 $const10 P 	%filename{"D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h"} %line{249} %argrw{"wrrr"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:209
#             C = texture (envname, Pndc[0], Pndc[1], "blur", blur);
	compref		$tmp12 ___304_Pndc $const1 	%filename{"D:/xrt.git\\src\\osl\\shaders\\material.h"} %line{209} %argrw{"wrr"}
	compref		$tmp13 ___304_Pndc $const2 	%argrw{"wrr"}
	texture		___302_C envmap $tmp12 $tmp13 $const13 $const7 	%argrw{"wrrrrr"} %argderivs{2,3}
# D:/xrt.git\\src\\osl\\shaders\\material.h:211
# 			if (istexture (envname)) {
	functioncall	$const14 32 	%line{211} %argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:169
# 	gettextureinfo (envname, "exists", status);
	gettextureinfo	$tmp15 envmap $const15 ___301_status 	%line{169} %argrw{"wrrw"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:170
# 	return status;
	assign		$tmp14 ___301_status 	%line{170} %argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:211
# 			if (istexture (envname)) {
	if		$tmp14 36 38 	%line{211} %argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:213
#                 vector D = transform (envspace, R);
	functioncall	$const11 35 	%line{213} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:248
# #define M_PI_2     1.5707963267948966        /* pi/2 */
	transformv	___306_D $const12 $const6 ___340_reflDir 	%filename{"D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h"} %line{248} %argrw{"wrrr"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:214
#                 C = environment (envname, R, "blur", blur);
	environment	___302_C envmap ___340_reflDir $const13 $const7 	%filename{"D:/xrt.git\\src\\osl\\shaders\\material.h"} %line{214} %argrw{"wrrrr"} %argderivs{2}
# D:/xrt.git\\src\\osl\\shaders\\material.h:217
#                 C = trace (P, R, "blur", blur, "samples", (int)samples,
	assign		$tmp16 s 	%line{217} %argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:218
#                              "traceset", envname);
	trace		___302_C P ___340_reflDir $const13 $const7 $const16 $tmp16 $const17 envmap 	%line{218} %argrw{"wrrrrrrrr"} %argderivs{1,2}
# D:/xrt.git\\src\\osl\\shaders\\material.h:222
#     else C = 0;
	assign		___302_C $const1 	%line{222} %argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\material.h:223
#     return C;
	assign		Crefl ___302_C 	%line{223} %argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:27
#     }
	assign		Crefl $const1 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl"} %line{27} %argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:30
#     opacity = 1;
	mul		C Kr Crefl 	%line{30} %argrw{"wrr"}
# D:\\xrt.git\\src\\osl\\shaders\\aachrome.osl:31
# }
	assign		opacity $const2 	%line{31} %argrw{"wr"}
	end
