Create a new RenderPipeline for CPU only rendering
This takes out of SkiaPipeline what relies on GPU, and puts it into
SkiaGpuPipeline, making SkiaOpenGLPipeline and SkiaVulkanPipeline
inherit from SkiaGpuPipeline.
From the new restricted SkiaPipeline, this creates SkiaCpuPipeline that
only relies on CPU for rendering.
In addition, this moves references to the GrContext out of
IRenderPipeline and into SkGpuPipeline as the only usage is in classes
inheriting from SkGpuPipeline.
Bug: 322360037
Test: build libhwui on host
Change-Id: Ifadacfc593ff54377d6a8a65b0505e294c8d1b29
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index 1fbd580..22de2f2 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -35,8 +35,8 @@
#include "Properties.h"
#include "RenderThread.h"
#include "hwui/Canvas.h"
+#include "pipeline/skia/SkiaGpuPipeline.h"
#include "pipeline/skia/SkiaOpenGLPipeline.h"
-#include "pipeline/skia/SkiaPipeline.h"
#include "pipeline/skia/SkiaVulkanPipeline.h"
#include "thread/CommonPool.h"
#include "utils/GLUtils.h"
@@ -108,7 +108,7 @@
}
void CanvasContext::prepareToDraw(const RenderThread& thread, Bitmap* bitmap) {
- skiapipeline::SkiaPipeline::prepareToDraw(thread, bitmap);
+ skiapipeline::SkiaGpuPipeline::prepareToDraw(thread, bitmap);
}
CanvasContext::CanvasContext(RenderThread& thread, bool translucent, RenderNode* rootRenderNode,