Blender
V3.3
|
#include <NOD_geometry_exec.hh>
Public Member Functions | |
GeoNodeExecParams (GeoNodeExecParamsProvider &provider) | |
GMutablePointer | extract_input (StringRef identifier) |
template<typename T > | |
T | extract_input (StringRef identifier) |
void | check_input_geometry_set (StringRef identifier, const GeometrySet &geometry_set) const |
void | check_output_geometry_set (const GeometrySet &geometry_set) const |
template<typename T > | |
Vector< T > | extract_multi_input (StringRef identifier) |
template<typename T > | |
T | get_input (StringRef identifier) const |
template<typename T > | |
void | set_output (StringRef identifier, T &&value) |
void | set_input_unused (StringRef identifier) |
bool | output_is_required (StringRef identifier) const |
bool | lazy_require_input (StringRef identifier) |
bool | lazy_output_is_required (StringRef identifier) |
const bNode & | node () const |
const Object * | self_object () const |
Depsgraph * | depsgraph () const |
void | error_message_add (const NodeWarningType type, std::string message) const |
std::string | attribute_producer_name () const |
void | set_default_remaining_outputs () |
void | used_named_attribute (std::string attribute_name, eNamedAttrUsage usage) |
Static Public Attributes | |
template<typename T > | |
static constexpr bool | is_field_base_type_v |
Definition at line 108 of file NOD_geometry_exec.hh.
|
inline |
Definition at line 113 of file NOD_geometry_exec.hh.
std::string blender::nodes::GeoNodeExecParams::attribute_producer_name | ( | ) | const |
Definition at line 130 of file intern/node_geometry_exec.cc.
References blender::nodes::GeoNodeExecParamsProvider::dnode, blender::nodes::NodeRef::label_or_name(), and TIP_.
void blender::nodes::GeoNodeExecParams::check_input_geometry_set | ( | StringRef | identifier, |
const GeometrySet & | geometry_set | ||
) | const |
Definition at line 37 of file intern/node_geometry_exec.cc.
References BLI_assert_unreachable, blender::nodes::SocketRef::bsocket(), blender::Span< T >::contains(), blender::nodes::GeoNodeExecParamsProvider::dnode, error_message_add(), GeometrySet::gather_component_types(), GEO_COMPONENT_TYPE_CURVE, GEO_COMPONENT_TYPE_EDIT, GEO_COMPONENT_TYPE_INSTANCES, GEO_COMPONENT_TYPE_MESH, GEO_COMPONENT_TYPE_POINT_CLOUD, GEO_COMPONENT_TYPE_VOLUME, GeometrySet::has_instances(), GeometrySet::has_realized_data(), Info, blender::nodes::NodeRef::input_by_identifier(), blender::Span< T >::is_empty(), blender::nodes::decl::Geometry::only_instances(), blender::nodes::decl::Geometry::only_realized_data(), bNodeSocket::runtime, blender::nodes::decl::Geometry::supported_types(), TIP_, and type.
Referenced by extract_input(), and get_input().
void blender::nodes::GeoNodeExecParams::check_output_geometry_set | ( | const GeometrySet & | geometry_set | ) | const |
Definition at line 106 of file intern/node_geometry_exec.cc.
References BLI_assert, GeometrySet::get_curve_edit_hints_for_read(), and UNUSED_VARS_NDEBUG.
Referenced by set_output().
|
inline |
Definition at line 296 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::depsgraph.
void blender::nodes::GeoNodeExecParams::error_message_add | ( | const NodeWarningType | type, |
std::string | message | ||
) | const |
Add an error message displayed at the top of the node when displaying the node tree, and potentially elsewhere in Blender.
Definition at line 18 of file intern/node_geometry_exec.cc.
References blender::nodes::GeoNodeExecParamsProvider::dnode, blender::nodes::geometry_nodes_eval_log::GeoLogger::local(), blender::nodes::geometry_nodes_eval_log::LocalGeoLogger::log_node_warning(), blender::nodes::GeoNodeExecParamsProvider::logger, and type.
Referenced by check_input_geometry_set().
|
inline |
Get the input value for the input socket with the given identifier.
The node calling becomes responsible for destructing the value before it is done executing. This method can only be called once for each identifier.
Definition at line 127 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::extract_input().
Referenced by extract_input().
|
inline |
Get the input value for the input socket with the given identifier.
This method can only be called once for each identifier.
Definition at line 140 of file NOD_geometry_exec.hh.
References blender::fn::ValueOrField< T >::as_field(), blender::fn::ValueOrField< T >::as_value(), check_input_geometry_set(), extract_input(), blender::GMutablePointer::relocate_out(), and T.
|
inline |
Get input as vector for multi input socket with the given identifier.
This method can only be called once for each identifier.
Definition at line 173 of file NOD_geometry_exec.hh.
References blender::Vector< T, InlineBufferCapacity, Allocator >::append(), blender::fn::ValueOrField< T >::as_value(), blender::nodes::GeoNodeExecParamsProvider::extract_multi_input(), and T.
|
inline |
Get the input value for the input socket with the given identifier.
Definition at line 192 of file NOD_geometry_exec.hh.
References blender::fn::ValueOrField< T >::as_field(), blender::fn::ValueOrField< T >::as_value(), BLI_assert, check_input_geometry_set(), blender::GPointer::get(), blender::nodes::GeoNodeExecParamsProvider::get_input(), blender::GPointer::is_type(), and T.
Asks the evaluator if a specific output is required right now. If this returns false, the value might still need to be computed later. This can only be used when the node supports laziness.
Definition at line 278 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::lazy_output_is_required().
Tell the evaluator that a specific input is required. This returns true when the input will only be available in the next execution. False is returned if the input is available already. This can only be used when the node supports laziness.
Definition at line 268 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::lazy_require_input().
|
inline |
Get the node that is currently being executed.
Definition at line 286 of file NOD_geometry_exec.hh.
References blender::nodes::NodeRef::bnode(), and blender::nodes::GeoNodeExecParamsProvider::dnode.
Returns true when the output has to be computed. Nodes that support laziness could use the lazy_output_is_required variant to possibly avoid some computations.
Definition at line 257 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::output_is_required().
|
inline |
Definition at line 291 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::self_object.
void blender::nodes::GeoNodeExecParams::set_default_remaining_outputs | ( | ) |
Definition at line 135 of file intern/node_geometry_exec.cc.
References blender::nodes::GeoNodeExecParamsProvider::set_default_remaining_outputs().
Tell the evaluator that a specific input won't be used anymore.
Definition at line 247 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::set_input_unused().
|
inline |
Store the output value for the given socket identifier.
Definition at line 220 of file NOD_geometry_exec.hh.
References blender::nodes::GeoNodeExecParamsProvider::alloc_output_value(), check_output_geometry_set(), blender::GMutablePointer::get(), blender::nodes::GeoNodeExecParamsProvider::set_output(), and type.
void blender::nodes::GeoNodeExecParams::used_named_attribute | ( | std::string | attribute_name, |
eNamedAttrUsage | usage | ||
) |
Definition at line 27 of file intern/node_geometry_exec.cc.
References blender::nodes::GeoNodeExecParamsProvider::dnode, blender::nodes::geometry_nodes_eval_log::GeoLogger::local(), blender::nodes::geometry_nodes_eval_log::LocalGeoLogger::log_used_named_attribute(), and blender::nodes::GeoNodeExecParamsProvider::logger.
|
inlinestaticconstexpr |
Definition at line 118 of file NOD_geometry_exec.hh.