Compare commits
No commits in common. "f58dd8816f059fb72dd430ae21982c051e669f46" and "ea38bdaa502f18cad20e8cdc938158ca03d11fbd" have entirely different histories.
f58dd8816f
...
ea38bdaa50
1 changed files with 6 additions and 7 deletions
|
@ -8,7 +8,7 @@ WIND_SPEED_MAX = 140 # knots
|
|||
WIND_SPEED_MIN = 10
|
||||
WIND_SPEED_STEP = 10
|
||||
|
||||
WIND_DIR_STEP = 30 # degrees
|
||||
WIND_DIR_STEP = 45 # degrees
|
||||
|
||||
def radians(degrees: float) -> float:
|
||||
return (degrees + 90) * (math.pi / 180.0)
|
||||
|
@ -108,8 +108,7 @@ class Hodograph():
|
|||
text = "%dkt" % speed
|
||||
extents = cr.text_extents(text)
|
||||
|
||||
for angle in (0, 180):
|
||||
sx, sy = self.sample_to_screen(speed, angle)
|
||||
sx, sy = self.sample_to_screen(speed, 180)
|
||||
|
||||
cr.move_to(x + sx + extents.width * 0.25,
|
||||
y + sy - extents.height * 1.5)
|
||||
|
|
Loading…
Add table
Reference in a new issue