Residue theorem with $\frac{1}{2\pi}\int_{0}^{2\pi}e^{\cos\theta}\cos(n\theta) d\theta$.
The integral is equal to the real part of
$$\frac1{2 \pi} \int_0^{2 \pi} d\theta \, e^{\cos{\theta}} \, e^{i n \theta}$$
Now let $z=e^{i \theta}$; the integral is then
$$\frac1{i 2 \pi} \oint_{|z|=1} \frac{dz}{z} e^{(z+z^{-1})/2} z^n = \frac1{i 2 \pi} \sum_{k=0}^{\infty}\frac1{2^k k!} \oint_{|z|=1} dz \frac{e^{z/2}}{z^{k+1-n}}$$
Note that the integrand is analytic in the unit circle when $0 \le k \le n-1$. Then the result of the integration is
$$\sum_{k=n}^{\infty} \frac1{2^k k!} \left [\frac{d^{k-n}}{dz^{k-n}} e^{z/2} \right ]_{z=0}= 2^n \sum_{k=n}^{\infty} \frac1{2^{2 k} k! (k-n)!} = \frac1{2^n} \sum_{k=0}^{\infty}\frac1{2^{2 k} k! (k+n)!} = I_n(1)$$
where $I_n$ is the modified Bessel function of the first kind of order $n$.