How can I create an ellipse marker with line pattern fill in QGIS?
I have already made simpler symbols, but there is no solution with the ellipse
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It only takes a minute to sign up.
Sign up to join this communityTo get the different symbols for each half of the ellipse:
with_variable('ellipse',
make_ellipse( $geometry, 10, 5, 0), -- make an ellipse and assign it to a variable
rotate(
intersection( -- get intersection of rectangle and ellipse to 'clip' half of it
make_rectangle_3points( -- make a rectangle that is half the bounding box of the ellipse
project($geometry, y_max(@ellipse) - y($geometry), 0), -- project a point from the original point directly north by half the height of the ellipse
project($geometry, y_max(@ellipse) - y($geometry), radians(180)), -- project a point from the original point directly south by half the height of the ellipse
make_point(x_max(@ellipse), y_min(@ellipse)) -- make a point of the 'lower right' corner of the bounds of the ellipse
),
@ellipse -- @ellipse is the variable name of the ellipse made above
),
120, $geometry -- rotate the half-ellipse, 120 is the rotation angle, $geometry is the center of rotation (the original point geometry)
)
)
rotate
by 180 degrees so the new symbol layer aligns with the first (in my case 120
->300
)Units
to Millimeter
for a scalable symbolUse Geometry Generator with the following expression:
make_ellipse(centroid($geometry), 1, 2, 0)
Change values 1 (semi_major_axis) and 2 (semi_minor_axis).
You can use a Filled Marker
.
Filled Marker
(or duplicate first symbol layer)