forked from blender/blender
MaterialX: Implement export of Input nodes #20
@ -26,6 +26,14 @@ static int node_shader_gpu_fresnel(GPUMaterial *mat,
|
||||
return GPU_stack_link(mat, node, "node_fresnel", in, out);
|
||||
}
|
||||
|
||||
NODE_SHADER_MATERIALX_BEGIN
|
||||
{
|
||||
/* TODO: some outputs expected be implemented within the next iteration (see nodedef
|
||||
* <artistic_ior>) */
|
||||
return get_input_value("IOR", NodeItem::Type::Float);
|
||||
}
|
||||
NODE_SHADER_MATERIALX_END
|
||||
|
||||
} // namespace blender::nodes::node_shader_fresnel_cc
|
||||
|
||||
/* node type definition */
|
||||
@ -38,6 +46,7 @@ void register_node_type_sh_fresnel()
|
||||
sh_node_type_base(&ntype, SH_NODE_FRESNEL, "Fresnel", NODE_CLASS_INPUT);
|
||||
ntype.declare = file_ns::node_declare;
|
||||
ntype.gpu_fn = file_ns::node_shader_gpu_fresnel;
|
||||
ntype.materialx_fn = file_ns::node_shader_materialx;
|
||||
|
||||
nodeRegisterType(&ntype);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user