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

Side by Side Diff: cc/output/software_output_device.h

Issue 132163009: [#6]Pass gfx structs by const ref (gfx::Vector2d) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on TOT Created 6 years, 10 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 unified diff | Download patch
« no previous file with comments | « cc/output/direct_renderer.cc ('k') | cc/output/software_output_device.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_ 5 #ifndef CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_
6 #define CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_ 6 #define CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 // SkCanvas instance returned by |BeginPaint| and should discard any reference 48 // SkCanvas instance returned by |BeginPaint| and should discard any reference
49 // that it holds to it. 49 // that it holds to it.
50 virtual void EndPaint(SoftwareFrameData* frame_data); 50 virtual void EndPaint(SoftwareFrameData* frame_data);
51 51
52 // Copies pixels inside |rect| from the current software framebuffer to 52 // Copies pixels inside |rect| from the current software framebuffer to
53 // |output|. Fails if there is no current softwareframebuffer. 53 // |output|. Fails if there is no current softwareframebuffer.
54 virtual void CopyToBitmap(const gfx::Rect& rect, SkBitmap* output); 54 virtual void CopyToBitmap(const gfx::Rect& rect, SkBitmap* output);
55 55
56 // Blit the pixel content of the SoftwareOutputDevice by |delta| with the 56 // Blit the pixel content of the SoftwareOutputDevice by |delta| with the
57 // write clipped to |clip_rect|. 57 // write clipped to |clip_rect|.
58 virtual void Scroll(gfx::Vector2d delta, 58 virtual void Scroll(const gfx::Vector2d& delta, const gfx::Rect& clip_rect);
59 const gfx::Rect& clip_rect);
60 59
61 // Discard the backing buffer in the surface provided by this instance. 60 // Discard the backing buffer in the surface provided by this instance.
62 virtual void DiscardBackbuffer() {} 61 virtual void DiscardBackbuffer() {}
63 62
64 // Ensures that there is a backing buffer available on this instance. 63 // Ensures that there is a backing buffer available on this instance.
65 virtual void EnsureBackbuffer() {} 64 virtual void EnsureBackbuffer() {}
66 65
67 // TODO(skaslev) Remove this after UberCompositor lands. 66 // TODO(skaslev) Remove this after UberCompositor lands.
68 // Called in response to receiving a SwapBuffersAck. At this point, software 67 // Called in response to receiving a SwapBuffersAck. At this point, software
69 // frame identified by id can be reused or discarded as it is no longer being 68 // frame identified by id can be reused or discarded as it is no longer being
(...skipping 11 matching lines...) Expand all
81 skia::RefPtr<SkCanvas> canvas_; 80 skia::RefPtr<SkCanvas> canvas_;
82 scoped_ptr<gfx::VSyncProvider> vsync_provider_; 81 scoped_ptr<gfx::VSyncProvider> vsync_provider_;
83 82
84 private: 83 private:
85 DISALLOW_COPY_AND_ASSIGN(SoftwareOutputDevice); 84 DISALLOW_COPY_AND_ASSIGN(SoftwareOutputDevice);
86 }; 85 };
87 86
88 } // namespace cc 87 } // namespace cc
89 88
90 #endif // CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_ 89 #endif // CC_OUTPUT_SOFTWARE_OUTPUT_DEVICE_H_
OLDNEW
« no previous file with comments | « cc/output/direct_renderer.cc ('k') | cc/output/software_output_device.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698