mirror of
https://github.com/3b1b/manim.git
synced 2025-08-05 16:49:03 +00:00
fixed drawing bars of height 0
This commit is contained in:
parent
bcf90c2b89
commit
aa178628a8
1 changed files with 4 additions and 0 deletions
|
@ -126,6 +126,10 @@ class Histogram(VMobject):
|
|||
stroke_width = self.bar_stroke_width,
|
||||
stroke_color = self.stroke_color,
|
||||
)
|
||||
if bar.height == 0:
|
||||
bar.height = 0.01
|
||||
bar.generate_points()
|
||||
|
||||
t = float(x - self.x_min)/(self.x_max - self.x_min)
|
||||
bar_color = interpolate_color(
|
||||
self.start_color,
|
||||
|
|
Loading…
Add table
Reference in a new issue