Files
test2/intern/cycles/kernel/svm/value.h
Brecht Van Lommel 0e7a696819 Cleanup: Unused arguments in Cycles kernel
And add back the compiler flag that hid them.

Pull Request: https://projects.blender.org/blender/blender/pulls/139497
2025-05-27 21:30:45 +02:00

35 lines
902 B
C

/* SPDX-FileCopyrightText: 2011-2022 Blender Foundation
*
* SPDX-License-Identifier: Apache-2.0 */
#pragma once
#include "kernel/svm/util.h"
CCL_NAMESPACE_BEGIN
/* Value Nodes */
ccl_device void svm_node_value_f(ccl_private float *stack,
const uint ivalue,
const uint out_offset)
{
stack_store_float(stack, out_offset, __uint_as_float(ivalue));
}
ccl_device int svm_node_value_v(KernelGlobals kg,
ccl_private float *stack,
const uint out_offset,
int offset)
{
/* read extra data */
const uint4 node1 = read_node(kg, &offset);
const float3 p = make_float3(
__uint_as_float(node1.y), __uint_as_float(node1.z), __uint_as_float(node1.w));
stack_store_float3(stack, out_offset, p);
return offset;
}
CCL_NAMESPACE_END