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

Exporting 3d plots as u3d files #2672

Closed
vickyscowcroft opened this issue Dec 11, 2013 · 3 comments
Closed

Exporting 3d plots as u3d files #2672

vickyscowcroft opened this issue Dec 11, 2013 · 3 comments

Comments

@vickyscowcroft
Copy link

Is there any way of exporting a 3d plot, such as a 3d scatter plot, to a u3d file for use in a PDF? It would be really useful for including interactive 3d plots in journal articles which tend to still be distributed as PDFs.
Thanks

@pelson
Copy link
Member

pelson commented Dec 12, 2013

Hi @vickyscowcroft, I think this is a really interesting idea, but one for the matplotlib mailinglist rather than the issue tracker itself. I suspect, though don't know for 100% certain, that this kind of usecase has not been addressed with the 3d plotting functionality of matplotlib - hopefully the mailinglist will be able to help if I'm wrong.

I hope you don't mind but I'm going to go ahead and close the issue - but I for one will look interestingly at what I hope will be a fruitful discussion.

Cheers!

@pelson pelson closed this as completed Dec 12, 2013
@WeatherGod
Copy link
Member

Sorry for the delay in responding.

Unfortunately, with the current architecture of matplotlib, all the 3D data
gets projected into 2D prior to the rendering stage. This is because
matplotlib's drawing core is a 2D layering engine. Therefore, it would
require a complete re-write of matplotlib's core to properly support 3D
graphics. mplot3d is merely a kludge to work around this problem.

One day, I hope to see this re-write occur using OpenGL, but there are
still some limitations that keep us from making that switch (text rendering
in OpenGL is lousy).

In the meantime, I suggest taking a peek at the GlumPy project. It is an
experimental mashup of matplotlib and OpenGL, so it should be very familiar
to matplotlib users. Perhaps that project is much more suited to supporting
these filetypes.

Cheers!

@vickyscowcroft
Copy link
Author

Thank you both for your quick replies and for the explanations.

I'll take a look at GlumPy and see what it can do.

Thanks!

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

3 participants