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

Unified Diff: gpu/ipc/service/direct_composition_surface_win.h

Issue 2735853002: Offset scissor and viewport when using SetDrawRectangle on surface. (Closed)
Patch Set: remove flag Created 3 years, 9 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
Index: gpu/ipc/service/direct_composition_surface_win.h
diff --git a/gpu/ipc/service/direct_composition_surface_win.h b/gpu/ipc/service/direct_composition_surface_win.h
index 831bbe938b5d247775b208087d68469d3b91a93f..28fbc76dbc9950c3a4cec2c6d37cc211cd4e5a4d 100644
--- a/gpu/ipc/service/direct_composition_surface_win.h
+++ b/gpu/ipc/service/direct_composition_surface_win.h
@@ -50,6 +50,7 @@ class GPU_EXPORT DirectCompositionSurfaceWin : public gl::GLSurfaceEGL {
bool OnMakeCurrent(gl::GLContext* context) override;
bool SupportsSetDrawRectangle() const override;
bool SetDrawRectangle(const gfx::Rect& rect) override;
+ gfx::Vector2d GetDrawOffset() const override;
bool Initialize(std::unique_ptr<gfx::VSyncProvider> vsync_provider);
@@ -95,6 +96,8 @@ class GPU_EXPORT DirectCompositionSurfaceWin : public gl::GLSurfaceEGL {
std::unique_ptr<gfx::VSyncProvider> vsync_provider_;
std::vector<Overlay> pending_overlays_;
+ gfx::Vector2d draw_offset_;
+
base::win::ScopedComPtr<ID3D11Device> d3d11_device_;
base::win::ScopedComPtr<IDCompositionDevice2> dcomp_device_;
base::win::ScopedComPtr<IDCompositionTarget> dcomp_target_;

Powered by Google App Engine
This is Rietveld 408576698