machinevision-toolbox-matlab icon indicating copy to clipboard operation
machinevision-toolbox-matlab copied to clipboard

Bug in istereo with vshift

Open JulianLelandBell opened this issue 3 years ago • 0 comments
trafficstars

Two bugfixes (I think) in istereo:

  1. 108: variable was given as vshift instead of opt.vshift in 2 locations
  2. 109 and 110: zero-indexing-related error produces inconsistent image sizes --> stereo_match doesn't work. My solution:
    if opt.vshift ~= 0
        if opt.vshift > 0
            L = L(1:end-opt.vshift+1,:);
            R = R(opt.vshift:end,:);
        else
            opt.vshift = -opt.vshift;
            L = L(opt.vshift:end,:);
            R = R(1:end-opt.vshift+1,:);
        end
    end

JulianLelandBell avatar Feb 24 '22 20:02 JulianLelandBell