general framework stuff, like scaling