[PATCH] Improve partial pressure graphs

Dirk Hohndel dirk at hohndel.org
Sat Mar 15 12:12:44 PDT 2014


On Sat, 2014-03-15 at 19:00 +0100, Jan Mulder wrote:
> This being my first submission to this list, first a very short 
> introduction.
> 
> I'm an active technical diver, both in long range cave diving context 
> and a little (deep) wreck diving. Obviously, this involves a lot of 
> gear, different gasses, scooters, and for some dives also a PSCR style 
> rebreather. Most of my contribution to this list can be seen in this 
> context, but keeping in mind that the software shall be useful for all 
> levels of diving; any technical diving extensions shall not hinder the 
> beginning diver.

Excellent. We are thrilled to have a tech diver join the developer team.
Your description of your approach to extending Subsurface very much
mirrors our desire as well. Thank you for spelling it out in detail.

As a side note, we used to have a tech diver named Jan on this team, so
you will find occasional references to "Jan" here or there - sadly in
two weeks will be the first anniversary of his final dive in the
Bodensee :-(

> Attached, a first patch, called "[PATCH] Bugfix: generalize pp graphs to 
> allow for multi over-threshold periods".
> 
> Especially in O2 decompression parts of a dive, the pp02 is typically 
> very close to the threshold value (normally 1.60 bar). The old 
> implementation of the pp profile graphs assumes that there is exactly 1 
> consecutive set of samples that needs to be in the "warning color". This 
> results in an erroneous display of the mentioned graphs, connecting 
> multiple episodes of too high pp with bogus lines in between.
> 
> This fix generalizes the pp graph logic to allow for multiple segments 
> of high pp, each to been drawn separately in the "warning color".
> 
> I've attached  2 screen shots to show the problem (and the fix).

Thanks for a great explanation and visualization of the issue. And a
solid first patch that solves the problem. You are making the work of
the maintainer very easy - no complaints at all.

In cases like this one thing that would be nice is a sample dive that
shows the issue (and renders correctly with the fix).

It may be overkill to include the complete dive that you used for the
visualization, but it should be very easy to use our Add Dive feature to
create a dive that shows the same pattern. Would you be interested in
submitting this as dives/test32.xml ?

Anyway, your patch has been added to master and pushed.

Welcome to the team!

/D





More information about the subsurface mailing list