Revert of Include glGetMultisamplefv API (patchset #1 id:1 of https://codereview...
authorethannicholas <ethannicholas@google.com>
Wed, 24 Feb 2016 16:19:04 +0000 (08:19 -0800)
committerCommit bot <commit-bot@chromium.org>
Wed, 24 Feb 2016 16:19:04 +0000 (08:19 -0800)
Reason for revert:
This is in the blamelist for Visualbench failures:

https://build.chromium.org/p/client.skia/builders/Perf-Ubuntu-GCC-ShuttleA-GPU-GTX660-x86_64-Release-VisualBench/builds/1035

and seems the most likely candidate for the failure, so I am tentatively reverting.

Original issue's description:
> Include glGetMultisamplefv API
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1720963002
>
> Committed: https://skia.googlesource.com/skia/+/69c1b24bcaa7cffd59753a75a7f3d155696fcac4

TBR=bsalomon@google.com,joshualitt@google.com,cdalton@nvidia.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1731333002

13 files changed:
include/gpu/GrCaps.h
include/gpu/gl/GrGLFunctions.h
include/gpu/gl/GrGLInterface.h
src/gpu/GrCaps.cpp
src/gpu/gl/GrGLAssembleInterface.cpp
src/gpu/gl/GrGLCaps.cpp
src/gpu/gl/GrGLCreateNullInterface.cpp
src/gpu/gl/GrGLDefines.h
src/gpu/gl/GrGLInterface.cpp
src/gpu/gl/GrGLNoOpInterface.cpp
src/gpu/gl/GrGLNoOpInterface.h
src/gpu/gl/SkNullGLContext.cpp
src/gpu/gl/debug/GrGLCreateDebugInterface.cpp

index 60f2139..e2e44a5 100644 (file)
@@ -144,7 +144,6 @@ public:
     bool compressedTexSubImageSupport() const { return fCompressedTexSubImageSupport; }
     bool oversizedStencilSupport() const { return fOversizedStencilSupport; }
     bool textureBarrierSupport() const { return fTextureBarrierSupport; }
-    bool sampleLocationsSupport() const { return fSampleLocationsSupport; }
     bool usesMixedSamples() const { return fUsesMixedSamples; }
 
     bool useDrawInsteadOfClear() const { return fUseDrawInsteadOfClear; }
@@ -277,7 +276,6 @@ protected:
     bool fCompressedTexSubImageSupport               : 1;
     bool fOversizedStencilSupport                    : 1;
     bool fTextureBarrierSupport                      : 1;
-    bool fSampleLocationsSupport                     : 1;
     bool fUsesMixedSamples                           : 1;
     bool fSupportsInstancedDraws                     : 1;
     bool fFullClearIsFree                            : 1;
index a6b9b9a..6986f8c 100644 (file)
@@ -89,7 +89,6 @@ typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetBufferParameterivProc)(GrGLenum ta
 typedef GrGLenum (GR_GL_FUNCTION_TYPE* GrGLGetErrorProc)();
 typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetFramebufferAttachmentParameterivProc)(GrGLenum target, GrGLenum attachment, GrGLenum pname, GrGLint* params);
 typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetIntegervProc)(GrGLenum pname, GrGLint* params);
-typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetMultisamplefvProc)(GrGLenum pname, GrGLuint index, GrGLfloat* val);
 typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetProgramInfoLogProc)(GrGLuint program, GrGLsizei bufsize, GrGLsizei* length, char* infolog);
 typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetProgramivProc)(GrGLuint program, GrGLenum pname, GrGLint* params);
 typedef GrGLvoid (GR_GL_FUNCTION_TYPE* GrGLGetQueryivProc)(GrGLenum GLtarget, GrGLenum pname, GrGLint *params);
index 150a2bf..1a91afb 100644 (file)
@@ -202,7 +202,6 @@ public:
         GrGLFunction<GrGLGetErrorProc> fGetError;
         GrGLFunction<GrGLGetFramebufferAttachmentParameterivProc> fGetFramebufferAttachmentParameteriv;
         GrGLFunction<GrGLGetIntegervProc> fGetIntegerv;
