f1[x_]= x Sin[x];
f2[x_]= Cos[x];
Plot[{f1[x],f2[x]},{x,-2,2}]

FindRoot[f1[x]==f2[x],{x,1}]

{a,b}={-0.86034,0.86034};
Plot[{f1[x],f2[x]},{x,a,b},
Filling->{1->{2}}]

SquareHeight[x_]=Abs[f1[x]-f2[x]];
ParametricPlot3D[
{
{x, t f1[x] + (1-t) f2[x], SquareHeight[x]},
{x, t f1[x] + (1-t) f2[x], 0}
},
{x, a,b},
{t, 0,1}
]

TentHeight[x_,t_]=(1-2Abs[t-1/2])*Abs[f1[x]-f2[x]]
ParametricPlot3D[
{
{x, t f1[x] + (1-t) f2[x], TentHeight[x,t]},
{x, t f1[x] + (1-t) f2[x], 0}
},
{x, a,b},
{t, 0,1}
]

ParabolaHeight[x_,t_]=(1-4(((t-1/2))^2))*Abs[f1[x]-f2[x]]
ParametricPlot3D[
{
{x, t f1[x] + (1-t) f2[x], ParabolaHeight[x,t]},
{x, t f1[x] + (1-t) f2[x], 0}
},
{x, a,b},
{t, 0,1},
BoxRatios->Automatic
]

CircleHeight[x_,t_]=(Sqrt[1-4(((t-1/2))^2)])*Abs[f1[x]-f2[x]]
ParametricPlot3D[
{
{x, t f1[x] + (1-t) f2[x], CircleHeight[x,t]},
{x, t f1[x] + (1-t) f2[x], 0}
},
{x, a,b},
{t, 0,1},
BoxRatios->Automatic
]