From Calculus II, it's easy to understand what is basically being calculated by integration; the area under a curve. $\int_a^bf(x) \, dx =$ the area under $f(x)$ within the interval $[a,b]$. However, a line integral is a bit more complicated. I completely understand the computation of a line integral; it isn't too difficult to understand. However, I lack the understanding of what exactly is being calculated by it. Is it the area under the integrated curve, treating the path along which it is integrated as though it were the $x$-axis? A visual example would be greatly appreciated! Thanks in advance.
You can have your geometric interpretation if you picture the function you are integrating "attached" to the line at each point on the curve. Now straighten out the curve and lay in along the $x$ axis, and treat the values of the function you had sewn to it as $y$ coordinates at each point. Then the line integral will be the ordinary area integral.
Fans of rigor will rake me over the coals on that answer, because it is easy to come up with tricky functions for which what I just said is meaningless, but for ordinary line integrals you will be encountering in early days, it is fine.
Let me make an attempt. I hope others can criticize and improve it.(Or downvote it if I am plainly wrong).
Let us first look at the integral of $g(x)$ between $a$ and $b$. It is the amount of area bounded by 3 straight line segments $x=a,\ x=b,\ y=0$ and the curve $y=g(x)$. This is a flat surface lying in a plane. This is swept our by a vertical line segment of varying height but bottom moving on $x$-axis between $a$ and $b$. Notice that all these line segments are in the same plane.
Now line integral is the generalization of this for a curve lying in a curved surface (not in a plane). That is, take the surface $z=g(x,y)$, for a curve lying on it (specified by two functions $x(t), y(t)$ with $g(x(t), y(t))=0$ pick the line segments parallel to $z$-axis with bottom on the plane $z=0$ and the top on the curve. The bottom instead of moving in a line moves in a "bottom plane" following the curve. They sweep out a curved sheet, a surface.
It is the amount of area of this curved sheet we get as line integral. (Algebraic geometers may call the region of 3d-space swept out by this "a ruled surface").