Skip to content

A custom component that allows selecting minimum and maximum values interactively, using a histogram as a reference

License

Notifications You must be signed in to change notification settings

MATLAB-Graphics-and-App-Building/histogramRangeSelector

Repository files navigation

histogramRangeSelector

View histogramRangeSelector on File Exchange

Version: 1.0

histogramRangeSelector

This component is designed to allow specification of minimum and maximum values for an intensity image, or independently for the RGB channels of an image. It features a histogram for showing the intensity data and editfields with accompanying lines for setting the minimum and maximum. When the values change, the MinChanged/MaxChanged events fire.

How to use:

c = histogramRangeSelector; % create the component

im = imread('myimage.png');     % read an image
[n,x]=histcounts(im(:),0:255);  % collect histogram data
set(c,'HistogramBinEdges',x,'HistogramBinCounts',n);


c.MinChangedFcn=@myMinChangedFunction;
c.MaxChangedFcn=@myMaxChangedFunction;

About

A custom component that allows selecting minimum and maximum values interactively, using a histogram as a reference

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Packages

No packages published

Languages