Rewrote from template, fixes texture bug. Suspect it was caused by setUpShaders function where position + texture attributes for shaders were incorrectly fetched