OpenShadingLanguage 1.01
# Compiled by oslc 1.6.2
displacement lumpy	%meta{string,description,"Lumpy displacement, procedural"} 
param	float	Km	1		%meta{string,description,"Amplitude"}  %read{29,29} %write{2147483647,-1} %derivs
param	float	sharp	1		%meta{string,description,"Sharpness"} %meta{float,UImin,0}  %read{28,28} %write{2147483647,-1} %derivs
param	float	octaves	3		%meta{string,description,"Octaves of noise"} %meta{string,UItype,"int"} %meta{float,UImin,1} %meta{float,UIsoftmax,8}  %read{14,14} %write{2147483647,-1}
param	float	freq	1		%meta{string,description,"Frequency"}  %read{1,1} %write{2147483647,-1} %derivs
param	point	Pref	0 0 0		%meta{string,description,"Reference pose (defaults to P)"}  %read{3,3} %write{0,0} %derivs %initexpr
param	string	shadingspace	"shader"		%meta{string,description,"Shading space"} %meta{string,UItype,"coordsys"}  %read{3,38} %write{2147483647,-1} %derivs
param	float	shadingfreq	1		%meta{string,description,"Shading frequency"}  %read{1,1} %write{2147483647,-1} %derivs
global	point	P	%read{0,48} %write{44,44} %derivs
global	normal	N	%read{33,33} %write{47,51} %derivs
local	vector	___261_dir	%read{36,42} %write{33,33} %derivs
local	vector	___261_Nresid	%read{47,51} %write{36,36} %derivs
local	float	___261_spacescale	%read{40,40} %write{39,39} %derivs
local	vector	___261_Ndisp	%read{44,48} %write{42,42} %derivs
local	float	___317_amp	%read{12,26} %write{8,26} %derivs
local	point	___317_pp	%read{12,26} %write{9,26} %derivs
local	float	___317_sum	%read{12,27} %write{10,26} %derivs
local	float	___317_fw	%read{12,26} %write{11,26} %derivs
local	float	___317_i	%read{12,26} %write{12,26}
local	point	Pshad	%read{5,9} %write{4,4} %derivs
local	float	dPshad	%read{11,11} %write{6,6} %derivs
local	float	amp	%read{28,30} %write{27,28} %derivs
temp	float	$tmp1	%read{4,4} %write{1,1} %derivs
temp	point	$tmp2	%read{4,4} %write{3,3} %derivs
const	string	$const1	"transform"		%read{2,37} %write{2147483647,-1}
const	string	$const2	"common"		%read{3,38} %write{2147483647,-1}
temp	float	$tmp3	%read{6,6} %write{5,5} %derivs
const	float	$const4	2		%read{23,24} %write{2147483647,-1}
const	float	$const5	0.5		%read{22,22} %write{2147483647,-1}
const	string	$const6	"fBm"		%read{7,7} %write{2147483647,-1}
const	int	$const7	1		%read{8,43} %write{2147483647,-1}
const	int	$const8	0		%read{10,13} %write{2147483647,-1}
temp	int	$tmp4	%read{12,26} %write{12,26}
temp	float	$tmp5	%read{20,20} %write{19,19} %derivs
const	string	$const9	"filteredsnoise"		%read{15,15} %write{2147483647,-1}
temp	float	$tmp6	%read{19,19} %write{16,16} %derivs
temp	float	$tmp7	%read{18,18} %write{17,17} %derivs
const	float	$const10	0.2		%read{17,17} %write{2147483647,-1}
const	float	$const11	0.75		%read{17,17} %write{2147483647,-1}
temp	float	$tmp8	%read{19,19} %write{18,18} %derivs
const	float	$const12	1		%read{18,26} %write{2147483647,-1}
temp	float	$tmp9	%read{21,21} %write{20,20} %derivs
temp	point	$tmp10	%read{25,25} %write{24,24} %derivs
temp	float	$tmp11	%read{30,30} %write{29,29} %derivs
temp	float	$tmp12	%read{41,41} %write{30,30} %derivs
const	string	$const13	"displace"		%read{31,32} %write{2147483647,-1}
temp	vector	$tmp13	%read{36,36} %write{35,35} %derivs
temp	vector	$tmp14	%read{35,35} %write{34,34} %derivs
temp	vector	$tmp15	%read{39,39} %write{38,38} %derivs
temp	float	$tmp16	%read{41,41} %write{40,40} %derivs
const	float	$const14	1e-006		%read{40,40} %write{2147483647,-1}
temp	float	$tmp17	%read{42,42} %write{41,41} %derivs
temp	vector	$tmp18	%read{47,47} %write{46,46} %derivs
temp	vector	$tmp19	%read{46,46} %write{45,45} %derivs
temp	vector	$tmp20	%read{51,51} %write{50,50} %derivs
temp	vector	$tmp21	%read{50,50} %write{49,49} %derivs
temp	point	$tmp22	%read{49,49} %write{48,48} %derivs
code Pref
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:68
#     string shadingspace = "shader"
	assign		Pref P 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl"} %line{68} %argrw{"wr"}
code ___main___
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:76
#     float dPshad = sqrt(area(Pshad));
	mul		$tmp1 freq shadingfreq 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl"} %line{76} %argrw{"wrr"}
	functioncall	$const1 4 	%argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:249
