diff options
author | bsalomon <bsalomon@google.com> | 2014-10-14 08:40:57 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-10-14 08:40:57 -0700 |
commit | b501ecd0d7aa1c49c8c7f407ac6d51f5dc93122f (patch) | |
tree | bf4623f5aa422cfde9e47f572ecb515d4e43c566 /src/gpu/gl | |
parent | e070c2bf54c451f0126d4ffb3a48bffe1fbfa437 (diff) |
Use GL_R8 rather than GL_RED for glTexImage2D on IMG/ES3. Check for failure of FP creation in SkImageFilter
BUG=skia:2922
Review URL: https://codereview.chromium.org/656853002
Diffstat (limited to 'src/gpu/gl')
-rw-r--r-- | src/gpu/gl/GrGpuGL.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/gpu/gl/GrGpuGL.cpp b/src/gpu/gl/GrGpuGL.cpp index a4665f9b3e..97f2a114db 100644 --- a/src/gpu/gl/GrGpuGL.cpp +++ b/src/gpu/gl/GrGpuGL.cpp @@ -587,11 +587,13 @@ bool GrGpuGL::uploadTexData(const GrGLTexture::Desc& desc, // size of the internal format whenever possible and so only use a sized internal format when // using texture storage. bool useSizedFormat = useTexStorage; - // At least some versions of the desktop ES3 drivers for NVIDIA won't accept GL_RED in + // At least some versions of the ES3 drivers for NVIDIA and IMG won't accept GL_RED in // glTexImage2D for the internal format but will accept GL_R8. - if (!useSizedFormat && kNVIDIA_GrGLVendor == this->glContext().vendor() && - kGLES_GrGLStandard == this->glStandard() && this->glVersion() >= GR_GL_VER(3, 0)) { - useSizedFormat = true; + if (kNVIDIA_GrGLVendor == this->glContext().vendor() || + kImagination_GrGLVendor == this->glContext().vendor()) { + if (kGLES_GrGLStandard == this->glStandard() && this->glVersion() >= GR_GL_VER(3, 0)) { + useSizedFormat = true; + } } if (!this->configToGLFormats(dataConfig, useSizedFormat, &internalFormat, &externalFormat, &externalType)) { |