Olivier
Olivier

Reputation: 31

Is there any way to get a true/false on Chrome to know if Hardware Acceleration is activated or not?

I'm having a bit of a problem with the CSS attribute preserve-3d. During my tests it seems to get ignored on Chrome when the Hardware Acceleration is disabled (mostly on older laptops, but possibly computers too).

When I check through chrome://gpu/ is says "3D CSS: Unavailable. Hardware Acceleration Unavailable".

Question is: Is there any way to detect that when the page loads with something as simple as a true or false in the end ? Possibly in Javascript ?

I already tried Modernizr and a bunch of other "preserve-3d" compatibility tests but they always come up as TRUE even though they still wont work.

I checked around in their chrome://gpu/gpu_internals.js file but nothing works so far...

Upvotes: 3

Views: 1617

Answers (1)

exussum
exussum

Reputation: 18568

Mordernizer is a libabry which specializes in feature detection

https://github.com/Modernizr/Modernizr/wiki/Undetectables

There Wiki lists hardware acceleration as "no reliable way to detect"

Your question actually relates to preserve-3d though

https://github.com/Modernizr/Modernizr/issues/762

That issue should help in some way

Upvotes: 2

Related Questions