필터 지우기
필터 지우기

Is there a code to replace image toolbox function 'ind2gray'?

조회 수: 2 (최근 30일)
Denni Purcell
Denni Purcell 2016년 3월 16일
답변: Walter Roberson 2016년 3월 16일
I am using the 'ind2gray' function of the image processing toolbox and our licence is due to expire. Considering this is the only function of the tool box used I am wondering if there is a code to replace it?

채택된 답변

Walter Roberson
Walter Roberson 2016년 3월 16일
Use the formula shown in http://www.mathworks.com/matlabcentral/answers/159282-convert-from-rgb-to-grayscale-without-rgb2gray to convert your map into grayscale. Then use the indices to index that grayscale data. If the indices are floating point then use the indices directly; if the indices are uint8() or uint16() then double() and add 1 and index with that.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Read, Write, and Modify Image에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by