/************************************************************************* Enable or disable auto-scaling for this Imageset. *************************************************************************/ void Imageset::setAutoScalingEnabled(bool setting) { if (setting != d_autoScale) { d_autoScale = setting; updateImageScalingFactors(); } }
/************************************************************************* Notify the Imageset of the current (usually new) display resolution. *************************************************************************/ void Imageset::notifyScreenResolution(const Size& size) { d_horzScaling = d_vertScaling = 1.0; if (d_autoScale) { updateImageScalingFactors(); } }
/************************************************************************* Notify the Imageset of the current (usually new) display resolution. *************************************************************************/ void Imageset::notifyDisplaySizeChanged(const Size& size) { d_horzScaling = size.d_width / d_nativeHorzRes; d_vertScaling = size.d_height / d_nativeVertRes; if (d_autoScale) { updateImageScalingFactors(); } }
/************************************************************************* Notify the Imageset of the current (usually new) display resolution. *************************************************************************/ void Imageset::notifyScreenResolution(const Size& size) { d_horzScaling = size.d_width / d_nativeHorzRes; d_vertScaling = size.d_height / d_nativeVertRes; if (d_autoScale) { updateImageScalingFactors(); } }