Protect against excessive bitmap size, max to 50M pixel.
More template.