You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With this method builder.add_visual_from_file(filename='./case.pbj'). you can assign material with this method. Probably, you can import textures manually by assigning texture to one material and then pass also the material through this function.
In my case, I use .obj mesh files with .mtl files which define the texture. I just call the method without defining material. SAPIEN can import the texture.
Color on vertices is known is vertex color (which is not a texture). We strongly encourage using actual textures instead of vertex colors since
Vertex color is less powerful. Most formats only let you specify color, but not other material properties such as roughness.
Vertex color is less standardized. And different software will export vertex color in different color spaces. It is also not clear whether it should be loaded as emission color or diffuse color.
While we implemented shaders without vertex colors, the vertex color properties are still loaded so you can implement your own custom shader to use it in your intended way. For example, the "vertex_color" shader shows how to display vertex color (but all other textures are disabled). You can also edit other shaders to use the vertex color in your own way.
Hi. I have one mesh with texture on vertices that I want to import to sapien and build actor with it.
I tried this, but it didn't include the texture in the rendering output.
builder = self.scene.create_actor_builder()
builder.add_convex_collision_from_file(filename='./case.ply')
builder.add_visual_from_file(filename='./case.pbj')
self.mesh = builder.build_static(name='mesh')
I also tried .obj and .ply. They all contains colors, which could be shown in Meshlab. But when I import them, the color is missing.
Is there any specific way (e.g., different APIs or different format of texture files) to do this?
Thank you.
case.ply looks like
The text was updated successfully, but these errors were encountered: