hh54188
hh54188

Reputation: 15646

translateZ(0) could enable an acceleration of GPU in Chrome,but it could work in other browser?

Recently I read a hack about translateZ(0), it is said that by using this property, it could enable an acceleration of GPU

but it is only work in Chrome or webkit browser, or could work in IE and firefox, too?

Upvotes: 0

Views: 1895

Answers (3)

Apoorv Saxena
Apoorv Saxena

Reputation: 4236

will-change allows an author to inform the UA ahead of time of what kinds of changes they are likely to make to an element. This allows the UA to optimize how they handle the element ahead of time, performing potentially-expensive work preparing for an animation before the animation actually begins.

W3C: CSS Will Change

Browser support for will-change property

Upvotes: 0

DividedByZero
DividedByZero

Reputation: 4391

well it's actually a webkit hack (basically abusing the way webkit treats translateZ)

Upvotes: 1

Jason Lydon
Jason Lydon

Reputation: 7180

Webkit only using -webkit-transform:translateZ(0); or -webkit-transform: translate3d(0,0,0);

Upvotes: 0

Related Questions