| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006-2008 Google Inc. | 2 * Copyright (C) 2006-2008 Google Inc. |
| 3 * | 3 * |
| 4 * Licensed under the Apache License, Version 2.0 (the "License"); | 4 * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 * you may not use this file except in compliance with the License. | 5 * you may not use this file except in compliance with the License. |
| 6 * You may obtain a copy of the License at | 6 * You may obtain a copy of the License at |
| 7 * | 7 * |
| 8 * http://www.apache.org/licenses/LICENSE-2.0 | 8 * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 * | 9 * |
| 10 * Unless required by applicable law or agreed to in writing, software | 10 * Unless required by applicable law or agreed to in writing, software |
| 11 * distributed under the License is distributed on an "AS IS" BASIS, | 11 * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 * See the License for the specific language governing permissions and | 13 * See the License for the specific language governing permissions and |
| 14 * limitations under the License. | 14 * limitations under the License. |
| 15 */ | 15 */ |
| 16 | 16 |
| 17 #ifndef SkBitmap_DEFINED | 17 #ifndef SkBitmap_DEFINED |
| 18 #define SkBitmap_DEFINED | 18 #define SkBitmap_DEFINED |
| 19 | 19 |
| 20 #include "Sk64.h" | 20 #include "Sk64.h" |
| 21 #include "SkColor.h" | 21 #include "SkColor.h" |
| 22 #include "SkPoint.h" | 22 #include "SkPoint.h" |
| 23 #include "SkRefCnt.h" | 23 #include "SkRefCnt.h" |
| 24 | 24 |
| 25 #if defined(SK_BUILD_FOR_MAC) | 25 #if defined(SK_BUILD_FOR_MAC) |
| 26 #include <carbon/carbon.h> | 26 #include <Carbon/Carbon.h> |
| 27 #endif | 27 #endif |
| 28 | 28 |
| 29 struct SkIRect; | 29 struct SkIRect; |
| 30 class SkColorTable; | 30 class SkColorTable; |
| 31 class SkPaint; | 31 class SkPaint; |
| 32 class SkPixelRef; | 32 class SkPixelRef; |
| 33 class SkRegion; | 33 class SkRegion; |
| 34 class SkFlattenableReadBuffer; | 34 class SkFlattenableReadBuffer; |
| 35 class SkFlattenableWriteBuffer; | 35 class SkFlattenableWriteBuffer; |
| 36 | 36 |
| (...skipping 565 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 602 // returns the address of the byte that contains the x coordinate | 602 // returns the address of the byte that contains the x coordinate |
| 603 inline uint8_t* SkBitmap::getAddr1(int x, int y) const { | 603 inline uint8_t* SkBitmap::getAddr1(int x, int y) const { |
| 604 SkASSERT(fPixels); | 604 SkASSERT(fPixels); |
| 605 SkASSERT(fConfig == kA1_Config); | 605 SkASSERT(fConfig == kA1_Config); |
| 606 SkASSERT((unsigned)x < fWidth && (unsigned)y < fHeight); | 606 SkASSERT((unsigned)x < fWidth && (unsigned)y < fHeight); |
| 607 return (uint8_t*)fPixels + y * fRowBytes + (x >> 3); | 607 return (uint8_t*)fPixels + y * fRowBytes + (x >> 3); |
| 608 } | 608 } |
| 609 | 609 |
| 610 #endif | 610 #endif |
| 611 | 611 |
| OLD | NEW |