Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1453)

Unified Diff: content/renderer/pepper/ppb_graphics_3d_impl.h

Issue 2086363004: mac: Finish plumbing for Pepper3D Image Chromium. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@temp98_native_gmb
Patch Set: Rebase error. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/common/content_switches.cc ('k') | content/renderer/pepper/ppb_graphics_3d_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/pepper/ppb_graphics_3d_impl.h
diff --git a/content/renderer/pepper/ppb_graphics_3d_impl.h b/content/renderer/pepper/ppb_graphics_3d_impl.h
index abafd2c4b14bd0eaf87ca780c0f5e42d315e0ad9..5d926ec110cc5ca0ba2b87d8259d0ca6cacd00c4 100644
--- a/content/renderer/pepper/ppb_graphics_3d_impl.h
+++ b/content/renderer/pepper/ppb_graphics_3d_impl.h
@@ -70,7 +70,9 @@ class PPB_Graphics3D_Impl : public ppapi::PPB_Graphics3D_Shared,
// ppapi::PPB_Graphics3D_Shared overrides.
gpu::CommandBuffer* GetCommandBuffer() override;
gpu::GpuControl* GetGpuControl() override;
- int32_t DoSwapBuffers(const gpu::SyncToken& sync_token) override;
+ int32_t DoSwapBuffers(const gpu::SyncToken& sync_token,
+ int32_t width,
+ int32_t height) override;
private:
explicit PPB_Graphics3D_Impl(PP_Instance instance);
@@ -110,7 +112,14 @@ class PPB_Graphics3D_Impl : public ppapi::PPB_Graphics3D_Shared,
bool lost_context_ = false;
#endif
+ // The width and height of the command buffer back buffer are first sized from
+ // this process, but then resized by the pepper process. Cache the original
+ // size.
+ int32_t original_width_ = 0;
+ int32_t original_height_ = 0;
+
bool has_alpha_;
+ bool use_image_chromium_;
std::unique_ptr<gpu::CommandBufferProxyImpl> command_buffer_;
base::WeakPtrFactory<PPB_Graphics3D_Impl> weak_ptr_factory_;
« no previous file with comments | « content/public/common/content_switches.cc ('k') | content/renderer/pepper/ppb_graphics_3d_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698