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

Make it easy to use Isomer with node-canvas #16

Closed
jdan opened this issue Apr 28, 2014 · 4 comments
Closed

Make it easy to use Isomer with node-canvas #16

jdan opened this issue Apr 28, 2014 · 4 comments

Comments

@jdan
Copy link
Owner

jdan commented Apr 28, 2014

node-canvas is a module that allows you to draw to a virtual canvas and export your drawing as a PNG. I'd like to make it easy to generate isomer drawings with node-canvas.

Doing this means we might need to rearrange some of the files to use a more traditional module pattern - at which point we can probably make it very easy to install isomer from NPM, Bower, and Component.

@rcmaniac25
Copy link
Contributor

I'm tempted to say that's a bit heavy. Not sure why you would need an entire library to do this.

document.createElement('canvas') will get you a Canvas element you can work with.
canvasElement.toDataURL() returns a data URL for image/png, though you could specify PNG explicitly if you want by doing toDataURL('image/png').

@jdan
Copy link
Owner Author

jdan commented Apr 30, 2014

So people don't have to use a web browser.

@rcmaniac25
Copy link
Contributor

My understanding was a bit off. The goal you have I do at work, but just checked some of the source and found that we support canvas on Node.js using node-canvas. So...

@jdan
Copy link
Owner Author

jdan commented May 1, 2014

Closed via #22. Will update docs on this over the next few days.

@jdan jdan closed this as completed May 1, 2014
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

2 participants