Skip to content

feat(mesh): add HSL color interpolation space - #26

Open
MrNihalT wants to merge 1 commit into
zoxilsi:mainfrom
MrNihalT:feature/HSL
Open

feat(mesh): add HSL color interpolation space#26
MrNihalT wants to merge 1 commit into
zoxilsi:mainfrom
MrNihalT:feature/HSL

Conversation

@MrNihalT

Copy link
Copy Markdown

Summary

Hey! This PR adds support for HSL (Hue, Saturation, Lightness) color space blending to the gradient editor.

Why

Currently, if you try to blend opposite colors (like blue and yellow) in RGB or Linear space, the math cuts straight through the color cube and creates a dull, muddy grey or brown area in the middle of the transition.

Related issue

Closes #

Type of change

  • Feature (feat)
  • Bug fix (fix)
  • Performance (perf)
  • Refactor / chore
  • Docs
  • Breaking change

How was this tested?

  • Ran pnpm check locally—TypeScript compiles, lint checks pass, and the production static build generated successfully without issues.
  • Fired up the dev server (pnpm dev) and manually checked it in Chrome. Selecting HSL blending renders smoothly and looks incredibly vibrant!

Checklist

  • pnpm check passes locally
  • I added or updated tests where appropriate, or explained why none are needed
  • I updated documentation where appropriate, or this change needs no docs
  • Verified the change in the running app
  • Self-reviewed the diff
  • This PR contains no secrets, credentials, or unrelated changes

Screenshots / recordings

{C956BB78-434B-4343-AF9C-914DE9CE5374}

Notes for reviewers

  • The circular projection logic is handled in lib/color.ts and the GLSL math is in shaders/meshPass.ts. Feel free to review the conversion steps!

@MrNihalT
MrNihalT requested a review from zoxilsi as a code owner July 29, 2026 09:10
@vercel

vercel Bot commented Jul 29, 2026

Copy link
Copy Markdown

@MrNihalT is attempting to deploy a commit to the zoxilsi's projects Team on Vercel.

A member of the Team first needs to authorize it.

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