Latex renderer in JOGL

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Latex renderer in JOGL

mahesh
Can Somebody guide me some latex renderer available to be used with jogl. I need to show Math equations on opengl window.
If there is no renderer available, I will appreciate any help or suggestion in writing a new latex renderer.
Reply | Threaded
Open this post in threaded view
|

Re: Latex renderer in JOGL

gouessej
Administrator
Hello

Use jlatexmath.

Create a BufferedImage with TeXFormula.createBufferedImage() and use AWTTextureIO to convert it into a texture that you can use with JOGL.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Latex renderer in JOGL

mahesh
Thans for the response.
jlatexmath is was my first choice but what about dynamic equations ? For example if there are many equations and few of them are continuously updating. Do I need to create buffered Image for the equation everytime and upload to gpu again (May be before each draw call)?

Writing buffered image on large texture is good for static equations where packed size of buffered image for each equation is known and fixed. But will multiple equations(25 to 30) be an issue as each equation may have its own texture so there will be multiple texture bind unbind calls?
Reply | Threaded
Open this post in threaded view
|

Re: Latex renderer in JOGL

gouessej
Administrator
You'll have to create a buffered image each time an equation changes if the object representing it is mutable. Don't do any premature optimizations.

Many games that don't use a texture atlas perform a lot more than 30 texture bind operations by draw call, it's not a problem.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Latex renderer in JOGL

mahesh
Thanks for the really useful info. You are always there to help!
Reply | Threaded
Open this post in threaded view
|

Re: Latex renderer in JOGL

gouessej
Administrator
You're welcome :)
Julien Gouesse | Personal blog | Website