// NOTE: Really should check here to see which dimension constrains the other.
// Right now, we assume that height is the constraint.
int newWidth = (int)(aspectRatio * (double)r.height());
// NOTE: Really should check here to see which dimension constrains the other.
// Right now, we assume that height is the constraint.
int newWidth = (int)(aspectRatio * (double)r.height());