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

Side by Side Diff: ui/gl/gl_image_io_surface_unittest.cc

Issue 2786103003: Add half-float IOSurface GpuMemoryBuffer support (Closed)
Patch Set: Review feedback Created 3 years, 8 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 | « ui/gl/gl_image_io_surface.mm ('k') | ui/gl/gl_image_memory.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
9 #include "ui/gfx/buffer_format_util.h" 9 #include "ui/gfx/buffer_format_util.h"
10 #include "ui/gfx/mac/io_surface.h" 10 #include "ui/gfx/mac/io_surface.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 return image; 56 return image;
57 } 57 }
58 58
59 unsigned GetTextureTarget() const { return GL_TEXTURE_RECTANGLE_ARB; } 59 unsigned GetTextureTarget() const { return GL_TEXTURE_RECTANGLE_ARB; }
60 const uint8_t* GetImageColor() { return kYuvImageColor; } 60 const uint8_t* GetImageColor() { return kYuvImageColor; }
61 }; 61 };
62 62
63 using GLImageTestTypes = testing::Types< 63 using GLImageTestTypes = testing::Types<
64 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_8888>, 64 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_8888>,
65 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>, 65 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>,
66 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_F16>,
66 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::YUV_420_BIPLANAR>>; 67 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::YUV_420_BIPLANAR>>;
67 68
68 INSTANTIATE_TYPED_TEST_CASE_P(GLImageIOSurface, GLImageTest, GLImageTestTypes); 69 INSTANTIATE_TYPED_TEST_CASE_P(GLImageIOSurface, GLImageTest, GLImageTestTypes);
69 70
70 using GLImageRGBTestTypes = 71 using GLImageRGBTestTypes =
71 testing::Types<GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_8888>, 72 testing::Types<GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_8888>,
72 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>>; 73 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>,
74 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::RGBA_F16>>;
73 75
74 INSTANTIATE_TYPED_TEST_CASE_P(GLImageIOSurface, 76 INSTANTIATE_TYPED_TEST_CASE_P(GLImageIOSurface,
75 GLImageZeroInitializeTest, 77 GLImageZeroInitializeTest,
76 GLImageRGBTestTypes); 78 GLImageRGBTestTypes);
77 79
78 INSTANTIATE_TYPED_TEST_CASE_P( 80 INSTANTIATE_TYPED_TEST_CASE_P(
79 GLImageIOSurface, 81 GLImageIOSurface,
80 GLImageBindTest, 82 GLImageBindTest,
81 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>); 83 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::BGRA_8888>);
82 84
83 INSTANTIATE_TYPED_TEST_CASE_P( 85 INSTANTIATE_TYPED_TEST_CASE_P(
84 GLImageIOSurface, 86 GLImageIOSurface,
85 GLImageCopyTest, 87 GLImageCopyTest,
86 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::YUV_420_BIPLANAR>); 88 GLImageIOSurfaceTestDelegate<gfx::BufferFormat::YUV_420_BIPLANAR>);
87 89
88 } // namespace 90 } // namespace
89 } // namespace gl 91 } // namespace gl
OLDNEW
« no previous file with comments | « ui/gl/gl_image_io_surface.mm ('k') | ui/gl/gl_image_memory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698