Compute the largest uniform zoom (px per content-unit) that fits a content rect of contentW x contentH (in content units) into a viewport rect of availW x availH (in pixels).
contentW x contentH
availW x availH
clamp optionally bounds the resulting zoom to [min, max].
clamp
Optional
Compute the largest uniform zoom (px per content-unit) that fits a content rect of
contentW x contentH(in content units) into a viewport rect ofavailW x availH(in pixels).clampoptionally bounds the resulting zoom to [min, max].