Does the Roman Catholic church recognize marriages outside of the church? I'm curious about the status of marriages performed outside the auspices of the church. For example, if a non Catholic converts to the Roman church, but was married beforehand, does it "count". Based on an earlier question, I understand now that the church annuls marriages - but, if these two went on to divorce, wouldn't the church be in the position of denying a marriage they never blessed?

Along these lines, what happens if two people get married by a justice of the peace, or If ignoring the advice of a priest, they choose to find some other minister to perform the ceremony. 

I realize that the church's recognition of a marriage is completely different from the state's recognition (and truthfully the practical effect of a non recognition by the church is slim), but it still makes me wonder if, say, two baptists who marry and then convert are "living in sin" until the priest recognizes the marriage. 

At the extreme side of things, Im assuming that the church would never recognize a "gay marriage," considering it annulled from the beginning- but would that extend to legitimate unions simply conducted outside the aegis of the church as well?

Just curious.
The Roman Church does recognise marriages outside the Church. See Canons 1055 and 1056:

Can.  1055 §1. The matrimonial covenant, by which a man and a woman establish between themselves a partnership of the whole of life and which is ordered by its nature to the good of the spouses and the procreation and education of offspring, has been raised by Christ the Lord to the dignity of a sacrament between the baptized.
§2. For this reason, a valid matrimonial contract cannot exist between the baptized without it being by that fact a sacrament.
Can.  1056 The essential properties of marriage are unity and indissolubility, which in Christian marriage obtain a special firmness by reason of the sacrament.

A marriage between two baptised people is by definition a sacrament: it's the couple who are ministers of that sacrament, not the officiant at the ceremony. Consequently it doesn't really matter who the officiant is (although there are rules, just to make sure that everything is done properly and legally).
As I noted in my profile and an earlier comment, I used to be an Anglican and am now a member of the English Ordinariate.
Members of my Anglican church considered joining the Ordinariate, but their previous dissolved marriages would have caused difficulty. In practice, the Church attempts to be compassionate in justice and in most cases the reason for divorce would have been a valid reason for annulment and there would be no problem — but all the circumstances would have to be investigated thoroughly.

Perhaps I should qualify the opening sentence as

The Roman Church does recognise marriages outside the Church which accord with Canon 1055.