Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
jamessanford committed Oct 13, 2015
1 parent d03edbe commit ef83b14
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
3 changes: 1 addition & 2 deletions deltabar/deltabar.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ def get_lib_dir():
# Fix import path for sim_info ctypes
lib_dir = 'apps/python/deltabar/{}'.format(get_lib_dir())
sys.path.insert(0, lib_dir)
# I doubt this is necessary:
#os.environ['PATH'] += ';.'
os.environ['PATH'] += ';.'


class DeltaBarData:
Expand Down
13 changes: 6 additions & 7 deletions deltabar/deltabar_lib/deltabar_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,13 +210,12 @@ def _delta_stripe_color_old(speed_delta):
"""
# NOTE: Scale from 0.0 meters/sec = 1.0 to 5.0 meters/sec = 0.0
# If you change 5.0, change 0.2 to 1/new_value
if not self.bar_new_colors:
x = 1.0 - (min(abs(speed_delta), 5.0) * 0.2)
if speed_delta >= 0.0:
colors = (x, 1.0, x, 1.0)
else:
colors = (1.0, x, x, 1.0)
return colors
x = 1.0 - (min(abs(speed_delta), 5.0) * 0.2)
if speed_delta >= 0.0:
colors = (x, 1.0, x, 1.0)
else:
colors = (1.0, x, x, 1.0)
return colors

@staticmethod
def _delta_stripe_color(speed_delta):
Expand Down

0 comments on commit ef83b14

Please sign in to comment.