Added helper function to Texture2D for framebuffers.