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

HTMLCanvasElement.toDataURL() issue #258

Open
Borisfrad opened this issue Feb 27, 2017 · 1 comment
Open

HTMLCanvasElement.toDataURL() issue #258

Borisfrad opened this issue Feb 27, 2017 · 1 comment

Comments

@Borisfrad
Copy link

Hi,

I'm trying to find a canvas element using querySelector and get the image data using toDataURL like this:
document.querySelector('CSS_SELECTOR').toDataURL('image/png');

The problem is that I'm getting 'null' instead of actual image data.
The canvas should be rendered using cornerstone.js but it seems to fail in that too.

Can anyone help solve this issue?

Thanks,
Boris

@Borisfrad Borisfrad changed the title HTMLCanvasElement.toDataURL issue HTMLCanvasElement.toDataURL() issue Feb 27, 2017
@hollingsworthd
Copy link
Owner

When constructing, try new JBrowserDriver(Settings.builder().headScript("").build()) ... the toDataURL is actually being explicitly disabled to prevent browser fingerprinting like Tor Browser does. This is clearly unintuitive for people and should be more easily configurable with more obvious defaults. Thanks for reporting this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants