NOTE: I am aware of this possible duplicate, but my question is slightly different as it also involves arithmetic-geometric mean.
The arithmetic mean of two numbers is defined as: $$\text{am}(a,b) = \frac{a}{2}+\frac{b}{2}$$ For example, $\text{am}(3,12) = 7.5$. Similarly, geometric mean of two numbers is defined as: $$\text{gm}(a,b) = \sqrt{ab}$$
So $\text{gm}(3,12)=6$. The arithmetic-geometric mean is a mean "between" these two, calculated as follows: $$ a_{0}=a,g_{0}=b\\ a_{n+1}=\text{am}(a_{n},g_{n})\\ g_{n+1}=\text{gm}(a_{n},g_{n})\\ \text{agm}(a,b)=\text{lim}_{n\rightarrow\infty}\;\;(a_n) $$
For instance, $\text{agm}(3,12) \approx 8.7407$. Note that $\text{gm}(a,b)\leq \text{agm}(a,b)\leq \text{am}(a,b)$.
My question: I need to define a general mean $M(a,b,c)$ for $0\leq c \leq 1$ that satifies these properties: $$ M(a,b,0) = \text{am}(a,b)\\ M(a,b,0.5) = \text{agm}(a,b)\\ M(a,b,1) = \text{gm}(a,b) $$ Power mean is not what I'm looking for, as $PM_{0.5}\;(a,b) \neq \text{agm}(a,b)$ (e.g. $PM_{0.5}\;(3,12) = 8.7464... \neq 8.7407...$).
Standard quadratic interpolation, as suggested by @Martin-R
\begin{align} M(a,b,t)&= (2t-1)(t-1)\operatorname{AM}(a,b) \\ &-4t(t-1)\operatorname{AGM}(a,b) \\ &+t(2t-1)\operatorname{GM}(a,b) . \end{align}
Or in expanded form,
\begin{align} M(a,b,t)&= (\sqrt a+\sqrt b)^2\,t^2 -(\tfrac32\,a+\tfrac32\,b+\sqrt{ab})\,t +\tfrac12\,a+\tfrac12\,b \\ &+\frac{\pi t(1-t)} {\displaystyle\int_0^1 \left(\sqrt{1-x^2}\sqrt{(a+b)^2-(a-b)^2\,x^2}\right)^{-1} \, dx } . \end{align}
Edit
At the second thought, I must admit that such interpolation is a bad choice for general $a,b\ge0$. It's ok for just switching between the three values $t=0,\tfrac12,1$ and works relatively reasonable for some ranges of $a,b$, but it could as bad as returning negative output, for example, $M(1000000,1,0.9)\approx-2081$, so it needs a serious treatment.