1818
1919#include < SkCamera.h>
2020
21+ #include < private/hwui/DrawGlInfo.h>
22+
2123#include " DisplayListLogBuffer.h"
2224#include " DisplayListRenderer.h"
2325#include " Caches.h"
@@ -796,9 +798,9 @@ void DisplayList::transformRect(float left, float top, float right, float bottom
796798 * in the output() function, since that function processes the same list of opcodes for the
797799 * purposes of logging display list info for a given view.
798800 */
799- bool DisplayList::replay (OpenGLRenderer& renderer, uint32_t width,
801+ status_t DisplayList::replay (OpenGLRenderer& renderer, uint32_t width,
800802 uint32_t height, Rect& dirty, int32_t flags, uint32_t level) {
801- bool needsInvalidate = false ;
803+ status_t drawGlStatus = 0 ;
802804 TextContainer text;
803805 mReader .rewind ();
804806
@@ -843,7 +845,7 @@ bool DisplayList::replay(OpenGLRenderer& renderer, uint32_t width,
843845 Functor *functor = (Functor *) getInt ();
844846 DISPLAY_LIST_LOGD (" %s%s %p" , (char *) indent, OP_NAMES[op], functor);
845847 renderer.startMark (" GL functor" );
846- needsInvalidate |= renderer.callDrawGLFunction (functor, dirty);
848+ drawGlStatus |= renderer.callDrawGLFunction (functor, dirty);
847849 renderer.endMark ();
848850 }
849851 break ;
@@ -950,7 +952,7 @@ bool DisplayList::replay(OpenGLRenderer& renderer, uint32_t width,
950952 int32_t flags = getInt ();
951953 DISPLAY_LIST_LOGD (" %s%s %p, %dx%d, 0x%x %d" , (char *) indent, OP_NAMES[op],
952954 displayList, width, height, flags, level + 1 );
953- needsInvalidate |= renderer.drawDisplayList (displayList, width,
955+ drawGlStatus |= renderer.drawDisplayList (displayList, width,
954956 height, dirty, flags, level + 1 );
955957 }
956958 break ;
@@ -1233,8 +1235,8 @@ bool DisplayList::replay(OpenGLRenderer& renderer, uint32_t width,
12331235 renderer.endMark ();
12341236
12351237 DISPLAY_LIST_LOGD (" %sDone (%p, %s), returning %d" , (char *) indent + 2 , this , mName .string (),
1236- needsInvalidate );
1237- return needsInvalidate ;
1238+ drawGlStatus );
1239+ return drawGlStatus ;
12381240}
12391241
12401242// /////////////////////////////////////////////////////////////////////////////
@@ -1321,11 +1323,11 @@ void DisplayListRenderer::interrupt() {
13211323void DisplayListRenderer::resume () {
13221324}
13231325
1324- bool DisplayListRenderer::callDrawGLFunction (Functor *functor, Rect& dirty) {
1326+ status_t DisplayListRenderer::callDrawGLFunction (Functor *functor, Rect& dirty) {
13251327 // Ignore dirty during recording, it matters only when we replay
13261328 addOp (DisplayList::DrawGLFunction);
13271329 addInt ((int ) functor);
1328- return false ; // No invalidate needed at record-time
1330+ return DrawGlInfo:: kStatusDone ; // No invalidate needed at record-time
13291331}
13301332
13311333int DisplayListRenderer::save (int flags) {
@@ -1415,7 +1417,7 @@ bool DisplayListRenderer::clipRect(float left, float top, float right, float bot
14151417 return OpenGLRenderer::clipRect (left, top, right, bottom, op);
14161418}
14171419
1418- bool DisplayListRenderer::drawDisplayList (DisplayList* displayList,
1420+ status_t DisplayListRenderer::drawDisplayList (DisplayList* displayList,
14191421 uint32_t width, uint32_t height, Rect& dirty, int32_t flags, uint32_t level) {
14201422 // dirty is an out parameter and should not be recorded,
14211423 // it matters only when replaying the display list
@@ -1437,7 +1439,7 @@ bool DisplayListRenderer::drawDisplayList(DisplayList* displayList,
14371439 addSize (width, height);
14381440 addInt (flags);
14391441 addSkip (location);
1440- return false ;
1442+ return DrawGlInfo:: kStatusDone ;
14411443}
14421444
14431445void DisplayListRenderer::drawLayer (Layer* layer, float x, float y, SkPaint* paint) {
0 commit comments