ID 385897 - Nuke crashes when a Dilate node uses two cropped images combined by a ChannelMerge as a source with inverted cropped image as the mask input.

Follow

Problem summary
Nuke crashes when a Dilate (Erode>Fast) node uses two cropped images (merged by a ChannelMerge) as a source and uses an inverted cropped image as the mask input.

From comprehensive testing, the issue appears to be related to the Dilate nodes inability to interpret the specific combination of two combined bounding boxes when the matte input is also using a bounding box that has been inverted.

Customer reported version
nuke.10.5v7

Customer reported platform
n_a_linux

Steps to reproduce

Open the attached Nuke script and enable the Dilate node.
Result: Nuke crashes

or

1) Open a new Nuke session

2) Create a Constant node, setting the node's format to 4000x3000 and the colour value to 1

3) Create a Crop node connected to the Constant, then crop the left and right sides of the image in the viewer


4) Merge the Constant node with the Crop node using a ChannelMerge node, using the Crop as the B input and the Constant as the A input


5) Within the ChannelMerge node, set the mix value to 0


5) Create a new Crop node from the Constant node, and when viewing the ChannelMerge node, crop in a bit from the right, ensuring that you stay out of the white region.


6) Create an Invert node under the Crop node to invert the alpha. (see below for node tree reference)


7) Create an Dilate (Erode>Fast) node

8) Connect the input of the Dilate node to the ChannelMerge node

9) Connect the mask input of the Dilate node to the Invert node

10) Disable to Dilate node

11) View through the Dilate node and re-enable the Dilate node
Result: Nuke crashes

Note: This issue will not occur in the above reproduction if:

a) The ChannelMerge's mix value is set to 1
or
b) The Invert node is disabled/removed
or
c) The Crop nodes are disabled/removed
or 
d) The source image is lower than 4000 pixels in height

Expected behaviour
Nuke should not be crashing when the Dilate (Erode>Fast) node is active and viewed through the Viewer using the above setup

Actual behaviour
Nuke crashes when the Dilate (Erode>Fast) node is active and viewed through the Viewer using the above setup

Workaround
There are several workarounds that could be used, only if you cannot remove one of the above mentioned nodes.

If you require the above setup, you have several options:

1) Use an Erode (Blur) node as appose to an Dilate (Erode>Fast)

2) Use a CopyBBox to copy the bounding box from before the ChannelMerge node to after the ChannelMerge node


3) Instead of a ChannelMerge node, create a Merge node and set from union to intersection



Reproduced by support
This bug has been reproduced in:
Nuke 11.3v2 - Windows 7 - CentOS 7 - MacOS 10.13.6
Nuke 11.3v1 - Windows 7
Nuke 11.2v5 - Windows 7
Nuke 11.2v1 - Windows 7
Nuke 11.1v1 - Windows 7
Nuke 11.0v1 - Windows 7
Nuke 10.5v1 - Windows 7
Nuke 10.0v1 - Windows 7
Nuke 9.0v1 - Windows 7
Nuke 8.0v1 - Windows 7 - CentOS 7 - MacOS 10.13.6

Earliest version tested
Nuke 8.0v1
- This issue appears to be in all versions of the product

    We're sorry to hear that

    Please tell us why