We present a coupled-channel Lagrangian approach (GiM) to describe the $pi N to pi N$, $2pi N$ scattering in the resonance energy region. The $2pi N$ production has been significantly improved by using the isobar approximation with $sigma N$ and $pi Delta(1232)$ in the intermediate state. The three-body unitarity is maintained up to interference pattern between the isobar subchannels. The scattering amplitudes are obtained as a solution of the Bethe-Salpeter equation in the $K$ matrix approximation. As a first application we perform a partial wave analysis of the $pi N to pi N$, $pi^0pi^0 N$ reactions in the Roper resonance region. We obtain $R_{sigma N}(1440)=27^{+4}_{-9}$,% and $R_{sigma N}(1440)=12^{+5}_{-3}$,% for the $sigma N$ and $pi Delta$ decay branching ratios of $N^*(1440)$ respectively. The extracted $pi N$ inelasticities and reaction amplitudes are consistent with the results from other groups.