Yes, thinking of the Iwahori decomposition (as a refined sort of p-adic Cartan decomposition), $GL_n=\bigcup_w I\cdot w\cdot I$ for $w$ in the affine Weyl group, here "monomial" matrices modulo diagonal units-entry matrices. At least for $GL_n$, it is easy to see the semi-direct product decomposition of affine Weyl group into spherical Weyl group (here essentially permutations). Since the integrand is right $K$ (=$GL_n(\mathfrak o)$)-invariant, the spherical Weyl group can be pulled through out. Thus, the most general integrand is $H(i_1w_1\cdot a\cdot w_2 i_2)$ with $i_j\in I$ and $w_j$ in the spherical Weyl group, and $a$ in the diagonal torus $A$. The $w_1$ conjugates across $a$, and after integrating on the right over $I$, the most general case that need be considered is the integral of $H(i_1 a w)$ with $w$ in the spherical Weyl group. Of course, when the integrals are over $K$, the $w$ on the right goes away, too.

After this simplification, to actually compute the thing for $GL_2$ is not hard, even with an arbitrary unramified character on $B$, by literally determining (most of) the p-adic Iwasawa decomposition: given $g=\pmatrix{a & b \cr c & d}$, if ${\rm ord}\, c\le {\rm ord}\, d$, right multiply by $\pmatrix{1 & 0 \cr -c/d & 1}\in K$ to make the thing upper-triangular. In the opposite case, right multiplication by $\pmatrix{0 & 1 \cr -1 & -d/c}$ makes the thing upper-upper-triangular. Summing a geometric series and doing some easy (but frangible) algebra gives the outcome, which I'll not attempt to reproduce (unless perhaps my attempted prescription is unclear).

Probably this is how the question arose, anyway, but it might be worth mentioning that these integrals arise in one presentation of p-adic zonal spherical functions. MacDonald's name comes to mind.

In various contexts, especially in the archimedean case, this map (or conceivably an inverse, from spherical functions to principal series) might also be called an Abel or Harish-Chandra or Selberg or someone-else transform. (All such names appear for good reason, even if we may wonder why some of these people were not paying more attention to what the others were doing or had done.)

In the archimedean case, the indicated determinant certainly appears at least as a change-of-variables measure constant, but I do not know offhand whether thinking in these terms is as useful in the p-adic case.