There is some evidence that depressive spells can lead to more clarity - this is wrapped up in the debate as to why depression exists in the first place. Additionally, the severity of the depression is a major factor - I have seen people entirely incapacitated by it, whereas others are able to effectively manage it using therapy and/or meds.
Also relevant is the nature/cause of the depression - it is possible to suffer from symptoms of depression (i.e. scoring highly on, say, the Beck depression inventory) that are largely situational - i.e. they are brought on by a job you hate, a bad relationship, etc. In these cases, doing a startup might actually be something that enables you to focus your energy and actually reduce or eliminate the symptoms entirely.