BLAST: Avoid JNI call on creation

JNI calls aren't free and we don't need to burn one
to call update with the values we just passed in.

Bug: 152501005
Test: Existing tests pass
Change-Id: Iaf272edb03d4ec195b75e9ef7e6c122604025dcb
This commit is contained in:
Robert Carr
2020-04-22 16:24:34 -07:00
parent 082d0c47b7
commit ae8e0aea36

View File

@@ -1793,8 +1793,9 @@ public final class ViewRootImpl implements ViewParent,
// We only return the Surface the first time, as otherwise
// it hasn't changed and there is no need to update.
ret = mBlastBufferQueue.getSurface();
} else {
mBlastBufferQueue.update(mBlastSurfaceControl, width, height);
}
mBlastBufferQueue.update(mBlastSurfaceControl, width, height);
return ret;
}