arb::pwlin can return an arb::msegment{id, p', q'} describing a subsection of the 'original' segment (id, p, q) such that
p' = q + u(q - p) and q' = p + v(q - p) for u, v: [0, 1].
At the moment, the renderer just inspects the id and returns the full segment regardless of any points.
Idea
- Add a field
f to all points in the renderer that is 0 on the proximal and 1 on the distal end. Ensure linear interpolation.
- Pass a pair
(u, v) to each frustrum when rendering based on the fractions above. Ensure constant.
- In the fragment shader
discard if not u < f < v.
Issues
- Need to compute
(u, v) from (p, q, p', q')
- Quite wasteful; usually we will show full segments, but have added 4 floats to each point
See: NeuroML/NeuroML2#144
arb::pwlincan return anarb::msegment{id, p', q'}describing a subsection of the 'original' segment(id, p, q)such thatp' = q + u(q - p)andq' = p + v(q - p)foru, v: [0, 1].At the moment, the renderer just inspects the
idand returns the full segment regardless of any points.Idea
fto all points in the renderer that is0on the proximal and1on the distal end. Ensure linear interpolation.(u, v)to each frustrum when rendering based on the fractions above. Ensure constant.discardif notu < f < v.Issues
(u, v)from(p, q, p', q')See: NeuroML/NeuroML2#144