Always display all 4 components of output from shader in pixel history

* This means the alpha that was output (and maybe used for blending) is
  displayed even when the target texture doesn't have an alpha component.
This commit is contained in:
baldurk
2018-11-02 11:02:26 +00:00
parent 6e3eef5fca
commit ad4bc8911e
+5 -2
View File
@@ -300,7 +300,7 @@ public:
return tr("No Pixel\nShader\nBound");
if(mod.directShaderWrite)
return tr("Tex Before\n\n") + modString(mod.preMod);
return tr("Shader Out\n\n") + modString(mod.shaderOut);
return tr("Shader Out\n\n") + modString(mod.shaderOut, 4);
}
}
@@ -485,12 +485,15 @@ private:
return QBrush(QColor::fromRgb((int)(255.0f * r), (int)(255.0f * g), (int)(255.0f * b)));
}
QString modString(const ModificationValue &val) const
QString modString(const ModificationValue &val, int forceComps = 0) const
{
QString s;
int numComps = (int)(m_Tex->format.compCount);
if(forceComps > 0)
numComps = forceComps;
static const QString colourLetterPrefix[] = {lit("R: "), lit("G: "), lit("B: "), lit("A: ")};
if(!m_IsDepth)