How to freeze the mesh boundaries


I have a question regarding the Freefem++ 2D remesher.

I want to refine only part of my meshing for efficient computation.

The idea is to use trunc function to divide the whole region into two parts.
Then I use the adaptmesh function to refine a part of my mesh.
The thing is, the compatibility between the adapted mesh and the other one can not be guaranteed. Therefore, I am looking for a function that can be used to freeze the mesh boundaries of the two parts.

Thank you very much.

Best regards,