accleratedjob: simplified function calls

This commit is contained in:
itsmattkc
2022-05-09 15:16:46 -07:00
parent 6c7dbc8521
commit b88e15b8cf
33 changed files with 149 additions and 149 deletions
+3 -3
View File
@@ -82,16 +82,16 @@ ShaderCode DespillNode::GetShaderCode(const ShaderRequest &request) const {
void DespillNode::Value(const NodeValueRow &value, const NodeGlobals &globals, NodeValueTable *table) const {
ShaderJob job;
job.InsertValue(value);
job.Insert(value);
// Set luma coefficients
double luma_coeffs[3] = {0.0f, 0.0f, 0.0f};
project()->color_manager()->GetDefaultLumaCoefs(luma_coeffs);
job.InsertValue(QStringLiteral("luma_coeffs"),
job.Insert(QStringLiteral("luma_coeffs"),
NodeValue(NodeValue::kVec3, QVector3D(luma_coeffs[0], luma_coeffs[1], luma_coeffs[2])));
// If there's no texture, no need to run an operation
if (job.GetValue(kTextureInput).toTexture()) {
if (job.Get(kTextureInput).toTexture()) {
table->Push(NodeValue::kTexture, QVariant::fromValue(job), this);
}
}