Affluent Black or Asian immigrants are typically high-skilled immigrants, a program that, by definition, screens for merit. Merit is heritable.
Gifted programs seek to screen for childhood intelligence, which is distinct both from being an immigrant and from having a good career. And, as I pointed out, being a smart kid is (in my experience) less of a factor in terms of being admitted to a gifted program than having attentive parents with free time and money.