Если я предполагаю, что комментарий Марка Сетчелла правильный, то с помощью командной строки Imagemagick вы можете сделать следующее. Извините, я не знаю RMagick.
Введите:

Что я делаю:
1. Read the input image.
2. Copy the input image and add 80% to make it whiter
3. Copy the image and fill it with white, then draw a black rectangle where you want to keep the original color. This will be a mask image
4. Use the mask image to composite the original and the white image together
5. Add a blue border
6. Save the result
convert lena.png \
\( -clone 0 -evaluate add 80% \) \
\( -clone 0 -fill white -colorize 100 \
-fill black -draw "rectangle 100,100 150,150" -alpha off \) \
-compose over -composite \
-fill none -stroke blue -strokewidth 5 \
-draw "rectangle 100,100 150,150" \
result.jpg

Настройте 80% на любое значение, которое вам нравится, чтобы сделать входной сигнал более белым.
Возможно, 50% приятнее.
