[skotty] Refactor paint opacity

Promote to a PaintNode attribute, drop color composite.

TBR=
Change-Id: Ia79d5f7e193a472d53ac4ff8beb7234d4dc26cef
Reviewed-on: https://skia-review.googlesource.com/94280
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
diff --git a/experimental/sksg/SkSGPaintNode.cpp b/experimental/sksg/SkSGPaintNode.cpp
index 146d248..bb5b714 100644
--- a/experimental/sksg/SkSGPaintNode.cpp
+++ b/experimental/sksg/SkSGPaintNode.cpp
@@ -31,6 +31,9 @@
 
     this->onApplyToPaint(&fPaint);
 
+    // Compose opacity on top of the subclass value.
+    fPaint.setAlpha(SkScalarRoundToInt(fPaint.getAlpha() * SkTPin<SkScalar>(fOpacity, 0, 1)));
+
     return SkRect::MakeEmpty();
 }