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

Side by Side Diff: include/gpu/GrContext.h

Issue 2041113004: sk_sp for gpu. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Reserve correctly. Created 4 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
« no previous file with comments | « include/gpu/GrClip.h ('k') | include/gpu/GrFragmentProcessor.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 2010 Google Inc. 2 * Copyright 2010 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 #ifndef GrContext_DEFINED 8 #ifndef GrContext_DEFINED
9 #define GrContext_DEFINED 9 #define GrContext_DEFINED
10 10
(...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 bool init(GrBackend, GrBackendContext, const GrContextOptions& options); 450 bool init(GrBackend, GrBackendContext, const GrContextOptions& options);
451 451
452 void initMockContext(); 452 void initMockContext();
453 void initCommon(const GrContextOptions&); 453 void initCommon(const GrContextOptions&);
454 454
455 /** 455 /**
456 * These functions create premul <-> unpremul effects if it is possible to g enerate a pair 456 * These functions create premul <-> unpremul effects if it is possible to g enerate a pair
457 * of effects that make a readToUPM->writeToPM->readToUPM cycle invariant. O therwise, they 457 * of effects that make a readToUPM->writeToPM->readToUPM cycle invariant. O therwise, they
458 * return NULL. They also can perform a swizzle as part of the draw. 458 * return NULL. They also can perform a swizzle as part of the draw.
459 */ 459 */
460 const GrFragmentProcessor* createPMToUPMEffect(GrTexture*, const GrSwizzle&, 460 sk_sp<GrFragmentProcessor> createPMToUPMEffect(GrTexture*, const GrSwizzle&,
461 const SkMatrix&) const; 461 const SkMatrix&) const;
462 const GrFragmentProcessor* createUPMToPMEffect(GrTexture*, const GrSwizzle&, 462 sk_sp<GrFragmentProcessor> createUPMToPMEffect(GrTexture*, const GrSwizzle&,
463 const SkMatrix&) const; 463 const SkMatrix&) const;
464 /** Called before either of the above two functions to determine the appropr iate fragment 464 /** Called before either of the above two functions to determine the appropr iate fragment
465 processors for conversions. This must be called by readSurfacePixels bef ore a mutex is 465 processors for conversions. This must be called by readSurfacePixels bef ore a mutex is
466 taken, since testingvPM conversions itself will call readSurfacePixels * / 466 taken, since testingvPM conversions itself will call readSurfacePixels * /
467 void testPMConversionsIfNecessary(uint32_t flags); 467 void testPMConversionsIfNecessary(uint32_t flags);
468 /** Returns true if we've already determined that createPMtoUPMEffect and cr eateUPMToPMEffect 468 /** Returns true if we've already determined that createPMtoUPMEffect and cr eateUPMToPMEffect
469 will fail. In such cases fall back to SW conversion. */ 469 will fail. In such cases fall back to SW conversion. */
470 bool didFailPMUPMConversionTest() const; 470 bool didFailPMUPMConversionTest() const;
471 471
472 /** 472 /**
(...skipping 24 matching lines...) Expand all
497 SkAutoTUnref<const GrCaps> fCaps; 497 SkAutoTUnref<const GrCaps> fCaps;
498 uint32_t fContextUniqueID; 498 uint32_t fContextUniqueID;
499 499
500 friend class GrContext; 500 friend class GrContext;
501 friend class SkImage; 501 friend class SkImage;
502 502
503 typedef SkRefCnt INHERITED; 503 typedef SkRefCnt INHERITED;
504 }; 504 };
505 505
506 #endif 506 #endif
OLDNEW
« no previous file with comments | « include/gpu/GrClip.h ('k') | include/gpu/GrFragmentProcessor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698