Skip to content

CONV-137: Implement PNG to WEBP driver#131

Merged
menvil merged 1 commit into
developfrom
feature/CONV-137-implement-png-to-webp-driver
Jun 1, 2026
Merged

CONV-137: Implement PNG to WEBP driver#131
menvil merged 1 commit into
developfrom
feature/CONV-137-implement-png-to-webp-driver

Conversation

@menvil

@menvil menvil commented Jun 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • Implements PngToWebpDriver at app/Conversion/Drivers/Image/PngToWebpDriver.php
  • GD WEBP support confirmed (gd_info()['WebP Support'] = true)
  • Supports quality option; lossless mode not exposed by GD encoder (lossy only)
  • Returns ConversionResult without mutating models

Test plan

  • PngToWebpDriverTest passes (file exists, extension=webp, mime=image/webp, size>0)
  • composer test passes (261 tests)
  • composer lint passes

🤖 Generated with Claude Code


Summary by cubic

Adds a PNG→WEBP conversion driver to meet CONV-137, enabling lossy WebP output with configurable quality. This lets us convert stored PNGs to WebP and return a ConversionResult without touching models.

  • New Features
    • Added PngToWebpDriver using intervention/image (GD) to encode WebP.
    • Supports quality option: low/medium/high/max (default fallback to 85).
    • Requires GD WebP support; encoder is lossy only.
    • Writes result.webp to the provided output directory on the local disk and returns ConversionResult with metadata.

Written for commit 6b32cde. Summary will update on new commits.

Review in cubic

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@menvil menvil merged commit 0af8840 into develop Jun 1, 2026
@coderabbitai

coderabbitai Bot commented Jun 1, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • release

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 4a3e4caa-42b4-4060-bdac-5d3eebc11032

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/CONV-137-implement-png-to-webp-driver

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@menvil menvil deleted the feature/CONV-137-implement-png-to-webp-driver branch June 1, 2026 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant