Commit ea706304 by Cody Northrop Committed by Commit Bot

Capture/Replay: Fixups for draw surface

Ran into these two problems while capturing gfxbench and trying to replay in the sample. Test: Capture and replay sample of gfxbench Bug: b/159238311 Change-Id: I1c873cbf2e297b5299581a7ffc2b1273e2d4c18a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2265287Reviewed-by: 's avatarManh Nguyen <nguyenmh@google.com> Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Cody Northrop <cnorthrop@google.com>
parent 259221d5
...@@ -928,6 +928,7 @@ void WriteCppReplayIndexFiles(bool compression, ...@@ -928,6 +928,7 @@ void WriteCppReplayIndexFiles(bool compression,
header << "#pragma once\n"; header << "#pragma once\n";
header << "\n"; header << "\n";
header << "#include \"util/gles_loader_autogen.h\"\n"; header << "#include \"util/gles_loader_autogen.h\"\n";
header << "#include \"util/egl_loader_autogen.h\"\n";
header << "\n"; header << "\n";
header << "#include <cstdint>\n"; header << "#include <cstdint>\n";
header << "#include <cstdio>\n"; header << "#include <cstdio>\n";
...@@ -3902,6 +3903,9 @@ void FrameCapture::onEndFrame(const gl::Context *context) ...@@ -3902,6 +3903,9 @@ void FrameCapture::onEndFrame(const gl::Context *context)
void FrameCapture::onMakeCurrent(const egl::Surface *drawSurface) void FrameCapture::onMakeCurrent(const egl::Surface *drawSurface)
{ {
if (!drawSurface)
return;
// Track the width and height of the draw surface as provided to makeCurrent // Track the width and height of the draw surface as provided to makeCurrent
// TODO (b/159238311): Track this per context. Right now last one wins. // TODO (b/159238311): Track this per context. Right now last one wins.
mDrawSurfaceWidth = drawSurface->getWidth(); mDrawSurfaceWidth = drawSurface->getWidth();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment