mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
planner: pass in_planner argument to vpmb_next_gradient()
To remove reliance on global state, pass an "in_planner" argument to vpmb_next_gradient(). Thus, calls to in_planner() can be removed. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
93ecad1b04
commit
8103e947aa
4 changed files with 9 additions and 9 deletions
|
|
@ -849,7 +849,7 @@ bool plan(struct deco_state *ds, struct diveplan *diveplan, struct dive *dive, i
|
|||
decostopcounter = 0;
|
||||
is_final_plan = (decoMode() == BUEHLMANN) || (previous_deco_time - ds->deco_time < 10); // CVA time converges
|
||||
if (ds->deco_time != 10000000)
|
||||
vpmb_next_gradient(ds, ds->deco_time, diveplan->surface_pressure / 1000.0);
|
||||
vpmb_next_gradient(ds, ds->deco_time, diveplan->surface_pressure / 1000.0, true);
|
||||
|
||||
previous_deco_time = ds->deco_time;
|
||||
restore_deco_state(bottom_cache, ds, true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue