I implement a simple web image capture using the chrome.downloads api.
I take the URLs of the images in the contents of the script and then call chrome.downloads.downloadto load them in the background of the script. It works well, but I want it faster.
I find that if users click " save image as " in the context menu of the <img> object, the download speed is very fast and almost seamless. I think it loads directly from the cache.
However, using chrome.load seems independent of loading <img> objects; even if the photos are already uploaded to the web page, it chrome.downloads.downloadtakes some time to upload each image, not as fast as “ save the image as ”. Therefore, I think it loads from the URL, regardless of the cache.
In fact, in this case, each picture is downloaded twice: one for caching in the browser, and the other for downloading. This is clearly a waste of time and a clean resource.
So ... back to the topic: is there any api support that supports downloading directly from the Chrome watch page? Also like " save image as ."