Given a fluid spherically distributed with density $\rho(r)$ in 3-dimensions in flat-spacetime; the projected surface density $\sigma(R)$ (onto two dimensions) can be obtained by the well known formula:
\begin{equation} \sigma(R)=2\int_{R}^{+\infty}\dfrac{\rho(r)r}{\sqrt{r^2-R^2}}dr\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\;\; (1) \end{equation}
Suppose now the fluid with density $\rho(r)$ is embedded in a static and spherically symmetric spacetime, with the metric: $$ds^2=-A(r)dt^2+A(r)^{-1}dr^2+r^2d\Omega^2.$$
How it gets modified equation (1) to obtain the equivalent $\sigma(R)$ in terms of $\rho(r)$ and now $A(r)$?