The only problem with that argument is that the two things are entirely different, legally and philosophically. The purported justifications for "miscegenation" (laws against interracial marriage) were completely different from those for traditional marriage laws.
The question of whether people of different races should marry was about whether marriage laws should apply to people in a mixed race relationship, while the question of whether two people of the same sex can marry was about whether such a thing is even possible, given the definition of marriage. The first was a question about ethics: should the law be applied to mixed race marriages; the second was about epistemology: can the law apply to same sex-couples.
The two questions are not only different questions, they are different kinds of questions: The question in miscegenation laws was who should be able to marry, not about what marriage is.
They were also different as a practical matter in relation to the operation of law: Given the definition everyone was agreed on, any prohibition on interracial marriages involved an additional law, while any prohibition of gay marriage only requires keeping the current ones. Stopping interracial marriage involved changing the law; stopping same-sex marriage involves keeping it the same.
In their paper What is Marriage? Sherif Girgis (PhD. candidate, Princeton), Robert P. George (Professor of Jurisprudence, Princeton), and Ryan Anderson (Ph.D candidate, Notre Dame) put it as follows:
Opponents of interracial marriage typically did not deny that marriage (understood as a union consummated by conjugal acts) between a black and a white was possible any more than proponents of segregated public facilities argued that some feature of the whites‐only water fountains made it impossible for blacks to drink from them. The whole point of antimiscegenation laws in the United States was to prevent the genuine possibility of interracial marriage from being realized or recognized, in order to maintain the gravely unjust system of white supremacy.9
By contrast, the current debate is precisely over whether it is possible for the kind of union that has marriage’s essential features to exist between two people of the same sex. Revisionists do not propose leaving intact the historic definition of marriage and simply expanding the pool of people eligible to marry. Their goal is to abolish the conjugal conception of marriage in our law10 and replace it with the revisionist conception. [See footnotes below]Opponents of current marriage laws will continue to repeat these arguments of course, but they are based on a flawed interpretation of history and law, and are at bottom an emotional appeal that attempts to hijack the visceral repulsion most people have to racism in order to direct it toward the traditional and historical idea of marriage. They will probably have some success in doing it too.
That's the thing about sophistry: It works pretty well, practically speaking. But if it does work, it won't be because the argument is a sound one, because it isn't.
9 See Loving v. Virginia, 388 U.S. 1, 11 (1967).
10 Throughout history, no society’s laws have explicitly forbidden gay marriage. They have not explicitly forbidden it because, until recently, it has not been thought possible. What is more, antimiscegenation laws, at least in the United States, were meant to keep blacks separate from whites, and thus in a position of social, economic, and political inferiority to them. But traditional marriage laws were not devised to oppress those with same‐sex attractions. The comparison is offensive, and puzzling to many—not least to the nearly two‐thirds of black voters who voted to uphold conjugal marriage under California Proposition Eight. See Cara Mia DiMassa & Jessica Garrison, Why Gays, Blacks are Divided on Prop. 8, L.A. TIMES, Nov. 8, 2008, at A1.