From d17f060d8faa9e88fe39dab62bf71e9f7b02a33a Mon Sep 17 00:00:00 2001 From: foreman Date: Fri, 18 Jan 2019 14:41:37 -0500 Subject: [PATCH] P4 to Git Change 1732709 by gandryey@gera-w8 on 2019/01/18 14:18:03 SWDEV-79445 - OCL generic changes and code clean-up - Add 101010 GL interop formats mapping into CL_RGBA. The change will make sure the channel order consistency between OGL and OCL Affected files ... ... //depot/stg/opencl/drivers/opencl/api/opencl/amdocl/cl_gl.cpp#62 edit ... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldefs.hpp#47 edit [ROCm/clr commit: 02c5d38cb91d6bd534edbd5bdef8d2371ba6c9ed] --- projects/clr/rocclr/runtime/device/pal/paldefs.hpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/projects/clr/rocclr/runtime/device/pal/paldefs.hpp b/projects/clr/rocclr/runtime/device/pal/paldefs.hpp index bd0817469c..2a58e18701 100644 --- a/projects/clr/rocclr/runtime/device/pal/paldefs.hpp +++ b/projects/clr/rocclr/runtime/device/pal/paldefs.hpp @@ -393,6 +393,13 @@ static const MemoryFormat MemoryFormatMap[] = { Pal::ChNumFormat::X10Y10Z10W2_Unorm, {Pal::ChannelSwizzle::Z, Pal::ChannelSwizzle::Y, Pal::ChannelSwizzle::X, Pal::ChannelSwizzle::One}}, + // RGBA + // Note: special case for GL interops, OCL spec doesn't support 101010 format + // for GL interop and GL uses real RGB channel order + {{CL_RGBA, CL_UNORM_INT_101010}, + Pal::ChNumFormat::X10Y10Z10W2_Unorm, + {Pal::ChannelSwizzle::X, Pal::ChannelSwizzle::Y, Pal::ChannelSwizzle::Z, + Pal::ChannelSwizzle::One}}, // RGBA {{CL_RGBA, CL_UNORM_INT8},