I have a HTML5 canvas
in a document. Over that canvas some div
s may be, hiding the canvas behind them (but still part of canvas is visible).
Knowing the position of canvas how can I check which divs actually cover the canvas so that I no longer draw behind those divs in order to improve perfromance?
And how do I actually only draw part of canvas to save some processing power?