Remove repeated host round trip in glBindSampler

bug: 117960593

glBindSampler was calling glGetIntegerv for the # of texture units which
was in turn calling glGetError, which resulted in lots of unnecessary
round trips. Caching the capability makes it so we compute that once
in the beginning and don't touch the host again.

Test: Profiling shows that glBindSampler no longer takes up most of
the runtime in a dEQP test (in gluStateReset)

Change-Id: Ibbbb5ddd93daae07bb4852fa34f3c5d8b187099d
2 files changed
tree: ba6bafea0966e21b090389eb6c1edf4741d11cac
  1. .vscode/
  2. host/
  3. shared/
  4. system/
  5. tests/
  6. Android.mk
  7. common.mk
  8. README