In[]:=
rule=Exp[Complex[0,n_]*π*θ]:>
n
x
;
In[]:=
poly=ax+x^2+cx^3+d
Out[]=
d+ax+
2
x
+c
3
x
In[]:=
p=poly/.x->Exp[θIπ]
Out[]=
d+a
πθ

+
2πθ

+c
3πθ

In[]:=
p/.rule
Out[]=
d+ax+
2
x
+c
3
x