Skip to content

Commit 4a9402d

Browse files
final scale fix hopefully
1 parent 267c944 commit 4a9402d

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

source/matplot/axes_objects/vectors.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -119,10 +119,9 @@ namespace matplot {
119119
if (normalize_ && m_value != 0) {
120120
double mag = sqrt(u_value * u_value + v_value * v_value +
121121
w_value * w_value);
122-
double scale = mag / m_value;
123-
u_value *= scale / mag;
124-
v_value *= scale / mag;
125-
w_value *= scale / mag;
122+
u_value *= scale_ / mag;
123+
v_value *= scale_ / mag;
124+
w_value *= scale_ / mag;
126125
}
127126

128127
ss << " " << u_value;

0 commit comments

Comments
 (0)