2019-12-12 22:25:40 +08:00
|
|
|
|
#include<hgl/graph/shader/node/node.h>
|
|
|
|
|
|
|
|
|
|
BEGIN_SHADER_NODE_NAMESPACE
|
2019-12-13 11:20:08 +08:00
|
|
|
|
bool Node::IsOutputParam(param::OutputParam *op)
|
|
|
|
|
{
|
|
|
|
|
if(!op)return(false);
|
|
|
|
|
|
|
|
|
|
return output_params.IsExist(op);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool Node::Check()
|
2019-12-12 22:25:40 +08:00
|
|
|
|
{
|
|
|
|
|
const int count=input_params.GetCount();
|
|
|
|
|
param::InputParam **ip=input_params.GetData();
|
|
|
|
|
|
|
|
|
|
for(int i=0;i<count;i++)
|
|
|
|
|
if(!(*ip)->Check())
|
|
|
|
|
return(false);
|
|
|
|
|
else
|
|
|
|
|
++ip;
|
|
|
|
|
|
|
|
|
|
return(true);
|
|
|
|
|
}
|
|
|
|
|
END_SHADER_NODE_NAMESPACE
|