BIN2GRAYCODE Conversion

bin2graycode_cvip() - Performs a binary code to gray code conversion on an input image.

Contents

SYNTAX

outputImage = bin2graycode_cvip(inputImage);

Input parameters include:

Output parameters include:

DESCRIPTION

This function performs a binary code to gray code conversion on an input image. Gray code is binary numerical system where two consecutive values differ in only one bit. Gray code is also known as Reflected binary code.

REFERENCE

1. Scott E Umbaugh. DIGITAL IMAGE PROCESSING AND ANALYSIS: Applications with MATLAB and CVIPtools, 3rd Edition.

EXAMPLE

% Read Image

  ipImage1=imread('cam.bmp'); % gray scale image
  ipImage2 =imread('Car.bmp'); % 3 band image

% Call function

  outputImage1=bin2graycode_cvip( ipImage1);
  outputImage2=bin2graycode_cvip( ipImage2);

% Display Input Image

  figure;imshow(ipImage1);title('Input Image 1');
  figure;imshow(ipImage2);title('Input Image 2');

% Display Output Image

  figure;imshow(outputImage1,[]);title('Output Image 1');
  figure;imshow(outputImage2,[]);title('Output Image 2');

CREDITS

Author: Deependra Mishra, October 2017
Copyright © 2017-2018 Scott E Umbaugh
For updates visit CVIP Toolbox Website