-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
color per triangle? #6060
Comments
Since all I know about this feature is from a comment by @errissa I tag them here in case they want to comment. |
The property In you example, you are using the legacy TriangleMesh that has no support for colors on faces. |
Thanks @lucagrementieri — just a few days ago I discovered the “t”/“tensor” subworld of Open3D, via experimenting with I would suggest that there is a bigger problem in the docs and sample code. After I started to understand the “t”/“legacy” distinction I looked for a description of that distinction and failed. (Similarly the doc for My intuition is that the “legacy” code is deprecated and that all new development has been on |
(This issue of legacy-vs-tensor confusion came up a day later here: #6130) |
Checklist
master
branch).My Question
(I may not understand the second question above, but I think I am running the most recent released version: Open3D 0.17.0, Python 3.10.10, macOS 12.6.3)
For a diagram-like rendering, I would like to use color per triangle instead of interpolated color per vertex (via
open3d.geometry.TriangleMesh.vertex_colors
). But this comment suggests per-triangle support was added to Open3D by December 2021. If so, I am unable to get it to run. This Python test code:gets an error on
mesh.triangles["colors"] = face_colors
:I am currently using one of the workarounds discussed on that earlier Issue. But if there is a supported way to apply face colors directly I would prefer to use that. Any suggestions? Is this feature mentioned in the documentation? I have failed to find it, and the keywords (triangles, colors) are too common for searching.
(I would expect the color data to be rgb triples of floats, but changed it from
Vector3dVector
toVector3iVector
based on the error message. I also triedo3d.core.Tensor(...)
as suggested in the previous Issue, but got the same error.)The text was updated successfully, but these errors were encountered: