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

Side by Side Diff: samplecode/SampleApp.cpp

Issue 1814533003: Revert of sRGB support in Ganesh. Several pieces: (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « include/gpu/SkGr.h ('k') | src/core/SkImageCacherator.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SampleApp.h" 8 #include "SampleApp.h"
9 9
10 #include "OverView.h" 10 #include "OverView.h"
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 if (fCurContext) { 303 if (fCurContext) {
304 // in case we have queued drawing calls 304 // in case we have queued drawing calls
305 fCurContext->flush(); 305 fCurContext->flush();
306 306
307 if (!IsGpuDeviceType(dType)) { 307 if (!IsGpuDeviceType(dType)) {
308 // need to send the raster bits to the (gpu) window 308 // need to send the raster bits to the (gpu) window
309 const SkBitmap& bm = win->getBitmap(); 309 const SkBitmap& bm = win->getBitmap();
310 fCurRenderTarget->writePixels(0, 0, bm.width(), bm.height(), 310 fCurRenderTarget->writePixels(0, 0, bm.width(), bm.height(),
311 SkImageInfo2GrPixelConfig(bm.colorT ype(), 311 SkImageInfo2GrPixelConfig(bm.colorT ype(),
312 bm.alphaT ype(), 312 bm.alphaT ype(),
313 bm.profil eType(), 313 bm.profil eType()),
314 *fCurCont ext->caps()),
315 bm.getPixels(), 314 bm.getPixels(),
316 bm.rowBytes(), 315 bm.rowBytes(),
317 GrContext::kFlushWrites_PixelOp); 316 GrContext::kFlushWrites_PixelOp);
318 } 317 }
319 } 318 }
320 #endif 319 #endif
321 320
322 win->present(); 321 win->present();
323 } 322 }
324 323
(...skipping 2005 matching lines...) Expand 10 before | Expand all | Expand 10 after
2330 #ifdef SK_BUILD_FOR_MAC 2329 #ifdef SK_BUILD_FOR_MAC
2331 setenv("ANDROID_ROOT", "/android/device/data", 0); 2330 setenv("ANDROID_ROOT", "/android/device/data", 0);
2332 #endif 2331 #endif
2333 SkGraphics::Init(); 2332 SkGraphics::Init();
2334 SkEvent::Init(); 2333 SkEvent::Init();
2335 } 2334 }
2336 2335
2337 void application_term() { 2336 void application_term() {
2338 SkEvent::Term(); 2337 SkEvent::Term();
2339 } 2338 }
OLDNEW
« no previous file with comments | « include/gpu/SkGr.h ('k') | src/core/SkImageCacherator.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698