A derivation of Belavkin's stochastic Schrödinger equations is given using quantum filtering theory. We study an open system in contact with its environment, the electromagnetic field. Continuous observation of the field yields information on the system: it is possible to keep track in real time of the best estimate of the system's quantum state given the observations made. This estimate satisfies a stochastic Schrödinger equation, which can be derived from the quantum stochastic differential equation for the interaction picture evolution of system and field together. Throughout the paper we focus on the basic example of resonance fluorescence.