0
在我開發的一個HTML5遊戲中,我在css動畫中使用了CSS特徵剪輯。但是我意識到它正在影響遊戲的表現。CSS剪輯使用gpu?
我想剪輯沒有使用GPU加速(如果我錯了,請讓我知道)。 有一種方法可以實現與使用GPU加速的剪輯相同的效果嗎?
這是我簡單的動畫:
@-webkit-keyframes animation
{
0%
{
clip:rect(0px,auto,0px,auto);
}
50%
{
clip:rect(0px,auto, 69px,auto);
}
100%
{
clip:rect(0px,auto,0px,auto);
}
}
在此先感謝。
替換此'navigator.userAgent'測試類似於document.style'中的''webkitTransform'。此外,javascript屬性不是'-webkit-transform',而是我之前引用的那個。 –