shared/source/built_ins/kernels/fill_image2d.builtin_kernel
raw| 1 | /* |
| 2 | * Copyright (C) 2018-2021 Intel Corporation |
| 3 | * |
| 4 | * SPDX-License-Identifier: MIT |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | R"===( |
| 9 | __kernel void FillImage2d( |
| 10 | __write_only image2d_t output, |
| 11 | uint4 color, |
| 12 | int4 dstOffset) { |
| 13 | const int x = get_global_id(0); |
| 14 | const int y = get_global_id(1); |
| 15 | |
| 16 | const int2 dstCoord = (int2)(x, y) + (int2)(dstOffset.x, dstOffset.y); |
| 17 | write_imageui(output, dstCoord, color); |
| 18 | } |
| 19 | )===" |