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

Side by Side Diff: include/core/SkBitmap.h

Issue 163603003: add peekPixels to SkCanvas and SkSurface (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: 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 | Annotate | Revision Log
« no previous file with comments | « gyp/gmslides.gypi ('k') | include/core/SkBitmapDevice.h » ('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 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
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 #ifndef SkBitmap_DEFINED 8 #ifndef SkBitmap_DEFINED
9 #define SkBitmap_DEFINED 9 #define SkBitmap_DEFINED
10 10
(...skipping 879 matching lines...) Expand 10 before | Expand all | Expand 10 after
890 } 890 }
891 891
892 inline SkPMColor SkBitmap::getIndex8Color(int x, int y) const { 892 inline SkPMColor SkBitmap::getIndex8Color(int x, int y) const {
893 SkASSERT(fPixels); 893 SkASSERT(fPixels);
894 SkASSERT(this->config() == kIndex8_Config); 894 SkASSERT(this->config() == kIndex8_Config);
895 SkASSERT((unsigned)x < (unsigned)this->width() && (unsigned)y < (unsigned)th is->height()); 895 SkASSERT((unsigned)x < (unsigned)this->width() && (unsigned)y < (unsigned)th is->height());
896 SkASSERT(fColorTable); 896 SkASSERT(fColorTable);
897 return (*fColorTable)[*((const uint8_t*)fPixels + y * fRowBytes + x)]; 897 return (*fColorTable)[*((const uint8_t*)fPixels + y * fRowBytes + x)];
898 } 898 }
899 899
900 ///////////////////////////////////////////////////////////////////////////////
901 //
902 // Helpers until we can fully deprecate SkBitmap::Config
903 //
904 extern SkBitmap::Config SkColorTypeToBitmapConfig(SkColorType);
905 extern SkColorType SkBitmapConfigToColorType(SkBitmap::Config);
906
900 #endif 907 #endif
OLDNEW
« no previous file with comments | « gyp/gmslides.gypi ('k') | include/core/SkBitmapDevice.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698