You can just use vOutpoints.assign(setSelected.begin(), setSelected.end());, I think.