File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ Shapes, Images and Positions
20
20
.. manim :: PointMovingOnShapes
21
21
22
22
class PointMovingOnShapes(Scene):
23
-
24
23
def construct(self):
25
24
26
25
circle = Circle(radius= 1, color=BLUE)
@@ -46,7 +45,9 @@ Shapes, Images and Positions
46
45
class GradientImageFromArray(Scene):
47
46
def construct(self):
48
47
n = 256
49
- imageArray = np.uint8([[i*256/n for i in range(0,n)] for _ in range(0,n)])
48
+ imageArray = np.uint8(
49
+ [[i * 256 / n for i in range(0, n)] for _ in range(0, n)]
50
+ )
50
51
image = ImageMobject(imageArray).scale(2)
51
52
self.add(image)
52
53
@@ -59,8 +60,7 @@ Shapes, Images and Positions
59
60
# Use PIL when you want to import an image from the web
60
61
import requests
61
62
from PIL import Image
62
- img = Image.open(requests.get("https://raw.githubusercontent.com/ManimCommunity/manim/master/logo/cropped.png",
63
- stream=True).raw)
63
+ img = Image.open("../logo/cropped.png")
64
64
img_mobject = ImageMobject(img)
65
65
# this line, when you want to import your Image on your machine
66
66
# img_mobject = ImageMobject("<your image address>")
You can’t perform that action at this time.
0 commit comments