"SetSamples" is new in qwt6. you are mixing qwt versions...