hack fix for calls to getViewport() before image has been loaded.  need to think through a real fix/solution for this...