Texture Transformation in VS or PS?

usually within the shaders around here the multiplication with the Texture transform Matrix is done in the vertexshader.

Out.TexCd = mul(TexCd, tTex);
float4 col = tex2D(Samp, In.TexCd);

but it is also possible to do that in the pixelshader:

Out.TexCd = TexCd;
float4 col = tex2D(Samp, mul(In.TexCd, tTex) ) ;

are there significant differences in performance (or other advantages/disadvantages) between those methods?

for my understanding it doesn’t make sense to do such a simple texture transformation in the pixelshader. remember that vertexshaders are called once per vertex, while pixelshaders are called once per pixel. and there are typically way more pixels involved in rendering, then vertices.

texture-coordinate data is automatically interpolated for you when handed from VS to PS, so there should not be any difference in the result. and while you may not significantly notice the performance difference (which depends on many other factors) i’d consider doing such a texture-transformation in the PS a major overhead.

thx very much for that detailed explanation!