-        GrGLFunction<GrGLGetMultisamplefvProc> fGetMultisamplefv;
         GrGLFunction<GrGLGetQueryObjecti64vProc> fGetQueryObjecti64v;
         GrGLFunction<GrGLGetQueryObjectivProc> fGetQueryObjectiv;
         GrGLFunction<GrGLGetQueryObjectui64vProc> fGetQueryObjectui64v;
index c544d6e..4fb05c1 100644 (file)
@@ -92,7 +92,6 @@ GrCaps::GrCaps(const GrContextOptions& options) {
     fCompressedTexSubImageSupport = false;
     fOversizedStencilSupport = false;
     fTextureBarrierSupport = false;
-    fSampleLocationsSupport = false;
     fUsesMixedSamples = false;
     fSupportsInstancedDraws = false;
     fFullClearIsFree = false;
@@ -166,7 +165,6 @@ SkString GrCaps::dump() const {
     r.appendf("Compressed Update Support          : %s\n", gNY[fCompressedTexSubImageSupport]);
     r.appendf("Oversized Stencil Support          : %s\n", gNY[fOversizedStencilSupport]);
     r.appendf("Texture Barrier Support            : %s\n", gNY[fTextureBarrierSupport]);
-    r.appendf("Sample Locations Support           : %s\n", gNY[fSampleLocationsSupport]);
     r.appendf("Uses Mixed Samples                 : %s\n", gNY[fUsesMixedSamples]);
     r.appendf("Supports instanced draws           : %s\n", gNY[fSupportsInstancedDraws]);
     r.appendf("Full screen clear is free          : %s\n", gNY[fFullClearIsFree]);
index f23bf17..e52d302 100644 (file)
@@ -162,9 +162,6 @@ const GrGLInterface* GrGLAssembleGLInterface(void* ctx, GrGLGetProc get) {
     GET_PROC(GetBufferParameteriv);
     GET_PROC(GetError);
     GET_PROC(GetIntegerv);
-    if (glVer >= GR_GL_VER(3,2)) {
-        GET_PROC(GetMultisamplefv);
-    }
     GET_PROC(GetQueryObjectiv);
     GET_PROC(GetQueryObjectuiv);
     if (glVer >= GR_GL_VER(3,3) || extensions.has("GL_ARB_timer_query")) {
@@ -612,11 +609,6 @@ const GrGLInterface* GrGLAssembleGLESInterface(void* ctx, GrGLGetProc get) {
     GET_PROC(GetBufferParameteriv);
     GET_PROC(GetError);
     GET_PROC(GetIntegerv);
-
-    if (version >= GR_GL_VER(3,1)) {
-        GET_PROC(GetMultisamplefv);
-    }
-
     GET_PROC(GetProgramInfoLog);
     GET_PROC(GetProgramiv);
     GET_PROC(GetShaderInfoLog);
index 883ac15..546b0bf 100644 (file)
@@ -126,13 +126,6 @@ void GrGLCaps::init(const GrContextOptions& contextOptions,
         fTextureBarrierSupport = ctxInfo.hasExtension("GL_NV_texture_barrier");
     }
 
-    if (kGL_GrGLStandard == standard) {
-        fSampleLocationsSupport = version >= GR_GL_VER(3,2) ||
-                                  ctxInfo.hasExtension("GL_ARB_texture_multisample");
-    } else {
-        fSampleLocationsSupport = version >= GR_GL_VER(3,1);
-    }
-
     // ARB_texture_rg is part of OpenGL 3.0, but mesa doesn't support GL_RED 
     // and GL_RG on FBO textures.
     if (kMesa_GrGLDriver != ctxInfo.driver()) {
index 17f305b..f56b1d9 100644 (file)
@@ -402,7 +402,6 @@ const GrGLInterface* GrGLCreateNullInterface() {
     functions->fGetBufferParameteriv = nullGLGetBufferParameteriv;
     functions->fGetError = noOpGLGetError;
     functions->fGetIntegerv = noOpGLGetIntegerv;
-    functions->fGetMultisamplefv = noOpGLGetMultisamplefv;
     functions->fGetQueryObjecti64v = noOpGLGetQueryObjecti64v;
     functions->fGetQueryObjectiv = noOpGLGetQueryObjectiv;
     functions->fGetQueryObjectui64v = noOpGLGetQueryObjectui64v;
index 219501c..9be769f 100644 (file)
 
 /* multisample */
 #define GR_GL_MULTISAMPLE                    0x809D
-#define GR_GL_SAMPLE_POSITION                0x8E50
 
 /* Points */
 #define GR_GL_POINT_SMOOTH                   0x0B10
index 84c51fb..c09efae 100644 (file)
@@ -487,14 +487,6 @@ bool GrGLInterface::validate() const {
     }
 
     if ((kGL_GrGLStandard == fStandard &&
-         (glVer >= GR_GL_VER(3,2) || fExtensions.has("GL_ARB_texture_multisample"))) ||
-        (kGLES_GrGLStandard == fStandard && glVer >= GR_GL_VER(3,1))) {
-        if (NULL == fFunctions.fGetMultisamplefv) {
-            RETURN_FALSE_INTERFACE
-        }
-    }
-
-    if ((kGL_GrGLStandard == fStandard &&
          (glVer >= GR_GL_VER(4,3) || fExtensions.has("GL_ARB_program_interface_query"))) ||
         (kGLES_GrGLStandard == fStandard && glVer >= GR_GL_VER(3,1))) {
         if (nullptr == fFunctions.fGetProgramResourceLocation) {
index 3cf9ecd..f08d737 100644 (file)
@@ -561,12 +561,6 @@ GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetInfoLog(GrGLuint program,
    }
 }
 
-GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetMultisamplefv(GrGLenum pname,
-                                                    GrGLuint index,
-                                                    GrGLfloat* val) {
-    val[0] = val[1] = 0.5f;
-}
-
 GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetShaderOrProgramiv(GrGLuint program,
                                                         GrGLenum pname,
                                                         GrGLint* params) {
index 23168e2..44894b7 100644 (file)
@@ -363,8 +363,6 @@ GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetInfoLog(GrGLuint program,
                                               GrGLsizei* length,
                                               char* infolog);
 
-GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetMultisamplefv(GrGLenum pname, GrGLuint index, GrGLfloat* val);
-
 // can be used for both the program and shader params
 GrGLvoid GR_GL_FUNCTION_TYPE noOpGLGetShaderOrProgramiv(GrGLuint program,
                                                         GrGLenum pname,
index 33f9a0a..68b19ce 100644 (file)
@@ -451,7 +451,6 @@ static GrGLInterface* create_null_interface(State* state) {
     functions->fGetBufferParameteriv = nullGLGetBufferParameteriv;
     functions->fGetError = noOpGLGetError;
     functions->fGetIntegerv = noOpGLGetIntegerv;
-    functions->fGetMultisamplefv = noOpGLGetMultisamplefv;
     functions->fGetQueryObjecti64v = noOpGLGetQueryObjecti64v;
     functions->fGetQueryObjectiv = noOpGLGetQueryObjectiv;
     functions->fGetQueryObjectui64v = noOpGLGetQueryObjectui64v;
index 23e0d7e..2118c02 100644 (file)
@@ -895,7 +895,6 @@ const GrGLInterface* GrGLCreateDebugInterface() {
     functions->fGetBufferParameteriv = debugGLGetBufferParameteriv;
     functions->fGetError = noOpGLGetError;
     functions->fGetIntegerv = noOpGLGetIntegerv;
-    functions->fGetMultisamplefv = noOpGLGetMultisamplefv;
     functions->fGetQueryObjecti64v = noOpGLGetQueryObjecti64v;
     functions->fGetQueryObjectiv = noOpGLGetQueryObjectiv;
     functions->fGetQueryObjectui64v = noOpGLGetQueryObjectui64v;