texture mapping (jogl & android); logic extracted.