add the possibility to ask for planes of a certain size
fix memory leak