diff options
author | bungeman <bungeman@google.com> | 2016-10-27 09:30:08 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-10-27 09:30:08 -0700 |
commit | 6bd5284415bd983b0628c4941dff5def40018f5a (patch) | |
tree | 7de7e45431f76db69807204ecdce3ed6fcc4d9e8 /tests/EGLImageTest.cpp | |
parent | 56380524d903f27627a75e2e1189463999725008 (diff) |
Remove SkAutoTUnref and SkAutoTDelete from public includes.
This also makes the required changed to src, tests, and tools. The few
public APIs modified by this change appear to be unused outside of Skia.
Removing these from the public API makes it easier to ensure users are
no longer using them.
This also updates GrGpu::wrapBackendXXX and the
::onWrapBackendXXX methods to clarify ownership.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2448593002
Review-Url: https://codereview.chromium.org/2448593002
Diffstat (limited to 'tests/EGLImageTest.cpp')
-rw-r--r-- | tests/EGLImageTest.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/EGLImageTest.cpp b/tests/EGLImageTest.cpp index 4a23a9c3f5..de305c7443 100644 --- a/tests/EGLImageTest.cpp +++ b/tests/EGLImageTest.cpp @@ -173,7 +173,7 @@ DEF_GPUTEST_FOR_GL_RENDERING_CONTEXTS(EGLImageTest, reporter, ctxInfo) { externalDesc.fWidth = kSize; externalDesc.fHeight = kSize; externalDesc.fTextureHandle = reinterpret_cast<GrBackendObject>(&externalTexture); - SkAutoTUnref<GrTexture> externalTextureObj( + sk_sp<GrTexture> externalTextureObj( context0->textureProvider()->wrapBackendTexture(externalDesc)); if (!externalTextureObj) { ERRORF(reporter, "Error wrapping external texture in GrTexture."); @@ -183,7 +183,7 @@ DEF_GPUTEST_FOR_GL_RENDERING_CONTEXTS(EGLImageTest, reporter, ctxInfo) { // Should not be able to wrap as a RT externalDesc.fFlags = kRenderTarget_GrBackendTextureFlag; - SkAutoTUnref<GrTexture> externalTextureRTObj( + sk_sp<GrTexture> externalTextureRTObj( context0->textureProvider()->wrapBackendTexture(externalDesc)); if (externalTextureRTObj) { ERRORF(reporter, "Should not be able to wrap an EXTERNAL texture as a RT."); @@ -192,18 +192,18 @@ DEF_GPUTEST_FOR_GL_RENDERING_CONTEXTS(EGLImageTest, reporter, ctxInfo) { // Should not be able to wrap with a sample count externalDesc.fSampleCnt = 4; - SkAutoTUnref<GrTexture> externalTextureMSAAObj( + sk_sp<GrTexture> externalTextureMSAAObj( context0->textureProvider()->wrapBackendTexture(externalDesc)); if (externalTextureMSAAObj) { ERRORF(reporter, "Should not be able to wrap an EXTERNAL texture with MSAA."); } externalDesc.fSampleCnt = 0; - test_read_pixels(reporter, context0, externalTextureObj, pixels.get()); + test_read_pixels(reporter, context0, externalTextureObj.get(), pixels.get()); - test_write_pixels(reporter, context0, externalTextureObj); + test_write_pixels(reporter, context0, externalTextureObj.get()); - test_copy_surface(reporter, context0, externalTextureObj, pixels.get()); + test_copy_surface(reporter, context0, externalTextureObj.get(), pixels.get()); cleanup(glCtx0, externalTexture.fID, glCtx1, context1, backendTexture1, image); } |