Is there a particular reason that we pass the filter in the constructor rather than providing it as a parameter here? Just wondering if there might be circumstances where we want to use the same Sampler but with different filters?

Also, is there any reason we pass the name of a filter rather than a Filter *? It seems more natural to me to be passing a Filter itself, so one can be constructed however you'd like.

Another thing I've been wondering about is the Filter::construct() method, and whether it belongs in Filter or not - is it possible that the construct() type behaviour and table of weights would be better off in the Sampler? I don't profess to be particularly on top of this side of the codebase (which is why my comments are largely cosmetic), but it always struck me as a bit odd that Filters have their own storage and presumably can't be shared across threads because of that. Would it make sense to move that logic into the Sampler? As far as I can tell in reading the new sample( float, float ) method, we reinitialise the weights every single time, so storing them in the filter isn't really of any benefit, at least for the sample() method - perhaps it has benefits in Reformat?