Bug 1232864 - Cauterize and release WebGL 2 to Nightly. - r=jrmuizel

This commit is contained in:
Jeff Gilbert 2015-12-16 14:56:24 -08:00
parent 378fb504ce
commit 10e8117f04
4 changed files with 30 additions and 5 deletions

View File

@ -19,12 +19,17 @@ WebGL2Context::ValidateBufferTarget(GLenum target, const char* info)
case LOCAL_GL_COPY_READ_BUFFER:
case LOCAL_GL_COPY_WRITE_BUFFER:
case LOCAL_GL_ELEMENT_ARRAY_BUFFER:
case LOCAL_GL_PIXEL_PACK_BUFFER:
case LOCAL_GL_PIXEL_UNPACK_BUFFER:
case LOCAL_GL_TRANSFORM_FEEDBACK_BUFFER:
case LOCAL_GL_UNIFORM_BUFFER:
return true;
case LOCAL_GL_PIXEL_PACK_BUFFER:
case LOCAL_GL_PIXEL_UNPACK_BUFFER:
ErrorInvalidOperation("%s: PBOs are still under development, and are currently"
" disabled.",
info);
return false;
default:
ErrorInvalidEnumInfo(info, target);
return false;

View File

@ -59,8 +59,14 @@ WebGL2Context::RenderbufferStorageMultisample(GLenum target, GLsizei samples,
GLenum internalFormat,
GLsizei width, GLsizei height)
{
RenderbufferStorage_base("renderbufferStorageMultisample", target, samples,
internalFormat, width, height);
const char funcName[] = "renderbufferStorageMultisample";
if (IsContextLost())
return;
//RenderbufferStorage_base(funcName, target, samples, internalFormat, width, height);
ErrorInvalidOperation("%s: Multisampling is still under development, and is currently"
" disabled.", funcName);
}
} // namespace mozilla

View File

@ -12,15 +12,24 @@ namespace mozilla {
already_AddRefed<WebGLSampler>
WebGL2Context::CreateSampler()
{
const char funcName[] = "createSampler";
if (IsContextLost())
return nullptr;
/*
GLuint sampler;
MakeContextCurrent();
gl->fGenSamplers(1, &sampler);
RefPtr<WebGLSampler> globj = new WebGLSampler(this, sampler);
return globj.forget();
*/
ErrorInvalidOperation("%s: Sampler objects are still under development, and are"
" currently disabled.",
funcName);
return nullptr;
}
void

View File

@ -4204,11 +4204,16 @@ pref("webgl.max-warnings-per-context", 32);
pref("webgl.enable-draft-extensions", false);
pref("webgl.enable-privileged-extensions", false);
pref("webgl.bypass-shader-validation", false);
pref("webgl.enable-prototype-webgl2", false);
pref("webgl.disable-fail-if-major-performance-caveat", false);
pref("webgl.disable-DOM-blit-uploads", false);
pref("webgl.webgl2-compat-mode", false);
#ifdef NIGHTLY_BUILD
pref("webgl.enable-prototype-webgl2", true);
#else
pref("webgl.enable-prototype-webgl2", false);
#endif
#ifdef RELEASE_BUILD
// Keep this disabled on Release and Beta for now. (see bug 1171228)
pref("webgl.enable-debug-renderer-info", false);