facebookresearch / pytorch3d

PyTorch3D is FAIR's library of reusable components for deep learning with 3D data
https://pytorch3d.org/
Other
8.81k stars 1.32k forks source link

Generate textures on a mesh #1875

Open hanyangyu1021 opened 1 month ago

hanyangyu1021 commented 1 month ago

Here's the setting. I have a mesh without texture. It only has vertices and faces. I want to add texture on it. Below is my code. But the generated mesh in plot_scene is always blue. And when i want to save the .glb file, I file no texture added on it. image image Anyone knows where is wrong?

bottler commented 1 month ago

plotly_vis ignores TexturesUV because as far as I remember, plotly itself does not have the needed functionality. If plotly now has it, it would be good to add it.

The saving question may be a Trimesh thing. Maybe you can use the native experimental_gltf_io stuff in PyTorch3D to write a glb file with the texture in.