function _drush_image_derive

8.0.x image.inc _drush_image_derive($style_name, $source)
8.0.x image_7.inc _drush_image_derive($style_name, $source)
7.x image.inc _drush_image_derive($style_name, $source)
7.x image_7.inc _drush_image_derive($style_name, $source)
master image.inc _drush_image_derive($style_name, $source)
master image_7.inc _drush_image_derive($style_name, $source)
1 call to _drush_image_derive()

File

commands/core/drupal/image.inc, line 37
Specific functions for a Drupal image handling. drush_include_engine() magically includes either this file or image_X.inc depending on which version of Drupal is in use.

Code

function _drush_image_derive($style_name, $source) {
  $image_style = drush_image_style_load($style_name);
  $derivative_uri = $image_style->buildUri($source);
  if ($image_style->createDerivative($source, $derivative_uri)) {
    return $derivative_uri;
  }
}