Bug 1636085 - Unbind GL_TEXTURE_EXTERNAL_OES before binding GL_TEXTURE_2D. r=gw
Bug 1636085 - Unbind GL_TEXTURE_EXTERNAL_OES before binding GL_TEXTURE_2D. r=gw

The android emulator appears to have a bug in its OpenGL
implementation where it gets confused about whether a texture is bound
to GL_TEXTURE_EXTERNAL_OES or GL_TEXTURE_2D. This was causing spurious
errors when attempting to use a regular 2D texture, due to the fact
that an external texture had previously been bound.

Work around this by explicitly unbinding from GL_TEXTURE_EXTERNAL_OES
immediately before binding to GL_TEXTURE_2D.

Differential Revision: https://phabricator.services.mozilla.com/D76318

[ghsync] From https://hg.mozilla.org/mozilla-central/rev/b9d97c8a708eb0c8b567d352833884c3103b0afc

servo/webrender,servo/webrender,servo/webrender,servo/webrender,servo/webrender,servo/webrender