[grainsContour] = boundaryContours(grains) - redraws grain boundary segments using a contouring algorithm instead of following pixel edges
[grains,stablefraction] = smooth1(grains,iter,ebsd,varargin) - same as smooth(grains) but stops moving boundary segments before they cross through the boundary neighbour ebsdId positions
smoothTest.m - demo script on mtexdata('twins')
[grainsContour] = boundaryContours(grains) - redraws grain boundary segments using a contouring algorithm instead of following pixel edges
[grains,stablefraction] = smooth1(grains,iter,ebsd,varargin) - same as smooth(grains) but stops moving boundary segments before they cross through the boundary neighbour ebsdId positions