Files
test2/source/blender/nodes/NOD_geometry_nodes_closure_eval.hh
Jacques Lucke fbd29acaa2 Cleanup: Geometry Nodes: avoid unnecessary void pointer
All socket types use `SocketValueVariant` now, so using `void *` is not necessary anymore.

Pull Request: https://projects.blender.org/blender/blender/pulls/144415
2025-08-12 09:12:08 +02:00

41 lines
1.0 KiB
C++

/* SPDX-FileCopyrightText: 2025 Blender Foundation
*
* SPDX-License-Identifier: GPL-2.0-or-later */
#pragma once
#include "NOD_geometry_nodes_closure.hh"
#include "NOD_geometry_nodes_lazy_function.hh"
#include "BKE_node_socket_value.hh"
namespace blender::nodes {
struct ClosureEagerEvalParams {
struct InputItem {
std::string key;
const bke::bNodeSocketType *type = nullptr;
/** This may be moved from. */
bke::SocketValueVariant value;
};
struct OutputItem {
std::string key;
const bke::bNodeSocketType *type = nullptr;
/**
* Where the output value should be stored. This is expected to point to uninitialized memory
* when it's passed into #evaluate_closure_eagerly which will then construct the value inplace.
*/
bke::SocketValueVariant *value = nullptr;
};
Vector<InputItem> inputs;
Vector<OutputItem> outputs;
GeoNodesUserData *user_data = nullptr;
};
void evaluate_closure_eagerly(const Closure &closure, ClosureEagerEvalParams &params);
} // namespace blender::nodes