summaryrefslogtreecommitdiffstats
path: root/libs/hwui/LayerRenderer.h
diff options
context:
space:
mode:
Diffstat (limited to 'libs/hwui/LayerRenderer.h')
-rw-r--r--libs/hwui/LayerRenderer.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/libs/hwui/LayerRenderer.h b/libs/hwui/LayerRenderer.h
index be68412..ed5d960 100644
--- a/libs/hwui/LayerRenderer.h
+++ b/libs/hwui/LayerRenderer.h
@@ -18,6 +18,7 @@
#define ANDROID_HWUI_LAYER_RENDERER_H
#include "OpenGLRenderer.h"
+#include "Layer.h"
namespace android {
namespace uirenderer {
@@ -39,7 +40,7 @@ namespace uirenderer {
class LayerRenderer: public OpenGLRenderer {
public:
- LayerRenderer(GLuint fbo): mFbo(fbo) {
+ LayerRenderer(Layer* layer): mLayer(layer) {
}
~LayerRenderer() {
@@ -48,15 +49,13 @@ public:
void prepare(bool opaque);
void finish();
- static GLuint createLayer(uint32_t width, uint32_t height,
- uint32_t* layerWidth, uint32_t* layerHeight, GLuint* texture);
- static void resizeLayer(GLuint fbo, GLuint texture, uint32_t width, uint32_t height,
- uint32_t* layerWidth, uint32_t* layerHeight);
- static void destroyLayer(GLuint fbo, GLuint texture);
- static void destroyLayerDeferred(GLuint fbo, GLuint texture);
+ static Layer* createLayer(uint32_t width, uint32_t height, bool isOpaque = false);
+ static bool resizeLayer(Layer* layer, uint32_t width, uint32_t height);
+ static void destroyLayer(Layer* layer);
+ static void destroyLayerDeferred(Layer* layer);
private:
- GLuint mFbo;
+ Layer* mLayer;
GLuint mPreviousFbo;
}; // class LayerRenderer