The reason why you are not getting those img tags with document.getElementsByTagName("img") is because Google Maps uses a <canvas> and renders those images directly into the canvas (using the drawImage method), there are no direct img tags that are part of the DOM.
For example take a look at this fiddle in which the images are loaded using a blob but injected into an img tag (in this case you can successfully get them using document.getElementsByTagName("img")):
var xhr = new XMLHttpRequest();
xhr.open( "GET", "https://fiddle.jshell.net/img/logo.png", true );
xhr.responseType = "arraybuffer";
xhr.onload = function( e ) {
var arrayBufferView = new Uint8Array( this.response );
var blob = new Blob( [ arrayBufferView ], { type: "image/jpeg" } );
var urlCreator = window.URL || window.webkitURL;
var imageUrl = urlCreator.createObjectURL( blob );
var img = document.querySelector( "#photo" );
img.src = imageUrl;
var images = document.querySelectorAll('img');
for(var i=0; i<images.length; i++) {
console.log(images[i].src);
}
};
xhr.send();
<img id="photo"/>
In this case we can successfully loop through the image elements that are part of the DOM and display their src property.
Now take a look on the other hand the approach that Google Maps uses with a <canvas> element:
var xhr = new XMLHttpRequest();
xhr.open( "GET", "https://fiddle.jshell.net/img/logo.png", true );
xhr.responseType = "arraybuffer";
xhr.onload = function( e ) {
var arrayBufferView = new Uint8Array( this.response );
var blob = new Blob( [ arrayBufferView ], { type: "image/jpeg" } );
var urlCreator = window.URL || window.webkitURL;
var imageUrl = urlCreator.createObjectURL( blob );
var canvas = document.getElementById('myCanvas');
var context = canvas.getContext('2d');
var img = new Image();
img.onload = function() {
context.drawImage(img, 0, 0);
};
img.src = imageUrl;
var images = document.querySelectorAll('img');
for(var i=0; i<images.length; i++) {
console.log(images[i].src);
}
};
xhr.send();
<canvas id="myCanvas" />
As you can see in this case nothing gets printed into the console because document.querySelectorAll('img') returns an empty array.
Unfortunately I am not quite sure how you can extract the images that have already been drawn into an existing canvas.