From 07f864f128ed6b70bb024af8ea0c025d6e4cc879 Mon Sep 17 00:00:00 2001 From: Vladislav Sytchenko Date: Tue, 17 Mar 2020 14:10:06 -0400 Subject: [PATCH] Don't hardcode the texture read mode The readmode needs to be inferred from the template arguments. Change-Id: I067037035e2492a24eac47e16d4015f879be0ea7 [ROCm/hip commit: 99e744ab4a058614b9ff2930991d7437ec962345] --- projects/hip/include/hip/hcc_detail/hip_texture_types.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/projects/hip/include/hip/hcc_detail/hip_texture_types.h b/projects/hip/include/hip/hcc_detail/hip_texture_types.h index fcd6d69dbe..e82ef30f00 100644 --- a/projects/hip/include/hip/hcc_detail/hip_texture_types.h +++ b/projects/hip/include/hip/hcc_detail/hip_texture_types.h @@ -57,7 +57,7 @@ struct __HIP_TEXTURE_ATTRIB texture : public textureReference { texture(int norm = 0, enum hipTextureFilterMode fMode = hipFilterModePoint, enum hipTextureAddressMode aMode = hipAddressModeClamp) { normalized = norm; - readMode = hipReadModeNormalizedFloat; + readMode = mode; filterMode = fMode; addressMode[0] = aMode; addressMode[1] = aMode; @@ -69,7 +69,7 @@ struct __HIP_TEXTURE_ATTRIB texture : public textureReference { texture(int norm, enum hipTextureFilterMode fMode, enum hipTextureAddressMode aMode, struct hipChannelFormatDesc desc) { normalized = norm; - readMode = hipReadModeNormalizedFloat; + readMode = mode; filterMode = fMode; addressMode[0] = aMode; addressMode[1] = aMode;