P4 to Git Change 1057445 by rili@rili_opencl_stg on 2014/07/21 14:11:34

EPR #399808 - Add CL_RGB, CL_UNORM_INT_101010 support

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpublit.cpp#105 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpudefs.hpp#111 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpuresource.cpp#186 edit
... //depot/stg/opencl/drivers/opencl/runtime/platform/memory.cpp#106 edit


[ROCm/clr commit: 1b9e65b27b]
Этот коммит содержится в:
foreman
2014-07-21 14:27:24 -04:00
родитель f5a1bcf870
Коммит 82dc9c5d23
4 изменённых файлов: 22 добавлений и 2 удалений
+7 -2
Просмотреть файл
@@ -760,6 +760,8 @@ Image::Format::getElementSize() const
break;
case CL_UNORM_INT_101010:
bytesPerPixel = 4;
break;
case CL_SIGNED_INT32:
case CL_UNSIGNED_INT32:
case CL_FLOAT:
@@ -916,6 +918,9 @@ Image::supportedFormats[] = {
{CL_RG, CL_HALF_FLOAT}, {CL_RG, CL_FLOAT},
// RGB
{CL_RGB, CL_UNORM_INT_101010},
// RGBA
{CL_RGBA, CL_SNORM_INT8}, {CL_RGBA, CL_SNORM_INT16},
{CL_RGBA, CL_UNORM_INT8}, {CL_RGBA, CL_UNORM_INT16},
@@ -1334,9 +1339,9 @@ Image::Format::formatColor(const void* colorRGBA, void* colorFormat) const
union t101010 {
struct {
uint32_t r_: 10;
uint32_t g_: 10;
uint32_t b_: 10;
uint32_t g_: 10;
uint32_t r_: 10;
uint32_t a_: 2;
};
uint32_t rgba_;