The text labels are always visible, also through geometry. The line closest to label text was set to no depth test, probably to match the text visibility. This is changed by this commit, and the top line will be hidden by reservoir geometry.
Introduced by https://github.com/OPM/ResInsight/issues/266
* Require that the length of the new segment is shorter than the *current*
distance to the end of the original segment, rather than the length of the
complete original segment.
* Note that this implementation simply removes vertices that are outside the range.
* It would look far better to insert vertices at the boundary when a segment is heading
out of range. This is more complicated.
* New vertices are successfully created in the intersections between the
curve and draw surface triangles
* New vertices are also inserted along the bottom edge of the filled curve.
* However, new vertices will still need to be inserted in the lines connecting the
top of the curve and the bottom where they intersect with the triangles.
* The option for filled curves remain hidden in the GUI. See #2860.
# Please enter the commit message for your changes. Lines starting
* Project existing points onto triangles first and make sure we choose the right triangle by
sorting possible projections by distance.
* Also allow some tolerance for the inside check.
* Create the new vertices by projecting the curve segment vector onto each triangle plane
before looking for intersections with the triangle edges.
* Makes more sense user wise and makes for better code.
* Helps refactor code to relate grids to curves so the curves can have access to the grid
it is being drawn on.
* This will help fix#2825 by being able to project curve points onto the exact triangle geometry.
* The previous drawable and geometry was kept if switching to a result type without
valid points.
* The drawable is then stuck in position until switching back to a result
type that has valid points.
* This commit fixes this by clearing the geometry every time you draw.
* TODO: cache values when it is possible to do so.