Way to Mask virtual HeightField mesh in the X and Y axis?

Need help to Mask my Virtual HeightField Mesh with the Slope mask I am using in my shader to only use the Virtual HeightField mesh in the Z axis to avoid stretching on the areas of my landscape that are going in the X or Y direction. My landscape is an imported mesh, not using the landscape tools. Thank you for any help in advance. John