Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More vPython compatibility #29

Open
rbarve opened this issue May 4, 2015 · 2 comments
Open

More vPython compatibility #29

rbarve opened this issue May 4, 2015 · 2 comments

Comments

@rbarve
Copy link
Contributor

rbarve commented May 4, 2015

If we want to have the brython-glow interface look closer to vPython than glowscript we need to consider the notes at http://www.glowscript.org/docs/GlowScriptDocs/VPython-vs-GlowScript.html

One would think, for instance, that a sphere ought to take a radius argument of type float/int, but as things stand that wont work. One could add an argument 'size' of the appropriately scaled vector whenever one sees a brython sphere() with argument 'radius'?

@ghost
Copy link

ghost commented May 5, 2015

I'd be willing to add a radius argument. How would one translate a radius to a size vector?

@rbarve
Copy link
Contributor Author

rbarve commented May 6, 2015

From the page it seems the size vectors x,y,z component are same as
diameter of sphere .. So in the sphere constructor we could add a size
vector
vec (2,2,2)*kwargs['radius']
whenever kwargs has radius arg but no size arg..
I could take a stab and send a pull request
On 6 May 2015 03:55, "Billy Earney" [email protected] wrote:

I'd be willing to add a radius argument. How would one translate a radius
to a size vector?


Reply to this email directly or view it on GitHub
#29 (comment)
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant