Texture-based functions for BHWD layout