Why does touchdesigner use TDInstanceTexCoord in vertex shader?

Why does touchdesigner use ‘TDInstanceTexCoord(TDUVUnwrapCoord())’ in vertex shader?

in vertex shader,

what is different between

‘vec3 uvUnwrapCoord = TDInstanceTexCoord(TDUVUnwrapCoord());
gl_Position = TDWorldToProj(worldSpacePos, uvUnwrapCoord);’

and

‘gl_Position = TDWorldToProj(worldSpacePos);’ ?

Anything doesn’t change. :frowning:

That parameter is used when doing UV Unwrapping in the Render TOP. It’s unused in other render modes, but doesn’t slow things down to have it there (the compiler should ignore it if it’s not used).

1 Like