Result[B] := Min(Wave1[B] + Wave2[B], 255); that should do it