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

feat: replaced ExtrudeGeometry with RoundedBoxGeometry #1920

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Riku-KANO
Copy link

@Riku-KANO Riku-KANO commented Apr 13, 2024

Why

  • Issue#180, Issue#1908.
  • To make this module simpler and more understandable by not using ExtrudeGeometry.

What

  • Replaced ExtrudeGeometry from 'three' with RoundedBoxGeometry from 'three-stdlib'
    → This allows us to attach multiple materials on each sides of RoundedBox, resolving Issue#180. Refer to the following code and image.
<RoundedBox args={[4, 6, 3]} segments={4} radius={1}>
  <meshStandardMaterial attach="material-0" color="#0000FF" />
  <meshStandardMaterial attach="material-1" color="#FFFFFF" />
  <meshStandardMaterial attach="material-2" color="#FF0000" />
  <meshStandardMaterial attach="material-3" color="#00FF00" />
  <meshStandardMaterial attach="material-4" color="#000000" />
  <meshStandardMaterial attach="material-5" color="#FF00FF" />
</RoundedBox>

スクリーンショット 2024-04-13 140729

I have simplified and clarified the previously complex implementation by utilizing existing modules.

Checklist

  • Documentation updated (example)
  • Storybook entry added (example)
  • Ready to be merged

Copy link

vercel bot commented Apr 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
drei ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 13, 2024 6:09am

Copy link

codesandbox-ci bot commented Apr 13, 2024

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

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.

None yet

1 participant