GFTransform

 

function call:

[out_img1]=vsg('GFTransform',in_img1);

 

Arguments:

in_img1 input image, 3 channel RGB, 1 channel greyscale or binary image, or DICOM image.

 

Description:

out_img1 – the output image values are set as the distance that input white pixels are from the nearest edge of the white region of which they are part of.

 

Example:

img = openimage('crown.jpg');

h=figure;image(img);set(h,'Name','Input Image');

[out_img1]=vsg('Threshold',img,100);

[out_img1]=vsg('GFTransform',out_img1);

h=figure;imagesc(out_img1(:,:,1));colormap(gray);set(h,'Name','GFTransform Transform');

 

Notes:

1. For DICOM images, the function operates on all slices separately.

2. For RGB images, the function operates on all colour planes separately.

3. Ensure that binary images have a range {0.255}.

Home       Functions    Back