I have not looked at your project, but let me put it like this:
What happens when you call something in QtConcurrent? The function that you pass to it is called repeatedly.
How do you call scaled? You use an object instance, inst, and use the -> or . operator: inst->scale( ... ).
The QtConcurrent framework does not have access to this. scale is simply a pointer to the scale function, not a specific class instance.
Thus, scale cannot be an ordinary class function. It must be able to execute without a this pointer. By making scale static, you can call it either as MyClass::scale( ... ), or inst->scale( ... ). Which is good enough for QtConcurrent (and probably your needs as well).





Reply With Quote
Bookmarks