From: Linus Torvalds Date: Sun, 23 Oct 2011 14:52:45 +0000 (+0300) Subject: Handle 'gas change' events correctly X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=2b4fa480ae57766889c5a20ff1cb59427469d401;hp=2b4fa480ae57766889c5a20ff1cb59427469d401;p=ext%2Fsubsurface.git Handle 'gas change' events correctly Dirk wrote the multi-cylinder support assuming that the dive computer always gives the selected cylinder index in the sample data - that's what his Uemis does, and it makes sense for any dive computer that supports multiple pressure transmitters. However, the other case is a dive computer where the pressure samples are all from cylinder 0, and any other cylinder will have the starting and ending pressure set by hand. And the gas change events show when the cylinder change happened. So this creates a "turn gas change events into pressure sample fixups" phase just before we actually analyze the pressures. That way the pressure analysis can alway sdo the right thing, regardless of how the data was originally stores in the dive. Signed-off-by: Linus Torvalds ---