To make compositing easier, UE5 has a series of nodes to serve some of the most common compositing operations. Here, each one is briefly highlighted and has an explanation of its purpose.
Click image to expand.
The compositing material nodes expect a float4 input, so make sure you're passing in RGBA and not just RGB.
Over
This node layers one image (A) over another (B), using the alpha from input A.

This node expects that the input color channels are pre-multiplied with the image's alpha.
In
This node returns the portion of A that is inside the shape of B.

Out
This node returns the portion of A that is outside the shape of B.

PreMult
This node multiplies the input's RGBA channel by its alpha.

UnPreMult
This node divides the input's RGBA channel by its alpha.

KeyMix
This node layers two images together using a specified mask.
