I don’t know if the code supports it now but I found this oldish issue and another question/answer.
please feel encouraged to edit OpenCV source to your liking and submit a pull request.