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

How to resize the thickness of the line of the camera frustum? #266

Open
YZsZY opened this issue Aug 15, 2024 · 2 comments
Open

How to resize the thickness of the line of the camera frustum? #266

YZsZY opened this issue Aug 15, 2024 · 2 comments

Comments

@YZsZY
Copy link

YZsZY commented Aug 15, 2024

image
Hello author~ Is there a way to adjust the thickness of the camera line as sometimes the lines of the camera are too thin which makes them less visible in the scene.

I noticed that the camera is automatically bolded when you click on it, but I didn't find the corresponding code, looking forward to your reply!

@brentyi
Copy link
Collaborator

brentyi commented Aug 16, 2024

Hi, this is unfortunately hardcoded as scale * 0.03 here:

<cylinderGeometry
args={[props.scale * 0.03, props.scale * 0.03, 1.0, 3]}
/>

We could expose an argument for configuring this. If you have time for a PR this would be appreciated!

If you're interested in the bold/outline effect, you could search based on OutlinesIfHovered. Here's where it's added for line segments we use for the camera frustums:

<Instance
position={midpoint}
quaternion={orientation}
scale={[1.0, length, 1.0]}
>
<OutlinesIfHovered creaseAngle={0.0} />
</Instance>

@YZsZY
Copy link
Author

YZsZY commented Aug 16, 2024

Thanks a lot! I will try 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

No branches or pull requests

2 participants