Skip to content

Arrow3D: get_start() and get_end() methods both return np.array([0,0,0]) #4255

Open
@crankycyclops

Description

@crankycyclops

Description of bug / unexpected behavior

Arrow3D doesn't appear to return the correct start and/or end points.

Instead of seeing the start and end points I used to create the 3d error, I get 0,0,0 for both.

Expected behavior

Given the sample code I pasted below, I would expect to see:

array([2., 2., 2.])
array([0., 0., 0.])

Instead I get:

array([0., 0., 0.])
array([0., 0., 0.])

How to reproduce the issue

Code for reproducing the problem
        vectorStart = ORIGIN
        vectorEnd = np.array([2, 2, 2])

        vector = Arrow3D(
            start = vectorStart,
            end = vectorEnd,
            color = BLUE_D,
            thickness = 0.015, # thickness of shaft
            base_radius = 0.06 # radius of the base of the conical arrow
        )

        # Draw the vector
        self.play(Create(vector))

        from pprint import pprint
        pprint(vector.get_end())
        pprint(vector.get_start())
        import sys
        sys.exit(1)

Additional media files

Images/GIFs

Logs

Terminal output
PASTE HERE OR PROVIDE LINK TO https://pastebin.com/ OR SIMILAR

System specifications

System Details
  • OS (with version, e.g., Windows 10 v2004 or macOS 10.15 (Catalina)): Ubuntu 22.04
  • RAM: 24GB
  • Python version (python/py/python3 --version): 3.10.12
  • Installed modules (provide output from pip list):
Package           Version
----------------- -----------
av                13.1.0
beautifulsoup4    4.13.4
click             8.2.0
cloup             3.0.7
decorator         5.2.1
glcontext         3.0.0
isosurfaces       0.1.2
manim             0.19.0
ManimPango        0.6.0
mapbox_earcut     1.0.3
markdown-it-py    3.0.0
mdurl             0.1.2
moderngl          5.12.0
moderngl-window   3.1.1
networkx          3.4.2
numpy             2.2.6
pillow            11.2.1
pip               22.0.2
pycairo           1.28.0
pydub             0.25.1
pyglet            2.1.6
pyglm             2.8.2
Pygments          2.19.1
rich              14.0.0
scipy             1.15.3
screeninfo        0.8.1
setuptools        68.1.2
skia-pathops      0.8.0.post2
soupsieve         2.7
srt               3.5.3
svgelements       1.9.6
tqdm              4.67.1
typing_extensions 4.13.2
watchdog          6.0.0
LaTeX details
  • LaTeX distribution (e.g. TeX Live 2020):
  • Installed LaTeX packages:

Additional comments

I'm not sure if I've misunderstood how this is supposed to work, but I assumed it would return the start and end points of the line that was used to construct the arrow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    🆕 New

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions