Check if glReadPixels caused a GL error in on device replay.
Check if glReadPixels caused a GL error in on device replay.

When doing ODR, we query the framebuffer format via the API. If there is
a GL error doing that, the values may be garbage. Guard against that by
checking the GL error and failing if there was an error reading the pixels
with a better error message.

Fixes #2873

google/agi,google/gapid,google/agi,pmuetschard/gapid,google/gapid,google/gapid,pmuetschard/gapid,google/agi,google/agi,google/gapid,pmuetschard/gapid,google/gapid,pmuetschard/gapid,pmuetschard/gapid,google/agi,google/agi,google/agi,google/agi,google/gapid,pmuetschard/gapid,google/gapid,google/gapid,pmuetschard/gapid,pmuetschard/gapid