0

I have a point feauture (radar). From this radar, I need to draw straight lines with a separation angle of 0.3° (full circle).

At best, I want to draw the first line by myself with all following lines having a separation angle of 0.3° to the first line.

How do I achieve this in QGIS? I tried the Plug-In "Azimuth and Distance" but was not able to solve my issue.

1
  • I am using QGIS 3.28 Commented Feb 29 at 10:22

1 Answer 1

1

You can use the Processing algorithm Geometry by Expression. Set the Input layer to your point layer, and chose Line for Output geometry type.

Use the following expression:

collect_geometries(
  array_foreach(
    generate_series(0,360,0.3),
    make_line(
      @geometry,
      project(@geometry,500,radians(@element))
)))

It will return a single MultiLineString geometry containing all of the lines. You can then use the Processing algorithm Multipart to Singleparts to get the individual lines as separate features.

The second argument of the project function (500 in the example) controls the length of the lines.

The result (shown with 5° step so that lines are actually visible): Result screenshot

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.