24 b.use_custom_socket_order();
25 b.allow_any_socket_order();
28 .default_value({1.0f, 1.0f, 1.0f, 1.0f})
31 .structure_type(StructureType::Dynamic);
32 b.add_output<
decl::Color>(
"Image").structure_type(StructureType::Dynamic).align_with_previous();
34 b.add_input<
decl::Float>(
"X").default_value(0.0f).min(-10000.0f).max(10000.0f);
35 b.add_input<
decl::Float>(
"Y").default_value(0.0f).min(-10000.0f).max(10000.0f);
42 .description(
"Interpolation method");
47 .description(
"The extension mode applied to the X axis");
52 .description(
"The extension mode applied to the Y axis");
88 const MenuValue menu_value =
input.get_single_value_default(default_menu_value);
90 switch (interpolation) {
107 const MenuValue menu_value =
input.get_single_value_default(default_menu_value);
109 switch (extension_x) {
125 const MenuValue menu_value =
input.get_single_value_default(default_menu_value);
127 switch (extension_y) {
158 ntype.
declare = file_ns::cmp_node_translate_declare;
159 ntype.
initfunc = file_ns::node_composit_init_translate;
#define NODE_CLASS_DISTORT
#define CMP_NODE_TRANSLATE
@ CMP_NODE_INTERPOLATION_NEAREST
@ CMP_NODE_INTERPOLATION_BILINEAR
@ CMP_NODE_INTERPOLATION_BICUBIC
@ CMP_NODE_INTERPOLATION_ANISOTROPIC
@ CMP_NODE_EXTENSION_MODE_EXTEND
@ CMP_NODE_EXTENSION_MODE_CLIP
@ CMP_NODE_EXTENSION_MODE_REPEAT
#define NOD_REGISTER_NODE(REGISTER_FUNC)
BMesh const char void * data
NodeOperation(Context &context, DNode node)
Result & get_result(StringRef identifier)
Result & get_input(StringRef identifier) const
void share_data(const Result &source)
RealizationOptions & get_realization_options()
T get_single_value_default(const T &default_value) const
DeclType::Builder & add_input(StringRef name, StringRef identifier="")
const CompositorInputRealizationMode & compositor_realization_mode() const
Interpolation get_interpolation()
ExtensionMode get_extension_mode_x()
ExtensionMode get_extension_mode_y()
NodeOperation(Context &context, DNode node)
void * MEM_callocN(size_t len, const char *str)
void node_register_type(bNodeType &ntype)
void node_type_storage(bNodeType &ntype, std::optional< StringRefNull > storagename, void(*freefunc)(bNode *node), void(*copyfunc)(bNodeTree *dest_ntree, bNode *dest_node, const bNode *src_node))
MatT from_location(const typename MatT::loc_type &location)
static void node_composit_init_translate(bNodeTree *, bNode *node)
static void cmp_node_translate_declare(NodeDeclarationBuilder &b)
static NodeOperation * get_compositor_operation(Context &context, DNode node)
VecBase< float, 2 > float2
static void register_node_type_cmp_translate()
void cmp_node_type_base(blender::bke::bNodeType *ntype, std::string idname, const std::optional< int16_t > legacy_type)
void node_free_standard_storage(bNode *node)
void node_copy_standard_storage(bNodeTree *, bNode *dest_node, const bNode *src_node)
const EnumPropertyItem rna_enum_node_compositor_extension_items[]
const EnumPropertyItem rna_enum_node_compositor_interpolation_items[]
std::string ui_description
NodeGetCompositorOperationFunction get_compositor_operation
void(* initfunc)(bNodeTree *ntree, bNode *node)
const char * enum_name_legacy
NodeDeclareFunction declare
ExtensionMode extension_x
ExtensionMode extension_y