A detector array signal processor of an imaging system, comprising: a counter ; and a discriminator including: a set of comparators ; a window width generator that is configured to generate a window width for a window based spectrum measurement; and a set of reference signal generators , each corresponding to a different one of the comparators, which are configured to generate different reference signals; wherein, in response to the discriminator being in a window based spectrum measurement mode, a first reference signal generator for a first comparator is configured to generate a first reference signal that is supplied to the first comparator and that is added with the window width to create a second reference signal, which is to be supplied to the second comparator, wherein the first comparator is configured to compare a peak height of a pulse indicative of an energy of detected radiation with the first reference signal and to produce a first output indicating which of the peak height or the first reference signal is greater; wherein the second comparator is configured to compare the peak height with the second reference signal and to produce a second output indicating which of the peak height or the second reference signal is greater; and wherein the counter is configured to increment a first count value in response to the peak height exceeding the first reference signal and a second count value in response to the peak height exceeding the second reference signal. a counter ; and a discriminator including: a set of comparators ; a window width generator that is configured to generate a window width for a window based spectrum measurement; and a set of reference signal generators , each corresponding to a different one of the comparators, which are configured to generate different reference signals; a set of comparators ; a window width generator that is configured to generate a window width for a window based spectrum measurement; and a set of reference signal generators , each corresponding to a different one of the comparators, which are configured to generate different reference signals; wherein, in response to the discriminator being in a window based spectrum measurement mode, a first reference signal generator for a first comparator is configured to generate a first reference signal that is supplied to the first comparator and that is added with the window width to create a second reference signal, which is to be supplied to the second comparator, wherein the first comparator is configured to compare a peak height of a pulse indicative of an energy of detected radiation with the first reference signal and to produce a first output indicating which of the peak height or the first reference signal is greater; wherein the second comparator is configured to compare the peak height with the second reference signal and to produce a second output indicating which of the peak height or the second reference signal is greater; and wherein the counter is configured to increment a first count value in response to the peak height exceeding the first reference signal and a second count value in response to the peak height exceeding the second reference signal. <EOS>