4. Given point $P$ is inside or on the circumference of a fixed circle $\odot O$, and a moving circle $\odot C$ passes through point $P$ and is tangent to $\odot O$. Then the locus of the center of $\odot C$ could be ( ).
(A) circle, ellipse, or hyperbola
(B) two rays, circle, or parabola
(C) two rays, circle, or ellipse
(D) ellipse, hyperbola, or parabola
4.C.

If point $P$ is on $\odot O$, then the locus of the center of $\odot C$ is two rays, as shown in Fig. 3(a); if point $P$ coincides with the center of $\odot O$, then the locus of the center of $\odot C$ is a circle with $O$ as the center and $\frac{r}{2}$ as the radius, as shown in Fig. 3(b); if point $P$ is inside $\odot O$ and does not coincide with $O$, then $|O C|+|P C|=r$, and the locus of the center of $\odot C$ is an ellipse, as shown in Fig. 3(c).