Background¶
- class Background(inner_color: Color, outer_color: Color, width: int = 270, height: int = 270, expansion: float = 0.5)[source]¶
A radial gradient background that can be used to visualize the exponential expansion of space.
Examples
Example: BackgroundExample ¶
from manim import * from colour import Color from hmanim.native import Background class BackgroundExample(Scene): def construct(self): # The plane that all our hyperbolic objects live in. background = Background( Color("#0021FF"), Color("#D13B1D"), expansion=0.25 ).scale(2) self.add(background)
from colour import Color from hmanim.native import Background class BackgroundExample(Scene): def construct(self): # The plane that all our hyperbolic objects live in. background = Background( Color("#0021FF"), Color("#D13B1D"), expansion=0.25 ).scale(2) self.add(background)