rotate_scale_alpha.imagecache_preset.inc 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. /**
  3. * @file
  4. * Test imagecache preset.
  5. *
  6. * Created on Dec 29, 2009
  7. *
  8. * @author 'dman' Dan Morrison http://coders.co.nz/
  9. */
  10. $presets['rotate_scale_alpha'] = array (
  11. 'name' => 'rotate_scale_alpha',
  12. '#weight' => 1.6,
  13. 'effects' => array (
  14. 1 => array (
  15. 'weight' => '1',
  16. 'module' => 'image',
  17. 'name' => 'image_rotate',
  18. 'data' => array (
  19. 'degrees' => '65',
  20. 'random' => 0,
  21. 'bgcolor' => '',
  22. ),
  23. ),
  24. /*
  25. * imageapi resize is NOT alpha-safe. This test case proves the bug.
  26. * A work-around is to change format before resizing.
  27. 2 => array (
  28. 'weight' => '2',
  29. 'module' => 'imagecache_coloractions',
  30. 'name' => 'coloractions_convert',
  31. 'data' => array (
  32. 'format' => 'image/png',
  33. 'quality' => '95',
  34. ),
  35. ),
  36. */
  37. 3 => array (
  38. 'weight' => '3',
  39. 'module' => 'image',
  40. 'name' => 'image_scale',
  41. 'data' => array (
  42. 'width' => '',
  43. 'height' => '150',
  44. 'upscale' => TRUE,
  45. ),
  46. ),
  47. 4 => array (
  48. 'weight' => '4',
  49. 'module' => 'imagecache_coloractions',
  50. 'name' => 'coloractions_convert',
  51. 'data' => array (
  52. 'format' => 'image/png',
  53. 'quality' => '95',
  54. ),
  55. ),
  56. ),
  57. );