I wouldn't be concerned about performance here. We're talking about millions of ops per second in something that happens once per animation (not per frame).