This article http://www.opengl.org/resources/code/samples/mjktips/Feedback.html
explains how to use OpenGL feedback to create postscript drawing
commands from OpenGL calls. The same technique can be used for
creating PDF (which has a similar rendering model to postscript).
This would be a fair chunk of work to implement, however.
Alex.
2008/10/10 Alex Holkner <alex.h...@gmail.com>:
Yeah details, details ... but I still would second the Python Nutter's
(wow, what a name) basic argument - there are easier ways to do this,
don't try to make your life too hard ;)
One approach to consider is just outputing the color buffer to a
format supported natively by pyglet such as png, and use external
tools such png2eps, epstool, etc to get it where you want. Also,
ImageMagick (http://www.imagemagick.org/script/formats.php) has a
dizzying array of supported formats, including eps, ps, pdf ...
Another thing you might want to experiment with is PIL's pdf output
support (http://www.pythonware.com/library/pil/handbook/format-pdf.htm)
in combination with a library such as ReportLab
(http://www.reportlab.org/). This is likely a more cross-platform
solution.
Surgeon General's Warning: I have nil experience with this specific
problem, so ignore everything I've said.
Drew