2022-06-08 12:47:24 +00:00
|
|
|
// Copyright (C) 2017 Juan José Casafranca.
|
2024-02-23 14:41:04 +00:00
|
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
|
2016-12-20 08:12:55 +00:00
|
|
|
|
2020-11-30 09:09:59 +00:00
|
|
|
#version 450 core
|
2016-12-20 08:12:55 +00:00
|
|
|
|
|
|
|
layout (local_size_x=32) in;
|
|
|
|
|
2020-11-30 09:09:59 +00:00
|
|
|
layout (std430, binding = 3) buffer InputBuffer
|
2016-12-20 08:12:55 +00:00
|
|
|
{
|
|
|
|
uint d[];
|
|
|
|
};
|
|
|
|
|
2020-11-30 09:09:59 +00:00
|
|
|
layout(std140, binding=4) uniform custom_uniforms {
|
|
|
|
int inputSize;
|
|
|
|
};
|
2016-12-20 08:12:55 +00:00
|
|
|
|
|
|
|
void main()
|
|
|
|
{
|
|
|
|
if (gl_GlobalInvocationID.x < inputSize)
|
2017-02-15 09:15:33 +00:00
|
|
|
d[gl_GlobalInvocationID.x] = d[gl_GlobalInvocationID.x] + gl_GlobalInvocationID.x * 2;
|
2016-12-20 08:12:55 +00:00
|
|
|
}
|