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

Side by Side Diff: cc/output/gl_renderer.cc

Issue 334133002: cc: Support on demand raster with ganesh (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review3 Created 6 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « cc/output/direct_renderer.cc ('k') | cc/output/overlay_unittest.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 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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 #include "cc/output/gl_renderer.h" 5 #include "cc/output/gl_renderer.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 1889 matching lines...) Expand 10 before | Expand all | Expand 10 after
1900 ResourceProvider::TextureUsageAny, 1900 ResourceProvider::TextureUsageAny,
1901 quad->texture_format); 1901 quad->texture_format);
1902 } 1902 }
1903 1903
1904 // Create and run on-demand raster task for tile. 1904 // Create and run on-demand raster task for tile.
1905 scoped_refptr<Task> on_demand_raster_task( 1905 scoped_refptr<Task> on_demand_raster_task(
1906 new OnDemandRasterTaskImpl(quad->picture_pile, 1906 new OnDemandRasterTaskImpl(quad->picture_pile,
1907 &on_demand_tile_raster_bitmap_, 1907 &on_demand_tile_raster_bitmap_,
1908 quad->content_rect, 1908 quad->content_rect,
1909 quad->contents_scale)); 1909 quad->contents_scale));
1910 RunOnDemandRasterTask(on_demand_raster_task.get()); 1910 client_->RunOnDemandRasterTask(on_demand_raster_task.get());
1911 1911
1912 uint8_t* bitmap_pixels = NULL; 1912 uint8_t* bitmap_pixels = NULL;
1913 SkBitmap on_demand_tile_raster_bitmap_dest; 1913 SkBitmap on_demand_tile_raster_bitmap_dest;
1914 SkColorType colorType = ResourceFormatToSkColorType(quad->texture_format); 1914 SkColorType colorType = ResourceFormatToSkColorType(quad->texture_format);
1915 if (on_demand_tile_raster_bitmap_.colorType() != colorType) { 1915 if (on_demand_tile_raster_bitmap_.colorType() != colorType) {
1916 on_demand_tile_raster_bitmap_.copyTo(&on_demand_tile_raster_bitmap_dest, 1916 on_demand_tile_raster_bitmap_.copyTo(&on_demand_tile_raster_bitmap_dest,
1917 colorType); 1917 colorType);
1918 // TODO(kaanb): The GL pipeline assumes a 4-byte alignment for the 1918 // TODO(kaanb): The GL pipeline assumes a 4-byte alignment for the
1919 // bitmap data. This check will be removed once crbug.com/293728 is fixed. 1919 // bitmap data. This check will be removed once crbug.com/293728 is fixed.
1920 CHECK_EQ(0u, on_demand_tile_raster_bitmap_dest.rowBytes() % 4); 1920 CHECK_EQ(0u, on_demand_tile_raster_bitmap_dest.rowBytes() % 4);
(...skipping 1259 matching lines...) Expand 10 before | Expand all | Expand 10 after
3180 context_support_->ScheduleOverlayPlane( 3180 context_support_->ScheduleOverlayPlane(
3181 overlay.plane_z_order, 3181 overlay.plane_z_order,
3182 overlay.transform, 3182 overlay.transform,
3183 pending_overlay_resources_.back()->texture_id(), 3183 pending_overlay_resources_.back()->texture_id(),
3184 overlay.display_rect, 3184 overlay.display_rect,
3185 overlay.uv_rect); 3185 overlay.uv_rect);
3186 } 3186 }
3187 } 3187 }
3188 3188
3189 } // namespace cc 3189 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/direct_renderer.cc ('k') | cc/output/overlay_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698