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

Side by Side Diff: cc/raster/raster_buffer_provider.h

Issue 2332143002: cc: Populate SkColorSpace for raster from resource gfx::ColorSpace (Closed)
Patch Set: Review feedback Created 4 years, 3 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/raster/one_copy_raster_buffer_provider.cc ('k') | cc/raster/raster_buffer_provider.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_RASTER_RASTER_BUFFER_PROVIDER_H_ 5 #ifndef CC_RASTER_RASTER_BUFFER_PROVIDER_H_
6 #define CC_RASTER_RASTER_BUFFER_PROVIDER_H_ 6 #define CC_RASTER_RASTER_BUFFER_PROVIDER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include "cc/playback/raster_source.h" 10 #include "cc/playback/raster_source.h"
(...skipping 24 matching lines...) Expand all
35 // already partially complete, and only the subrect needs to be played back. 35 // already partially complete, and only the subrect needs to be played back.
36 static void PlaybackToMemory( 36 static void PlaybackToMemory(
37 void* memory, 37 void* memory,
38 ResourceFormat format, 38 ResourceFormat format,
39 const gfx::Size& size, 39 const gfx::Size& size,
40 size_t stride, 40 size_t stride,
41 const RasterSource* raster_source, 41 const RasterSource* raster_source,
42 const gfx::Rect& canvas_bitmap_rect, 42 const gfx::Rect& canvas_bitmap_rect,
43 const gfx::Rect& canvas_playback_rect, 43 const gfx::Rect& canvas_playback_rect,
44 float scale, 44 float scale,
45 sk_sp<SkColorSpace> color_space,
45 const RasterSource::PlaybackSettings& playback_settings); 46 const RasterSource::PlaybackSettings& playback_settings);
46 47
47 // Acquire raster buffer. 48 // Acquire raster buffer.
48 virtual std::unique_ptr<RasterBuffer> AcquireBufferForRaster( 49 virtual std::unique_ptr<RasterBuffer> AcquireBufferForRaster(
49 const Resource* resource, 50 const Resource* resource,
50 uint64_t resource_content_id, 51 uint64_t resource_content_id,
51 uint64_t previous_content_id) = 0; 52 uint64_t previous_content_id) = 0;
52 53
53 // Release raster buffer. 54 // Release raster buffer.
54 virtual void ReleaseBufferForRaster(std::unique_ptr<RasterBuffer> buffer) = 0; 55 virtual void ReleaseBufferForRaster(std::unique_ptr<RasterBuffer> buffer) = 0;
(...skipping 15 matching lines...) Expand all
70 virtual void Shutdown() = 0; 71 virtual void Shutdown() = 0;
71 72
72 protected: 73 protected:
73 // Check if resource format matches output format. 74 // Check if resource format matches output format.
74 static bool ResourceFormatRequiresSwizzle(ResourceFormat format); 75 static bool ResourceFormatRequiresSwizzle(ResourceFormat format);
75 }; 76 };
76 77
77 } // namespace cc 78 } // namespace cc
78 79
79 #endif // CC_RASTER_RASTER_BUFFER_PROVIDER_H_ 80 #endif // CC_RASTER_RASTER_BUFFER_PROVIDER_H_
OLDNEW
« no previous file with comments | « cc/raster/one_copy_raster_buffer_provider.cc ('k') | cc/raster/raster_buffer_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698