[Insight-users] Histogram modification - troubles with SetFrequency
sacrif
markus_m at gmx.net
Fri Dec 4 03:43:45 EST 2009
Hi, I finally found out what the problem is. The histogram is defined as
const HistogramType * histogram; or HistogramType::ConstPointer histogram;
However the SetFrequency method is a not const method. Therefore non of the
4 SetFrequency methods is applicable on it.
The problem is that the GetOutput() method of the
itk::Statistics::ScalarImageToHistogramGenerator class returns a "const
HistogramType *" which I assign to my "const HistogramType* histogram"
pointer. So I can only define the histogram as const. But then the
SetFrequency would not work. (and results in the compilation error: error
C2663: 'itk::Statistics::Histogram<TMeasurement>::SetFrequency' : 4
overloads have no legal conversion for 'this' pointer...<--as written in my
previous post)
Is it possible that a histogram as I defined it can't be changed as soon as
it is created? Somehow I can't imagine this is the case. But at the moment I
can only imagine to write the values in an std::vector to proceed working on
it.
I would appreciate any onther advice.
Thank you & kind regards
--
View this message in context: http://old.nabble.com/Histogram-modification---troubles-with-SetFrequency-tp26615939p26635812.html
Sent from the ITK - Users mailing list archive at Nabble.com.
More information about the Insight-users
mailing list