I'd say a number of things - but the primary thing is that it's all stuff within your spouse:
1. Her comfort with her own gender / sexuality
2. Her views of masculinity / femininity / gender roles
3. If she has some gender variance herself, even a bit, and is comfortable with it, that helps quite a bit.
4. Bisexual women seem to deal with this easier
5. Lack of very dogmatic religious views that declare such behavior as a perversion
6. Her ability to forgive your deception

External stuff like how solid the marriage is, and whether or not you told her up front before marriage also matter, but in my opinion, it's mostly her. (Telling her up front is huge, actually.)