unconed / MathBox.js

MathBox is a (work in progress) library for making presentation-quality math diagrams in WebGL.
MIT License
1.94k stars 127 forks source link

Added point labels for curves by adapting Labels.js #9

Closed jakemoves closed 10 years ago

jakemoves commented 10 years ago

Hey Steven,

I put together basic point label functionality and thought I would share it with you in case it's useful. It's not fancy but it is working for what I need. If you have suggestions to clean it up or anything, please let me know.

I have only altered the Curve class to make use of it.

I wasn't able to run the build script on my machine successfully, so I made my changes to the files in /src and then manually replaced the relevant sections in MathBox-bundle.js for testing.

I added PointLabels.html so you can see it in operation.

Thanks for the great library!

Best, Jacob

PS This is my first time sending a pull request so if I've done anything stupid or have missed something I should have done, please let me know.

unconed commented 10 years ago

This is a feature I'd like to add in a more general fashion to MathBox 2, so I'm not going to merge it. But I'll definitely review this for ideas.