Let $C(A, B)$ denote a truncated cylinder whose left edge has length $A$ and whose right edge has length $B$. (I'm assuming that it's placed so that its longest and shortest edges are to the left and right).
The volume of $C(A, 0)$ is $\frac{1}{2} \pi r^2 A$. Reason: Stack up $C(A, 0)$ atop $C(0, A)$ to get a cylinder of height $A$. The volume of $C(A, 0)$ is clearly half the volume of this cylinder.
Now for a cylinder C(A, B), where $A > B$, consider the stack
C(0, Q)
C(A, B)
C(B, A)
C(Q, 0)
where $Q = A - B$. THat's a cylinder of height $A + B + (A-B) = 2A$. If we subtract from it the volumes of the top and bottom pieces (which we computed in part 1), we get
$$
\pi r^2 (2A) - \pi r^2 (Q) = \pi r^2 (2A - (A-B)) = \pi r^2 (A + B)
$$
But the volume we've just computed is twice the volume of the sliced cylinder $C(A,B)$ that we're interested in. So the volume of $C(A,B)$ isjust
$$
\pi r^2 \frac{A + B}{2}
$$
A rather similar proof works for surface area.
Note that the proof given above works for a cylinder cut by ANY two planes, as long as the longest and shortest "line" of the truncated cylinder are diametrically opposite each other.
An area element in spherical coordinates is given by
$$\mathrm d A=r^2\sin\phi \mathrm d\phi \mathrm d\theta,$$
following the convention shown here:
Place your sphere at the origin and say your projection is orthogonal to the $x,y$-plane, i.e. parallel to the $z$-axis. You now have a pixel. Let its bottom-left corner (as seen in the $x,y$-plane) have coordinate $(nd,md)$ with $d$ being the pixel width and $|n|,|m|<\frac{r}{d}$. You now project this pixel onto the sphere and want to know what the corresponding area on the sphere is. To do this, simply integrate the above mentioned area element over the limits in spherical coordinates corresponding to the change in $x$ and $y$, being $x_1=nd\rightarrow x_2=(n+1)d$ and $y_1=md\rightarrow y_2=(m+1)d$ respectively. However, we want to find these limits in terms of $\theta$ and $\phi$, i.e. $\theta_1,\theta_2$ and $\phi_1,\phi_2$, so that we can calculate the projected area of pixel $n,m$ by
$$A_{nm}=\int_{\phi_1}^{\phi_2}\int_{\theta_1}^{\theta_2}\mathrm d A.$$
We have that
\begin{align}
\theta&=\arctan\left(\frac{y}{x}\right) \\
\phi&=\arccos\left(\frac{z}{r}\right).
\end{align}
Now, the $\theta$-part is easy enough, as
\begin{align}
\theta_1&= \arctan\left(\frac{m}{n}\right)\\
\theta_2&= \arctan\left(\frac{m+1}{n+1}\right).
\end{align}
However, the $\phi$-part requires knowledge of $z$, but since we are always only projecting onto the surface of the sphere, we know that
$$x^2+y^2+z^2=r^2 \implies z=\sqrt{r^2-x^2-y^2},$$
(note that I've chosen the positive solution... If I were you, I would rotate my coordinate-system each time you're working with pixels lying outside of the first quadrant)
which gives
\begin{align}
z_1&=r\sqrt{1-\frac{d^2}{r^2}(n^2+m^2)} \\
z_2&=r\sqrt{1-\frac{d^2}{r^2}((n+1)^2+(m+1)^2)}.
\end{align}
But with this, we can calculate the remaining limits:
\begin{align}
\phi_1&=\arccos\left(\sqrt{1-\frac{d^2}{r^2}(n^2+m^2)}\right)\\
\phi_2&=\arccos\left(\sqrt{1-\frac{d^2}{r^2}\left((n+1)^2+(m+1)^2\right)}\right),
\end{align}
such that the integral evaluates to
\begin{align}
A_{nm}&=r^2(\theta_2-\theta_1)(\cos\phi_1-\cos\phi_2)\\
&= r^2\left(\arctan\left(\frac{m+1}{n+1}\right)-\arctan\left(\frac{m}{n}\right)\right)\left(\sqrt{1-\frac{d^2}{r^2}(n^2+m^2)}-\sqrt{1-\frac{d^2}{r^2}\left((n+1)^2+(m+1)^2\right)}\right)
\end{align}
In conclusion, this is a formula for the area of the pixel with $x,y$-coordinates $(nd,md)$ projected onto a sphere that has center at the origin and radius $r.$ Do this for every pixel whose projection is completely on the sphere (the formula does not work otherwise) and you can find your desired ratio.
Doing concrete calculations with this requires care w.r.t. principal values and such, but as I mentioned, I'd strongly recommend rotating your coordinate system when working with the pixels lying in other quadrants of the $x,y$-plane than the first.
Do leave a comment if you have any questions.
Best Answer
Let $R$ and $r$ be the radius of the beam and the cylinder respectively. Let $\mu = \frac{r}{R}$.
Choose the coordinate axis such that the beam is illuminating the cylinder from the $+ve$ $x$-axis. In cylindrical polar coordinates $(r,\theta, z)$,
$$(r,\theta,z) \quad\iff\quad (x,y,z) = (r\cos\theta, r\sin\theta, z)$$
The illuminated area on the cylinder are those points satisfying:
$$ |\theta | \le \frac{\pi}{2}\quad\text{ and }\quad r^2\sin^2\theta + z^2 \le R^2$$
Since the area element on the cylinder is $r dz d\theta$, the area we want is
$$\verb/Area/ = \int_{-\theta_0}^{\theta_0} \int_{-\sqrt{R^2 - r^2\sin^2\theta}}^{\sqrt{R^2 - r^2\sin^2\theta}} rdz d\theta = 4rR \int_0^{\theta_0} \sqrt{1 - \mu^2 \sin^2\theta} d\theta$$ where $$\theta_0 = \begin{cases} \frac{\pi}{2}, & \mu \le 1,\\ \sin^{-1}(\mu^{-1}), & \mu > 1 \end{cases}$$
When $\mu \le 1$, the cylinder is smaller than the beam. It is easy to see
$$\verb/Area/_{\mu \le 1} = 4rR E\left(\mu\right)$$
where $$E(k) = \int_0^{\pi/2} \sqrt{1 - k^2\sin^2\theta} d\theta = \int_0^1 \sqrt{\frac{1-k^2t^2}{1-t^2}} dt $$ is the complete elliptic integral of the second kind.
When $\mu > 1$, the cylinder is larger than the beam. Change variable to $t = \mu\sin\theta$, we have
$$\begin{align} \verb/Area/_{\mu > 1} &= 4rR\mu^{-1} \int_0^1 \sqrt{\frac{1-t^2}{1-\mu^{-2}t^2}} dt\\ &= 4rR\mu^{-1} \int_0^1 \frac{1 - t^2}{\sqrt{(1-t^2)(1-\mu^{-2}t^2)}}dt\\ &= 4rR\mu \int_0^1 \frac{(1 - \mu^{-2}t^2) - ( 1 - \mu^{-2})}{ \sqrt{(1-t^2)(1-\mu^{-2}t^2)}}\\ &= 4r^2 \left[E(\mu^{-1}) - (1-\mu^{-2})K(\mu^{-1})\right] \end{align} $$ where $$K(k) = \int_0^{\pi/2} \frac{1}{\sqrt{1 - k^2\sin^2\theta}} d\theta = \int_0^1 \frac{1}{\sqrt{(1-k^2t^2)(1-t^2)}} dt $$ is the complete elliptic integral of the first kind.
Summary:
$$ \bbox[8pt,border:1px solid blue]{ \verb/Area/ = \begin{cases} 4rR E\left(\frac{r}{R}\right), & r < R\\ 4r^2 \left[E\left(\frac{R}{r}\right) - (1-\frac{R^2}{r^2})K\left(\frac{R}{r}\right)\right], & r > R \end{cases} } $$