You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We could speed this up by making a application wide image cache - any time you want to to Image.new, you first check to see if an image with that URL (well, let's use a hash of that url or data/uri tag, so the data struct is smaller) already exists in this global dictionary. If not, we create a new one and put it there. if it does exist, just get it from the dictionary (and maybe copy its data if html canvas's dont like rendering the exact same object multiple places).
We can also look at integrating this into the project opening process.
When loading a file, images take too long.
We could speed this up by making a application wide image cache - any time you want to to Image.new, you first check to see if an image with that URL (well, let's use a hash of that url or data/uri tag, so the data struct is smaller) already exists in this global dictionary. If not, we create a new one and put it there. if it does exist, just get it from the dictionary (and maybe copy its data if html canvas's dont like rendering the exact same object multiple places).
We can also look at integrating this into the project opening process.
http://stackoverflow.com/questions/10240110/how-do-you-cache-an-image-in-javascript
The text was updated successfully, but these errors were encountered: