INDX INDEX_SECTION Ib¾üVop/BRDF_Functions Ib¾üBRDF_FunctionsBRDF Functions,oplib:/Vop/BRDF_Functions?Vop/BRDF_FunctionsVOP_BRDF_FunctionsVopIb¾üINDX DialogScriptãIb¾ü CreateScriptã"Ib¾üTypePropertiesOptionsìIb¾üHelpñØIb¾ü Tools.shelf ÉwIb¾üExtraFileOptions@Ib¾ü# Dialog script for BRDF_Functions automatically generated 01/05/09 21:16:28 { name BRDF_Functions script BRDF_Functions label "BRDF Functions" code { "vector $If = $isconnected_I ? $I : I;" "vector $Nf = $isconnected_N ? $N : N;" "vector $Lf = $isconnected_L ? $L : L;" "" "#if !strcmp($brdfType, \"simpleDiffuseBRDF\")" "$brdf = diffuseBRDF(normalize($Lf), normalize($Nf));" "#else" "$brdf = $brdfType(normalize($Lf), normalize($Nf), normalize(-$If), $rough);" "#endif" } input vector I "Direction from Eye to Surface" input vector N "Surface Normal" input vector L "Direction from Surface to Light" input float rough Rough input string brdfType "BRDF Type" output float brdf BRDF signature "Default Inputs" default { } help { "" } parm { name "brdfType" label "BRDF Type" type ordinal default { "diffuseBRDF" } menu { "simpleDiffuseBRDF" "Diffuse" "diffuseBRDF" "Oren-Nayer Diffuse" "specularBRDF" "Specular" "blinnBRDF" "Blinn" "phongBRDF" "Phong" } range { 0 1 } export none } parm { name "rough" label "Rough" type float default { "0.1" } disablewhen "{ brdfType == simpleDiffuseBRDF }" range { 0 50 } export none } } # Automatically generated script: Monday January 05, 21:16 \set noalias = 1 # # Creation script for BRDF_Functions operator # if ( "$arg1" == "" ) then echo This script is intended as a creation script exit endif # Node $arg1 (Vop/BRDF_Functions) opexprlanguage -s hscript $arg1 ParmsFromVfl := 0; PrefixDroppedParmName := 1; UseDSParms := 1; ForbidOutsideParms := 1; LockContents := 1; SaveSpareParms := 0; CheckExternal := 1; GzipContents := 1; MakeDefault := 1; PrefixDroppedParmLabel := 1; UnlockOnCreate := 0; = Illuminance Loop Tool: BRDF Functions = #type: node #context: vop #internal: BRDFs #icon: chop/transform """ The BRDF Functions VOP is used to access VEX-only bi-directional reflectance functions for use in illuminance loops to extract this information for each light. """ TIP: Select the function you want from the list to get the BRDF float value for that function. @parameters == Parameters == Parameters for BRDF Functions VOP. BRDF Type: The BRDF types are: 1) Diffuse (Simple) which is the VEX diffuse function which does not use the "L" or "rough" parameters and equivalent to clamp(dot(L, N), 0, 1). 2) Diffuse which does use the "L" or "rough" parameters. 3) Specular 4) Blinn 5) Phong Roughness: Defines the amount of roughness of the surface. Defaults to 0.1 which is a good starting range for everything but Phong which works better at 10 and up. @inputs N Input: Input a surface normal vector. This paramter is normalized by the VOP. If nothing is connected to it, the glabal variable will be used. L Input: Input a direction from the surface to the light as a vector. This paramter is normalized by the VOP. If nothing is connected to it, the glabal variable will be used. I Input: Input a direction from the eye of the camera to the surface as a vector. This is used in the BRDFs as the normalized negative of I. If nothing is connected to it, the glabal variable will be used. @related - [Node:vop/illuminance] VOP VOP $HDA_TABLE/$HDA_NAME Digital Assets