removed some dup constants and made scale a function object