Camilo Barraza
Camilo Barraza

Reputation: 195

canvas flickering on chrome

Seems like an update on google chrome messed up my canvas animation. Currently I´m getting lots of flickering, this seems awkward because I haven´t changed any of the code and it worked smoothly a couple days ago. Am I the only one with this problem?

ps: the animation works fine in firefox.

Upvotes: 2

Views: 3775

Answers (2)

kthompson
kthompson

Reputation: 892

try using requestAnimationFrame: https://developer.mozilla.org/en-US/docs/Web/API/window.requestAnimationFrame

Upvotes: 0

Gavin Haynes
Gavin Haynes

Reputation: 2002

Are you using double buffering? You should expect flickering unless you are using a buffer. See Does HTML5/Canvas Support Double Buffering? and Google search

Upvotes: 1

Related Questions