many changes to support glew and android

Change-Id: I52ea4f3f003436fa002ea86962153d5ea4cb532a
many changes to support glew and android

Change-Id: Ia4a6ecb86c53582349e7631b376cf739cd31c27e
many changes to support glew and android

Change-Id: I67fbaa1ed24471d4b0fd303fb007ad7350768f30