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

Smooth geometry no longer possible with SurfaceTool #66765

Closed
codespren opened this issue Oct 2, 2022 · 2 comments · Fixed by #68034
Closed

Smooth geometry no longer possible with SurfaceTool #66765

codespren opened this issue Oct 2, 2022 · 2 comments · Fixed by #68034

Comments

@codespren
Copy link

Godot version

4.0 Beta 1

System information

macOS Monterey 12.6

Issue description

Setting geometry non-smooth seems to be no longer possible.

In Godot 3.5, that was done by calling surfaceTool.add_smooth_group(bool). In Godot 4.0, the method is removed and there's a new method, set_smooth_group(int index) but it seems to set smoothgroups true but smoothgroups are true by default so it's not possible to disable them.

Also documentation lacks explanation what the parameter index should be when index arrays are not used.

Steps to reproduce

  1. Try to generate geometry with non-smooth normals.

Minimal reproduction project

No response

@clayjohn
Copy link
Member

clayjohn commented Oct 2, 2022

The API has changed as you noted. You need to specify the smooth group that the vertex belongs to using the set_smooth_group(). Previously the smooth group was inferred based on context, but it broke in many edge cases.

The docs need to be updated, in particular the surface_tool tutorial needs to show how the new API is used.

@akien-mga
Copy link
Member

Fixed by #68034.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants