-
Notifications
You must be signed in to change notification settings - Fork 44
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
Errror while trying to draw visualization using open3d after running sapien render #186
Comments
It is very surprising that SAPIEN would have any effect on open3d since SAPIEN does not use OpenGL at all. And there is certainly no way to cause /usr/lib/dri/swrast_dri.so to go missing. Can you first verify this problem does not occur with open3d alone and is not caused some other libraries and provide a minimal example? |
Sorry for the late response; I wasn't working on this due to holidays and other commitments. I did some minor checks, and even importing import sapien as sapien
from sapien.utils import Viewer
import numpy as np
import open3d as o3d
def main():
# Replace this with your actual 3D points
points_world = np.random.rand(100, 3) # Example: 100 random points in 3D space
# Create an Open3D PointCloud object
point_cloud = o3d.geometry.PointCloud()
# Assign the points to the PointCloud object
point_cloud.points = o3d.utility.Vector3dVector(points_world)
# Optionally, add colors to the point cloud (e.g., random colors)
colors = np.random.rand(points_world.shape[0], 3)
point_cloud.colors = o3d.utility.Vector3dVector(colors)
# Visualize the point cloud
o3d.visualization.draw_geometries([point_cloud], window_name="3D Point Cloud")
if __name__ == "__main__":
main() |
Do you see any warnings from SAPIEN. For example, warnings about a broken driver installation where SAPIEN tries to workaround? One possibility is that your GPU graphics driver is not installed properly and SAPIEN tries to workaround this by providing missing EGL and Vulkan files when imported. And these files may interfere with open3d. For example, one possibility is that previously open3d is using the CPU to render, but since SAPIEN provides these GPU files, open3d now thinks it is fine to use the GPU and uses a incorrectly configured GPU. |
Also, your issue seems quite rare for a desktop environment. Are you using some special desktop setup such as x-forwarding, VNC, remote desktop, or docker? |
yes, I am using forwarding to run ubuntu remotely on windows; maybe that's why am facing such issue. I also find out that if I import open3d at first I don't get the error. So, its working fine for me now. Thanks for the quick responses. |
after i initiate sapien ; in the same script if i try to draw visualization using open3D i get following error:
libGL error: MESA-LOADER: failed to open swrast: /usr/lib/dri/swrast_dri.so: cannot open shared object file: No such file or directory (search paths /usr/lib/x86_64-linux-gnu/dri:$${ORIGIN}/dri:/usr/lib/dri, suffix _dri)
libGL error: failed to load driver: swrast
[Open3D WARNING] GLFW Error: GLX: Failed to create context: GLXBadFBConfig
[Open3D WARNING] Failed to create window
[Open3D WARNING] [DrawGeometries] Failed creating OpenGL window.
X Error of failed request: BadWindow (invalid Window parameter)
Major opcode of failed request: 15 (X_QueryTree)
Resource id in failed request: 0x2c00026
Serial number of failed request: 1518
The text was updated successfully, but these errors were encountered: