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

Unified Diff: gpu/command_buffer/service/texture_manager.h

Issue 139013008: Implement support for rendering to 32-bit float textures on ES3 (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Make TexSubImage validation agree with TexImage validation Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/service/texture_manager.h
diff --git a/gpu/command_buffer/service/texture_manager.h b/gpu/command_buffer/service/texture_manager.h
index b74ef91421a440daf3da0ea901793e2ee8d67abb..c44bef314af061d29d6ea5b0c8b177db0ba10631 100644
--- a/gpu/command_buffer/service/texture_manager.h
+++ b/gpu/command_buffer/service/texture_manager.h
@@ -116,7 +116,7 @@ class GPU_EXPORT Texture {
}
// Returns true of the given dimensions are inside the dimensions of the
- // level and if the format and type match the level.
+ // level and if the type matches the level.
bool ValidForTexture(
GLint target,
GLint level,
@@ -124,7 +124,6 @@ class GPU_EXPORT Texture {
GLint yoffset,
GLsizei width,
GLsizei height,
- GLenum format,
GLenum type) const;
bool IsValid() const {
@@ -707,9 +706,15 @@ class GPU_EXPORT TextureManager {
TextureRef* GetTextureInfoForTargetUnlessDefault(
ContextState* state, GLenum target);
+ bool ValidateFormatAndTypeCombination(
+ ErrorState* error_state, const char* function_name,
+ GLenum format, GLenum type);
+
+ // Note that internal_format is only checked in relation to the format
+ // parameter, so that this function may be used to validate texSubImage2D.
bool ValidateTextureParameters(
ErrorState* error_state, const char* function_name,
- GLenum target, GLenum format, GLenum type, GLint level);
+ GLenum format, GLenum type, GLenum internal_format, GLint level);
private:
friend class Texture;

Powered by Google App Engine
This is Rietveld 408576698