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
+4 -4
View File
@@ -47,16 +47,16 @@ void OpacityEffect::Value(const NodeValueRow &value, const NodeGlobals &globals,
{
ShaderJob job;
job.InsertValue(value);
job.Insert(value);
// If there's no texture, no need to run an operation
if (job.GetValue(kTextureInput).toTexture()) {
if (!qFuzzyCompare(job.GetValue(kValueInput).toDouble(), 1.0)) {
if (job.Get(kTextureInput).toTexture()) {
if (!qFuzzyCompare(job.Get(kValueInput).toDouble(), 1.0)) {
job.SetAlphaChannelRequired(GenerateJob::kAlphaForceOn);
table->Push(NodeValue::kTexture, QVariant::fromValue(job), this);
} else {
// 1.0 float is a no-op, so just push the texture
table->Push(job.GetValue(kTextureInput));
table->Push(job.Get(kTextureInput));
}
}
}