Open AaronLlanos opened 8 years ago
After further researching this topic, it appears as though the answer above is coming from WebWorker operating on a seperate global scope.
iOS webworkers do not ship with atob defined on them. It may help to perform a check on the atob function within the webworker setup and assign it there if it does not exist. Furthermore, iOS does not setup Canvas Recorder properly to include RIFF or LIST from the decoded value.
@AaronLlanos could you please provide your solution?
Hello,
I am building a project using this tool which records a canvas. I import the Whammy script along with the CanvasRecorder script as specified here. The problem I am having is that whenever I call the function recorder.stop((blob) => {}), it uses the whammy library to convert each webP to base 64 and combine it to webM.
It is in this function where the problem occurs:
WhammyVideo.compile -> processInWebWorker -> whammyInWebWorker -> ArrayToWebM -> parseWebP -> parseRIFF -> atob
As stated above, on android web view through phonegap this works but on iOS it does not. I tried logging window and even tried polyfilling the function with a shim but nothing has worked so far. It seems as though the
window
variable is lost in the function:Maybe I am just thinking about this incorrectly but I think this library should be working across all devices especially iOS through Phonegap since it is a growing development community.
Best, Aaron