Change output view of pin cushion distortion

2 views (last 30 days)
I'd like to change to change the output view of the pin cushion example (referenced below) to include the part of the checkboard that is being cropped off by keeping the output the same. I've played around with increasing the nrow,ncols and properties in imref2d like and the WorldLimits and ImageSize but can't seem to figure it out. Can someout point me in the right direction?
Image 9: Apply Pin Cushion Transformation to Checkerboard @ https://www.mathworks.com/help/images/creating-a-gallery-of-transformed-images.html
Thanks in advance.

Accepted Answer

DGM
DGM on 12 Jun 2021
Maybe try something like
s = r - (b/rmax.^2)*r.^3; % this is the same as before
s = s/(max(s(:))/rmax); % or use whatever scaling factor you want

More Answers (0)

Products


Release

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!