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

Support interpolation for 2D rendering modes #102

Merged
merged 7 commits into from
May 12, 2024
Merged

Support interpolation for 2D rendering modes #102

merged 7 commits into from
May 12, 2024

Conversation

mkeeter
Copy link
Owner

@mkeeter mkeeter commented May 12, 2024

Changed to 2D rendering API to support render modes which use linear interpolation to process full / empty regions

  • Specifically, RenderMode::interval now returns an IntervalAction, which can be Fill(..), Recurse, or Interpolate.
  • Modify SdfRenderMode use this interpolation; the previous pixel-perfect behavior is renamed to SdfPixelRenderModel
  • Make RenderMode trait methods static, because they weren't using &self
  • Change signature of fidget::render::render2d to pass the mode only as a generic parameter, instead of an argument

@mkeeter mkeeter enabled auto-merge (squash) May 12, 2024 17:53
@mkeeter mkeeter merged commit f15e65d into main May 12, 2024
11 checks passed
@mkeeter mkeeter deleted the sdf-interpolate branch May 12, 2024 18:10
@mkeeter mkeeter mentioned this pull request May 27, 2024
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