ES31: Implement getMultisamplefv for D3D part.
Implement getMultisamplefv for d3d part.Because standard D3D sample
positions from https://msdn.microsoft.com/en-us/library/windows/
desktop/ff476218.aspx are fixed sample pattern,we put the sample
positions into a constant array in renderer11_utils.cpp with a
function to query it.
BUG=angleproject:1590
TEST=dEQP-GLES31.functional.texture.multisample.samples_*.sample_position
Change-Id: I6e6006ed1c4e22fe006522e9ffd3297247bee75e
Reviewed-on: https://chromium-review.googlesource.com/594970
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/Context.cpp b/src/libANGLE/Context.cpp
index a1f3214..f7f58da 100644
--- a/src/libANGLE/Context.cpp
+++ b/src/libANGLE/Context.cpp
@@ -4131,8 +4131,10 @@
void Context::getMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
{
- mGLState.syncDirtyObject(this, GL_READ_FRAMEBUFFER);
- const Framebuffer *framebuffer = mGLState.getReadFramebuffer();
+ // According to spec 3.1 Table 20.49: Framebuffer Dependent Values,
+ // the sample position should be queried by DRAW_FRAMEBUFFER.
+ mGLState.syncDirtyObject(this, GL_DRAW_FRAMEBUFFER);
+ const Framebuffer *framebuffer = mGLState.getDrawFramebuffer();
switch (pname)
{