main: Add entry point for TextureBufferRange.

v2: Review by Martin Peres
   - Get rid of difficult-to-follow code copied and pasted from
     the original TexBufferRange

Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
4 files changed