# // Vector functions
	transform	$tmp2 $const2 shadingspace Pref 	%filename{"D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h"} %line{249} %argrw{"wrrr"}
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:76
#     float dPshad = sqrt(area(Pshad));
	mul		Pshad $tmp1 $tmp2 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl"} %line{76} %argrw{"wrr"}
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:77
# 
	area		$tmp3 Pshad 	%line{77} %argrw{"wr"} %argderivs{1}
	sqrt		dPshad $tmp3 	%argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:79
#     amp = pow (amp, sharp);
	functioncall	$const6 28 	%line{79} %argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:98
# // * Neither the name of NVIDIA nor the names of its contributors
	assign		___317_amp $const7 	%filename{"D:/xrt.git\\src\\osl\\shaders\\noises.h"} %line{98} %argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:99
# //   may be used to endorse or promote products derived from this software
	assign		___317_pp Pshad 	%line{99} %argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:100
# //   without specific prior written permission.
	assign		___317_sum $const8 	%line{100} %argrw{"wr"}
	assign		___317_fw dPshad 	%argrw{"wr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:103
# // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
	for		$tmp4 14 15 26 27 	%line{103} %argrw{"r"}
	assign		___317_i $const8 	%argrw{"wr"}
	lt		$tmp4 ___317_i octaves 	%argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:104
# // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
	functioncall	$const9 20 	%line{104} %argrw{"r"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:62
#     return snoise(p) * (1-smoothstep (FILTLOW,FILTHIGH,width));
	snoise		$tmp6 ___317_pp 	%line{62} %argrw{"wr"}
	smoothstep	$tmp7 $const10 $const11 ___317_fw 	%argrw{"wrrr"}
	sub		$tmp8 $const12 $tmp7 	%argrw{"wrr"}
	mul		$tmp5 $tmp6 $tmp8 	%argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:104
# 	sum += amp * filteredsnoise (pp, fw);
	mul		$tmp9 ___317_amp $tmp5 	%line{104} %argrw{"wrr"}
	add		___317_sum ___317_sum $tmp9 	%argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:105
# 	amp *= gain;  fw *= lacunarity;
	mul		___317_amp ___317_amp $const5 	%line{105} %argrw{"wrr"}
	mul		___317_fw ___317_fw $const4 	%argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:106
#         pp = pp * lacunarity + 1;  // multiply and offset
	mul		$tmp10 ___317_pp $const4 	%line{106} %argrw{"wrr"}
	add		___317_pp $tmp10 $const12 	%argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:103
#     for (i = 0;  i < octaves;  i += 1) {
	add		___317_i ___317_i $const12 	%line{103} %argrw{"wrr"}
# D:/xrt.git\\src\\osl\\shaders\\noises.h:108
#     return sum;
	assign		amp ___317_sum 	%line{108} %argrw{"wr"}
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:80
#     displace (shadingspace, -Km*amp);
	pow		amp amp sharp 	%filename{"D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl"} %line{80} %argrw{"wrr"}
# D:\\xrt.git\\src\\osl\\shaders\\lumpy.osl:81
# }
	neg		$tmp11 Km 	%line{81} %argrw{"wr"}
	mul		$tmp12 $tmp11 amp 	%argrw{"wrr"}
	functioncall	$const13 52 	%argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:463
#             s = (v - min) / v;
	functioncall	$const13 52 	%filename{"D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h"} %line{463} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:449
#     vector dir = normalize(N);
	normalize	___261_dir N 	%line{449} %argrw{"wr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:451
#     vector Nresid = dir - normalize(calculatenormal (P));
	calculatenormal	$tmp14 P 	%line{451} %argrw{"wr"} %argderivs{1}
	normalize	$tmp13 $tmp14 	%argrw{"wr"}
	sub		___261_Nresid ___261_dir $tmp13 	%argrw{"wrr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:452
#     float spacescale = length(transform(space, dir));
	functioncall	$const1 39 	%line{452} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:248
# vector transform (string to, vector p) { return transform("common",to,p); }
	transformv	$tmp15 $const2 shadingspace ___261_dir 	%line{248} %argrw{"wrrr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:452
#     float spacescale = length(transform(space, dir));
	length		___261_spacescale $tmp15 	%line{452} %argrw{"wr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:453
#     vector Ndisp = dir * (amp / max(spacescale,1e-6));
	max		$tmp16 ___261_spacescale $const14 	%line{453} %argrw{"wrr"}
	div		$tmp17 $tmp12 $tmp16 	%argrw{"wrr"}
	mul		___261_Ndisp ___261_dir $tmp17 	%argrw{"wrr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:454
# 	if (truedisp) {
	if		$const7 48 52 	%line{454} %argrw{"r"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:455
# 		P += Ndisp;
	add		P P ___261_Ndisp 	%line{455} %argrw{"wrr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:456
# 		N = Nresid + normalize (calculatenormal (P));
	calculatenormal	$tmp19 P 	%line{456} %argrw{"wr"} %argderivs{1}
	normalize	$tmp18 $tmp19 	%argrw{"wr"}
	add		N ___261_Nresid $tmp18 	%argrw{"wrr"}
# D:/xrt.git\\build\\vc10\\Win32\\Release\\shaders\\stdosl.h:458
# 	    N = Nresid + normalize (calculatenormal (P + Ndisp));
	add		$tmp22 P ___261_Ndisp 	%line{458} %argrw{"wrr"}
	calculatenormal	$tmp21 $tmp22 	%argrw{"wr"} %argderivs{1}
	normalize	$tmp20 $tmp21 	%argrw{"wr"}
	add		N ___261_Nresid $tmp20 	%argrw{"wrr"}
	end
