Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run unit tests with vips as the driver for intervention/image #611

Open
GuySartorelli opened this issue Jun 4, 2024 · 1 comment
Open

Comments

@GuySartorelli
Copy link
Member

osiemsiedem/intervention-image-vips-driver provides a driver for libvips, which is a more efficient alternative to GD and Imagick for manipulating images.

There have been PRs in the past to allow libvips to work with Silverstripe CMS - but we don't run tests against it, so regressions could sneak in.

Getting libvips driver working

  1. Install libvips (e.g. sudo apt install libvips42)
  2. Add osiemsiedem/intervention-image-vips-driver (e.g. composer require osiemsiedem/intervention-image-vips-driver)
  3. Configure the libvips driver for intervention/image via yaml config:
    SilverStripe\Core\Injector\Injector:
      Intervention\Image\ImageManager:
        constructor:
          - { driver: Vips }

Acceptance criteria

  • An additional job is added to CI for this module which runs the unit tests with libvips configured as the driver for intervention/image
@maxime-rainville
Copy link
Contributor

We had some initial discussion with CreMarketing about this.

Vips looked like it could in theory be quite a cool improvement for generating images. Our own testing has been a bit more dubious.

Intervention 3 doesn't support it and doesn't seem inclined to support it. This would be a blocker for CMS 6 support.

Validation required:

  • What are the scenarios where this could be beneficial?
  • Could this be supported on SC?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants