mirror of
https://github.com/3b1b/manim.git
synced 2025-08-05 16:49:03 +00:00
use quick_point_from_proportion for graph points
This commit is contained in:
parent
fbbea47d11
commit
e764da3c3a
1 changed files with 2 additions and 2 deletions
|
@ -151,14 +151,14 @@ class CoordinateSystem():
|
||||||
else:
|
else:
|
||||||
alpha = binary_search(
|
alpha = binary_search(
|
||||||
function=lambda a: self.point_to_coords(
|
function=lambda a: self.point_to_coords(
|
||||||
graph.point_from_proportion(a)
|
graph.quick_point_from_proportion(a)
|
||||||
)[0],
|
)[0],
|
||||||
target=x,
|
target=x,
|
||||||
lower_bound=self.x_range[0],
|
lower_bound=self.x_range[0],
|
||||||
upper_bound=self.x_range[1],
|
upper_bound=self.x_range[1],
|
||||||
)
|
)
|
||||||
if alpha is not None:
|
if alpha is not None:
|
||||||
return graph.point_from_proportion(alpha)
|
return graph.quick_point_from_proportion(alpha)
|
||||||
else:
|
else:
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue