pyrender
pyrender copied to clipboard
Can not see the color when visualize scene in pyrender
Hello, I visualize my scene (file .ply), but I only see the black and white color in the scene. Here is my .ply file. Here is my code:
import trimesh
fuze_trimesh = trimesh.load('meshed_poisson.ply')
mesh = pyrender.Mesh.from_trimesh(fuze_trimesh, smooth=False)
scene = pyrender.Scene()
scene.add(mesh)
pyrender.Viewer(scene)
Color rendering works on 0.1.32 version. Refer to issue #85
adding a ambient_light to Scene, or increaseing the intensity of light solves my problems.
scene = pyrender.Scene(ambient_lgith = [0.3,0.3,0.3, 1.0])
or do something like this:
light = pyrender.PointLight(intensity = 500)
Make sure fuze.obj, fuze.obj.mtl, fuze_uv.jpg all exist and placed in the same directory.