slight changes to histeq