diff options
Diffstat (limited to 'source/blender/nodes/composite/nodes/node_composite_crop.cc')
-rw-r--r-- | source/blender/nodes/composite/nodes/node_composite_crop.cc | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/source/blender/nodes/composite/nodes/node_composite_crop.cc b/source/blender/nodes/composite/nodes/node_composite_crop.cc index d7331732fc7..13d02a707be 100644 --- a/source/blender/nodes/composite/nodes/node_composite_crop.cc +++ b/source/blender/nodes/composite/nodes/node_composite_crop.cc @@ -27,6 +27,8 @@ namespace blender::nodes::node_composite_crop_cc { +NODE_STORAGE_FUNCS(NodeTwoXYs) + static void cmp_node_crop_declare(NodeDeclarationBuilder &b) { b.add_input<decl::Color>(N_("Image")) @@ -163,11 +165,6 @@ class CropOperation : public NodeOperation { return bnode().custom2; } - NodeTwoXYs &get_node_two_xys() - { - return *static_cast<NodeTwoXYs *>(bnode().storage); - } - /* Returns true if the operation does nothing and the input can be passed through. */ bool is_identity() { @@ -190,7 +187,7 @@ class CropOperation : public NodeOperation { void compute_cropping_bounds(int2 &lower_bound, int2 &upper_bound) { - const NodeTwoXYs &node_two_xys = get_node_two_xys(); + const NodeTwoXYs &node_two_xys = node_storage(bnode()); const int2 input_size = get_input("Image").domain().size; if (get_is_relative()) { |