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

Side by Side Diff: gpu/command_buffer/tests/gl_texture_storage_unittest.cc

Issue 2448083003: Reland of gpu: Clarify sized texture format is available (https://codereview.chromium.org/211718300… (Closed)
Patch Set: diff to reland Created 4 years, 1 month 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 | « gpu/command_buffer/service/texture_manager.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 <GLES2/gl2.h> 5 #include <GLES2/gl2.h>
6 #include <GLES2/gl2ext.h> 6 #include <GLES2/gl2ext.h>
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "gpu/command_buffer/tests/gl_manager.h" 9 #include "gpu/command_buffer/tests/gl_manager.h"
10 #include "gpu/command_buffer/tests/gl_test_utils.h" 10 #include "gpu/command_buffer/tests/gl_test_utils.h"
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 0, 149 0,
150 GL_RGBA, 150 GL_RGBA,
151 4, 4, 151 4, 4,
152 0, 152 0,
153 GL_RGBA, 153 GL_RGBA,
154 GL_UNSIGNED_BYTE, 154 GL_UNSIGNED_BYTE,
155 NULL); 155 NULL);
156 EXPECT_EQ(static_cast<GLenum>(GL_INVALID_OPERATION), glGetError()); 156 EXPECT_EQ(static_cast<GLenum>(GL_INVALID_OPERATION), glGetError());
157 } 157 }
158 158
159 TEST_F(TextureStorageTest, InternalFormatBleedingToTexImage) {
160 if (!extension_available_)
161 return;
162
163 EXPECT_EQ(static_cast<GLenum>(GL_NO_ERROR), glGetError());
164 // The context is ES2 context.
165 glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA8_OES, 4, 4, 0, GL_RGBA,
166 GL_UNSIGNED_BYTE, nullptr);
167 EXPECT_EQ(static_cast<GLenum>(GL_INVALID_VALUE), glGetError());
168 }
169
159 } // namespace gpu 170 } // namespace gpu
160 171
161 172
162 173
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/texture_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698