First, we exploit the evenness of the cosine function to write
$\displaystyle \int_{-\pi/2}^{\pi/2}\cos(t)^x dt = 2\int_0^{\pi/2}\cos(t)^xdt.$
Next, we have our first substitution. Let $\displaystyle u = \cos(t)$ so that $\displaystyle du = -\sin(t) dt$. Here $\displaystyle t=\arccos(u)$ and see that
$\displaystyle 2\int_0^{\pi/2}\cos(t)^xdt = -2\int_0^1 \frac{u^xdu}{\sin(\arccos(u))}.$
Using some trig we find that
$\displaystyle \sin(\arccos(u)) = (1-u^2)^{-1/2}$
so the integral becomes
$\displaystyle 2\int_0^1 u^x (1-u^2)du. $
Our second substitution aims to obtain the Beta function (not the Gamma function as MaxJasper pointed out). Let $\displaystyle t = u^2$ so that $\displaystyle u = t^{1/2}$ and $\displaystyle du = t^{-1/2}dt/2$. We see that
$\displaystyle f(x) = \int_0^1 t^{x/2-1/2}(1-t)^{-1/2}dt$
The beta function is written as
$\displaystyle B(a,b) = \int_0^1 t^{a-1}(1-t)^{b-1} dt$
and we need to put our integral into this form. We get
$\displaystyle f(x) = \int_0^1 t^{(x/2+1/2)-1}(1-t)^{(1/2)-1}dt = B\left(\frac{1+x}{2},\frac{1}{2}\right)$
Another way we can express the Beta function is as follows
$\displaystyle B(a,b) = \frac{\Gamma(a)\Gamma(b)}{\Gamma(a+b)}$
So
$\displaystyle f(x) = \frac{\Gamma((1+x)/2)\Gamma(1/2)}{\Gamma(1+x/2)} = \frac{\sqrt{\pi}\Gamma((1+x)/2)}{\Gamma(1+x/2)}$
Of course, now that we know what the substitutions are, we can baffle everyone by using the single substitution
$\displaystyle s = \cos^2 t$