Answer the question
In order to leave comments, you need to log in
Image::crossOrigin attribute?
Somehow I came across this code in the sources, it seems, processingJS:
if (path.indexOf('data:image/') !== 0) {
img.crossOrigin = 'Anonymous';
}
Answer the question
In order to leave comments, you need to log in
I once wrote something on canvas, there was pixel-by-pixel image processing. That is, I took the canvas using the getImageData function and did something there. So, if the image was not on the same server as my site, then some kind of error popped up, this is such a type of protection. So I read on one foreign forum, in order to avoid this error (bypass this protection), then the property crossOrigin of the Image () object must be assigned 'Anonymous'. Maybe I wrote some nonsense, it was a long time ago ...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question