| OLD | NEW | 
|---|
| 1 | 1 | 
| 2 /* | 2 /* | 
| 3  * Copyright 2010 Google Inc. | 3  * Copyright 2010 Google Inc. | 
| 4  * | 4  * | 
| 5  * Use of this source code is governed by a BSD-style license that can be | 5  * Use of this source code is governed by a BSD-style license that can be | 
| 6  * found in the LICENSE file. | 6  * found in the LICENSE file. | 
| 7  */ | 7  */ | 
| 8 | 8 | 
| 9 #ifndef GrTypes_DEFINED | 9 #ifndef GrTypes_DEFINED | 
| 10 #define GrTypes_DEFINED | 10 #define GrTypes_DEFINED | 
| (...skipping 598 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 609             SkFAIL("Unknown compressed pixel config"); | 609             SkFAIL("Unknown compressed pixel config"); | 
| 610             return 4 * width * height; | 610             return 4 * width * height; | 
| 611     } | 611     } | 
| 612 } | 612 } | 
| 613 | 613 | 
| 614 /** | 614 /** | 
| 615  * This value translates to reseting all the context state for any backend. | 615  * This value translates to reseting all the context state for any backend. | 
| 616  */ | 616  */ | 
| 617 static const uint32_t kAll_GrBackendState = 0xffffffff; | 617 static const uint32_t kAll_GrBackendState = 0xffffffff; | 
| 618 | 618 | 
| 619 /////////////////////////////////////////////////////////////////////////////// |  | 
| 620 |  | 
| 621 #if GR_ALWAYS_ALLOCATE_ON_HEAP |  | 
| 622     #define GrAutoMallocBaseType SkAutoMalloc |  | 
| 623 #else |  | 
| 624     #define GrAutoMallocBaseType SkAutoSMalloc<S> |  | 
| 625 #endif | 619 #endif | 
| 626 |  | 
| 627 template <size_t S> class GrAutoMalloc : public GrAutoMallocBaseType { |  | 
| 628 public: |  | 
| 629     GrAutoMalloc() : INHERITED() {} |  | 
| 630     explicit GrAutoMalloc(size_t size) : INHERITED(size) {} |  | 
| 631     virtual ~GrAutoMalloc() {} |  | 
| 632 private: |  | 
| 633     typedef GrAutoMallocBaseType INHERITED; |  | 
| 634 }; |  | 
| 635 |  | 
| 636 #undef GrAutoMallocBaseType |  | 
| 637 #endif |  | 
| OLD | NEW | 
|---|