Jump to content

Efficient orbit lines for planets?


d13
 Share

Recommended Posts

Hi Everyone!

Can anyone suggest an efficient way to dynamically draw an ellipse that represents the orbit of a rotating planet?

I've tried a few different things but so far they've all been too performance heavy.

 

First, I added simple spheres trailing each planet that acted as orbit trace markers.

That works, but is way too slow.

Second, I tried creating a tube to represent the orbit by capturing an array of planet positions, and then using Path3D and getCurve to create a tube.

That also works, but is again too slow.

 

However, something like this *might* be fast enough:

1. Capture the planet's positions at point A and point B.

2. Use those two points to extrapolate an ellipse.

3. Draw the ellipse.

 

Does that make sense, and, if so, does anyone know how to do that?

Thanks!!

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...