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

[Three.js] 테두리 생성 유틸 추가 #28

Open
wants to merge 1 commit into
base: feat/find-waffle
Choose a base branch
from

Conversation

minkyu97
Copy link
Collaborator

Three JS 에서 물체에 테두리를 추가하는 것이 생각보다 까다롭습니다.
EdgesGeometry 와 LineBasicMaterial 을 활용하는 방법도 있지만, 공식 문서에도 나와있듯이 두께 조절이 가능하지 않습니다.

위의 한계점을 극복하기 위해 머터리얼의 프라그먼트 셰이더를 조작하여 테두리 두께와 색상을 자유롭게 지정할 수 있는 유틸을 추가합니다.

참고: https://discourse.threejs.org/t/how-to-make-a-2d-border-with-the-same-thickness-around-the-entire-perimeter/28487/6

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