Render all geometries in an array from geometry generator / QGIS expression editor

How about collect_geometries()?

enter image description here

enter image description here


Geometry Generator is great for building new geometrie(s) for each initial feature. That is, a main limitation is the inability to produce new row of data.

While it is possible to create a complex multi-polygon geometry, as shown by @Kazuikito, it remains a single geometry with a single style.

If you need control over the generated data, say to label the buffers or use a different color per ring, you would have to prepare the buffers before styling them. This can still be an automatic solution if implemented as a virtual layer.

Go the the menu layer / add layer / add-edit virtual layer and enter the following query. Feel free to add any field you wish from your layer (here only the id is included)

WITH RECURSIVE generate_series(value) AS (
  SELECT 1 -- Smallest value
  UNION ALL
  SELECT value+1 FROM generate_series   -- "+1" is the step
   WHERE value+1 <= 10  -- "+1" is the step, 10 is the greatest value
)
SELECT s.value as bufferSize, SingleSidedBuffer(a.geometry, s.value,1) as geometry, a.id
FROM generate_series s, 
     myLineLayer a;

enter image description here