function retina_images_multiply_data_dimensions in Retina Images 7
Conditionally multiply the height and width keys of an array by a variable amount.
Parameters
$data: The configuration data for a specific image effect. This is expected to have a 'width' and 'height' key that will be modified. Passed by reference.
int $int: The amount that the width and height will be multiplied by. Defaults to 2.
4 calls to retina_images_multiply_data_dimensions()
- retina_images_image_crop_effect in ./
retina_images.module - Image effect callback; Crop an image resource.
- retina_images_image_resize_effect in ./
retina_images.module - Image effect callback; Resize an image resource.
- retina_images_image_scale_and_crop_effect in ./
retina_images.module - Image effect callback; Scale and crop an image resource.
- retina_images_image_scale_effect in ./
retina_images.module - Image effect callback; Scale an image resource.
File
- ./
retina_images.module, line 78 - This module provides an image effect to assist in outputing high resolution images.
Code
function retina_images_multiply_data_dimensions(&$data, $int = 2) {
if (isset($data['retinafy']) && $data['retinafy']) {
$data['width'] = $data['width'] * $int;
$data['height'] = $data['height'] * $int;
}
}