But there is the problem. I need to put in a functor, so I don't know the type. And since I cannot define the functor inside the header, I cannot deduce the type.
So I need to hide or post-pone the type in some way. So this is what I wanted to ask. What is good solution for this kind of situation? What are some good techniques?

Ah, so it does. Long time last since I used boost::bind.
It seems like an acceptable solution, for now, at least.

Although, still, this seems like a compromise. What if I have to do this with a generic class taking one or more functors?
I would either have to rewrite them or use some other solution.

12-08-2010

whiteflags

Unfortunately the only other way I know is to make class CVideoEncoderforN8Dlg a template too. But I think you knew that because you said:

Quote:

... And since I cannot define the functor inside the header, I cannot deduce the type.

About that I do not understand. Functors are types, so you can separate the implementation from design like normal. If the functors themselves are templates, then you can define them in a separate header and include them later. So there would have to be some other reason why you can't deduce the type. I do not think the inheritance precludes this.