aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLingfeng Yang <lfy@google.com>2018-10-12 12:39:17 -0700
committerLingfeng Yang <lfy@google.com>2018-10-12 12:39:17 -0700
commit400bc51942768b046d76e552ab4000b2e4cdea24 (patch)
tree56c550c2d1d4883a3dc669fcf76549fbe148a302
parent64bb1574822e3b8339a067a99d0e330290e5dc30 (diff)
downloaddevice_generic_goldfish-opengl-400bc51942768b046d76e552ab4000b2e4cdea24.tar.gz
device_generic_goldfish-opengl-400bc51942768b046d76e552ab4000b2e4cdea24.tar.bz2
device_generic_goldfish-opengl-400bc51942768b046d76e552ab4000b2e4cdea24.zip
Fix wrong indexing into fboprops
Test: ASAN happy in dEQP-GLES3.functional.texture.specification.* Change-Id: I6cf935b2a44313988b015966449d5662239ac7c8
-rw-r--r--shared/OpenglCodecCommon/GLClientState.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/shared/OpenglCodecCommon/GLClientState.cpp b/shared/OpenglCodecCommon/GLClientState.cpp
index 7d403894..c4bf4da0 100644
--- a/shared/OpenglCodecCommon/GLClientState.cpp
+++ b/shared/OpenglCodecCommon/GLClientState.cpp
@@ -1271,14 +1271,14 @@ void GLClientState::getBoundFramebufferFormat(
res_info->rb_format = queryRboFormat(props.depthAttachment_rbo);
res_info->rb_multisamples =
queryRboSamples(
- props.colorAttachmenti_rbos[colorAttachmentIndex]);
+ props.depthAttachment_rbo);
} else if (props.depthAttachment_hasTexObj) {
res_info->type = FBO_ATTACHMENT_TEXTURE;
res_info->tex_internalformat = queryTexInternalFormat(props.depthAttachment_texture);
res_info->tex_format = queryTexFormat(props.depthAttachment_texture);
res_info->tex_type = queryTexType(props.depthAttachment_texture);
res_info->tex_multisamples =
- queryTexSamples(props.colorAttachmenti_textures[colorAttachmentIndex]);
+ queryTexSamples(props.depthAttachment_texture);
} else {
res_info->type = FBO_ATTACHMENT_NONE;
}
@@ -1289,14 +1289,14 @@ void GLClientState::getBoundFramebufferFormat(
res_info->rb_format = queryRboFormat(props.stencilAttachment_rbo);
res_info->rb_multisamples =
queryRboSamples(
- props.colorAttachmenti_rbos[colorAttachmentIndex]);
+ props.stencilAttachment_rbo);
} else if (props.stencilAttachment_hasTexObj) {
res_info->type = FBO_ATTACHMENT_TEXTURE;
res_info->tex_internalformat = queryTexInternalFormat(props.stencilAttachment_texture);
res_info->tex_format = queryTexFormat(props.stencilAttachment_texture);
res_info->tex_type = queryTexType(props.stencilAttachment_texture);
res_info->tex_multisamples =
- queryTexSamples(props.colorAttachmenti_textures[colorAttachmentIndex]);
+ queryTexSamples(props.stencilAttachment_texture);
} else {
res_info->type = FBO_ATTACHMENT_NONE;
}
@@ -1307,14 +1307,14 @@ void GLClientState::getBoundFramebufferFormat(
res_info->rb_format = queryRboFormat(props.depthstencilAttachment_rbo);
res_info->rb_multisamples =
queryRboSamples(
- props.colorAttachmenti_rbos[colorAttachmentIndex]);
+ props.depthstencilAttachment_rbo);
} else if (props.depthstencilAttachment_hasTexObj) {
res_info->type = FBO_ATTACHMENT_TEXTURE;
res_info->tex_internalformat = queryTexInternalFormat(props.depthstencilAttachment_texture);
res_info->tex_format = queryTexFormat(props.depthstencilAttachment_texture);
res_info->tex_type = queryTexType(props.depthstencilAttachment_texture);
res_info->tex_multisamples =
- queryTexSamples(props.colorAttachmenti_textures[colorAttachmentIndex]);
+ queryTexSamples(props.depthstencilAttachment_texture);
} else {
res_info->type = FBO_ATTACHMENT_NONE;
}