Remove unused GrFPArgs::fInputColorIsOpaque
Change-Id: I0bd34550c762e5d0f88cf7e3e44cbf38d2a8a7ba Reviewed-on: https://skia-review.googlesource.com/c/skia/+/469057 Reviewed-by: Michael Ludwig <michaelludwig@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
This commit is contained in:
parent
4a41c9401e
commit
864f71b3ac
@ -981,18 +981,13 @@ public:
|
||||
get_xformed_uniforms(fEffect.get(), fUniforms, args.fDstColorInfo->colorSpace());
|
||||
SkASSERT(uniforms);
|
||||
|
||||
// If we sample children with explicit colors, this may not be true.
|
||||
// TODO: Determine this via analysis?
|
||||
GrFPArgs childArgs = args;
|
||||
childArgs.fInputColorIsOpaque = false;
|
||||
|
||||
auto [success, fp] = make_effect_fp(fEffect,
|
||||
"runtime_shader",
|
||||
std::move(uniforms),
|
||||
/*inputFP=*/nullptr,
|
||||
/*destColorFP=*/nullptr,
|
||||
SkMakeSpan(fChildren),
|
||||
childArgs);
|
||||
args);
|
||||
if (!success) {
|
||||
return nullptr;
|
||||
}
|
||||
|
@ -28,7 +28,6 @@ struct GrFPArgs {
|
||||
|
||||
GrFPArgs withNewMatrixProvider(const SkMatrixProvider& provider) const {
|
||||
GrFPArgs newArgs(fContext, provider, fDstColorInfo);
|
||||
newArgs.fInputColorIsOpaque = fInputColorIsOpaque;
|
||||
newArgs.fPreLocalMatrix = fPreLocalMatrix;
|
||||
return newArgs;
|
||||
}
|
||||
@ -38,9 +37,6 @@ struct GrFPArgs {
|
||||
|
||||
const SkMatrix* fPreLocalMatrix = nullptr;
|
||||
|
||||
// Make this SkAlphaType?
|
||||
bool fInputColorIsOpaque = false;
|
||||
|
||||
const GrColorInfo* fDstColorInfo;
|
||||
};
|
||||
|
||||
|
@ -427,7 +427,6 @@ static inline bool skpaint_to_grpaint_impl(GrRecordingContext* context,
|
||||
// of per-vertex colors.
|
||||
std::unique_ptr<GrFragmentProcessor> paintFP;
|
||||
if (!primColorMode || blend_requires_shader(*primColorMode)) {
|
||||
fpArgs.fInputColorIsOpaque = origColor.isOpaque();
|
||||
if (shaderProcessor) {
|
||||
paintFP = std::move(*shaderProcessor);
|
||||
} else {
|
||||
@ -532,8 +531,6 @@ static inline bool skpaint_to_grpaint_impl(GrRecordingContext* context,
|
||||
|
||||
SkMaskFilterBase* maskFilter = as_MFB(skPaint.getMaskFilter());
|
||||
if (maskFilter) {
|
||||
// We may have set this before passing to the SkShader.
|
||||
fpArgs.fInputColorIsOpaque = false;
|
||||
if (auto mfFP = maskFilter->asFragmentProcessor(fpArgs)) {
|
||||
grPaint->setCoverageFragmentProcessor(std::move(mfFP));
|
||||
}
|
||||
|
@ -166,7 +166,6 @@ skvm::Color SkShader_Blend::onProgram(skvm::Builder* p,
|
||||
std::unique_ptr<GrFragmentProcessor> SkShader_Blend::asFragmentProcessor(
|
||||
const GrFPArgs& orig_args) const {
|
||||
GrFPArgs::WithPreLocalMatrix args(orig_args, this->getLocalMatrix());
|
||||
args.fInputColorIsOpaque = true; // See use of MakeInputOpaqueAndPostApplyAlpha below
|
||||
auto fpA = as_SB(fDst)->asFragmentProcessor(args);
|
||||
auto fpB = as_SB(fSrc)->asFragmentProcessor(args);
|
||||
if (!fpA || !fpB) {
|
||||
|
Loading…
Reference in New Issue
Block a user