1

I'm working on an HTML/js/css program that reads video frames as they play, & stores them in an array for playback. Because canvas is screen sensitive, drawing the canvases takes long enough that frames get dropped. I would think that drawing the images to a buffer or RAM address would be faster if the canvas info is stored without having to draw each frame to the screen. Is that correct, or even possible?

I tried something like style.id.display='none'. Didn't work.

JimM
  • 111
  • 1
  • 11
  • 1
    Don't append anything to the document ? Ps: you might find this useful : http://stackoverflow.com/questions/32699721/javascript-extract-video-frames-reliably/32708998 – Kaiido Sep 15 '16 at 07:56
  • @Kaiido, Your link is very useful. It's exactly what I'm trying to accomplish. – JimM Sep 15 '16 at 12:27
  • @Kaiido, The timeupdate event listener clears up the dropped frame problem, but the command, canvas.toDataURL() takes forever to convert. I had found a way to store the raw canvas image in an array that gets me a lot closer to real time record & playback. However, it's on my other PC. Rest assured, though, you pointed me in the right direction. – JimM Sep 15 '16 at 13:33
  • Yes toDataURL is slow. Yiu may prefer it's async equivalent toBlob – Kaiido Sep 15 '16 at 13:58

0 Answers0