зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1276096 - Introspect for readBuffer mode. - r=jrmuizel
This commit is contained in:
Родитель
7fad0075ea
Коммит
3773a30362
|
@ -43,11 +43,8 @@ WebGL2Context::GetParameter(JSContext* cx, GLenum pname, ErrorResult& rv)
|
|||
|
||||
/* GLenum */
|
||||
case LOCAL_GL_READ_BUFFER: {
|
||||
if (mBoundReadFramebuffer) {
|
||||
GLint val = LOCAL_GL_NONE;
|
||||
gl->fGetIntegerv(pname, &val);
|
||||
return JS::Int32Value(val);
|
||||
}
|
||||
if (mBoundReadFramebuffer)
|
||||
return JS::Int32Value(mBoundReadFramebuffer->ReadBufferMode());
|
||||
|
||||
return JS::Int32Value(LOCAL_GL_BACK);
|
||||
}
|
||||
|
|
|
@ -257,6 +257,8 @@ public:
|
|||
mReadBufferMode = readBufferMode;
|
||||
}
|
||||
|
||||
GLenum ReadBufferMode() const { return mReadBufferMode; }
|
||||
|
||||
protected:
|
||||
WebGLFBAttachPoint* GetAttachPoint(GLenum attachment); // Fallible
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче