templated transformation scalar