Seeking QGIS geometry generator manual?

There is no such site so far. The feature is rather new and usage examples are only starting to emerge now.

For your specific use case, I'd still recommend to create a line layer with all connections. You can then filter this layer using Atlas and don't need to worry about anything else.


This is possible using a different 'geometry generator' to the one that you originally intended I suspect, You can avoid having to generate the all connections line layer by using a virtual layer:

Some points:

sample points

Add a virtual layer using the following SQL - the JOIN matches every point to every other, and the line geometry is generated using the Spatialite MakeLine function:

SELECT s.id 'ID1', c.id 'ID2' , MakeLine(s.geometry,c.geometry) 'geometry'
  FROM SamplePoints AS s JOIN SamplePoints AS c 
  WHERE s.id <> c.id

The result:

Points with connecting lines

This virtual table could then be filtered dynamically using the Atlas functionality.

Dynamically generating curved lines would be trickier, but should still be possible. Curving them in a cartographically appropriate way (considering the distribution of the other lines) is probably beyond what can be achieved with virtual layers.

Update:

With a little tinkering and a lot of reference to the Spatialite function list I have generated curved lines:

Points with curved connecting lines

The virtual layer SQL for this is below. Note that all permutations are shown, and reversing the order of the start and end location generates the complementary curve.

SELECT s.id 'ID1', c.id 'ID2' , 
MakeArc(
    X(Project(MakePoint((X(s.geometry)+X(c.geometry))/2,(Y(s.geometry)+Y(c.geometry))/2),distance(s.geometry,c.geometry),Azimuth(s.geometry,c.geometry) - PI()/2)),
    Y(Project(MakePoint((X(s.geometry)+X(c.geometry))/2,(Y(s.geometry)+Y(c.geometry))/2),distance(s.geometry,c.geometry),Azimuth(s.geometry,c.geometry) - PI()/2)),
    distance(s.geometry,c.geometry) * 1.1180339887,
    90 - azimuth(Project(MakePoint((X(s.geometry)+X(c.geometry))/2,(Y(s.geometry)+Y(c.geometry))/2),distance(s.geometry,c.geometry),Azimuth(s.geometry,c.geometry) - PI()/2),s.geometry) * (180/PI()),
    90 - azimuth(Project(MakePoint((X(s.geometry)+X(c.geometry))/2,(Y(s.geometry)+Y(c.geometry))/2),distance(s.geometry,c.geometry),Azimuth(s.geometry,c.geometry) - PI()/2),c.geometry) * (180/PI()),
    27700,
    2) 'geom' /*line:27700*/
  FROM SamplePoints AS s JOIN SamplePoints AS c 
  WHERE s.id <> c.id