-
Notifications
You must be signed in to change notification settings - Fork 315
getDataURL parameters useBgImage doesn't seems to work #131
Comments
any updates here? |
any updates here? |
Yes as I thought the function called was the bad one, if i remember well you just need to remove "this." in the this.drawImage : |
Can you please explain exactly how / where you did edit this in other to get it to work? I've looked into the node_modules for an index.js but couldn't manage it... thanks |
any updates here? |
Still not working. Any updates? @mitjana Could you please share your modified |
@embiem I am currently investigating what is happening when getting the image data with the background. Disclaimer: I haven't really worked a lot with canvas elements ✌️ In the index.js on line 178, you save the reference to the canvas.
In total, the library uses four canvas instances. I found out that the background image is part of the canvas with the name "grid". Is this a reason why the background image is not part of the canvas we are trying to save? I hope that is somewhat clear. |
Hello, I hope it can help you. |
@mitjana Thank you so much for creating the pull request ✌️ I've just tested it locally and I am getting the following runtime error:
How did you solve this issue? @embiem Could you please have a look at the issue? I really like your library and would love to integrate it into our project fully. But this feature would be required for us. Please let me know if you need further details! |
Hi there, @skuntze I think you may have a clue concerning the canvas ref at line 178 in index.js. Seems like we get only the drawings but not the bgImage as it is drawn on the canvas grid. I'm no expert but it looks like a good lead, right ? @embiem I really appreciate your work on this library. I would like to use background image in my project too but as it's still not working... |
Hi there. I had the same problem so I made this. |
Hello,
Thanks for your package, it is pretty easy to use and understand.
I need to save the background as well as the drawing on it so I set the parameter useBgImage to true but this doesn't seems to work.
I looked into the source code for the getDataURL but the function called by this.drawImage doesn't seem to do anything to the export, on the other hand I saw you import another function called drawImage that could achieve what I what need but it is not used in index.js.
Could you help me with this issue ?
The text was updated successfully, but these errors were encountered: