7

I have 30 points, each one represents the SE corner of a 1.5 by 1.5m plot. I want to create polygons to represent these plots.

How do I create square polygons from a corner point and with a specific length?

Taras
  • 32,823
  • 4
  • 66
  • 137
Kate
  • 99
  • 4

2 Answers2

16

There is "Vector geometry > Geometry by Expression" tool in Processing Toolbox. You should use in a projected coordinate system.

  • Select "Polygon" as "Output geometry type" option.

  • Click "Expression" button (highlighted blue square)

  • And paste the following expression

    make_rectangle_3points(  
      make_point($x, $y), 
      make_point($x, $y + 1.5),
      make_point($x - 1.5, $y + 1.5)
    )
    

enter image description here

Result:

enter image description here

Kadir Şahbaz
  • 76,800
  • 56
  • 247
  • 389
12

Use geometry by expression to create a point at 315 degrees azimuth from your point with a distance of the hypotenuse of the square, then create a box around the two points:

bounds(collect_geometries( $geometry, project( $geometry, sqrt(2*1.5^2),  radians(315))))

enter image description here

BERA
  • 72,339
  • 13
  • 72
  • 161