CloudCompare / CloudComPy

Python wrapper for CloudCompare
Other
271 stars 39 forks source link

Visualisation using CloudComparePy in CloudCompare #178

Open niklesh98 opened 3 weeks ago

niklesh98 commented 3 weeks ago

Hi,

I would like to know if it is possible to load the files and then viusalise them using CloudCompare, directly through CloudComPy. i.e(I do not wish to manually drag and drop the files for comparison).

Use case: I have two meshes (one from a CAD file, one from a 3D scan) and I have performed best fit on them. I want to compare the distance between them (for quality inspection) and identify regions where there are defects, using a color map. I have written a python script for all this, however I am not able to visualsie it using CloudCompare.

I am aware there are options to add these to render scene (https://www.simulation.openfields.fr/documentation/CloudComPy/html/userUseCases.html#render-a-3d-scene-to-an-image-file) and see them as images. However, I was hoping it would be great if the user can rotate, move and zoom in and out of the meshes during visualisation .

Is this already available thorugh CloudComPy? Thank you!

prascle commented 3 weeks ago

Hello, Have you seen the last option in (https://www.simulation.openfields.fr/documentation/CloudComPy/html/userUseCases.html#render-a-3d-scene-to-an-image-file) ? The cloudComPy.render() function has an optional argument to play with the view before saving the file.

What operating system do you use? The function works on Windows and Linux, but not on macOs. I will try to fix that.

Best regards, Paul

prascle commented 2 weeks ago

Hi Nik,

You can use the mesh method getAssociatedCloud to work on the cloud associated with the mesh. When you define and select a scalar field on the cloud, and display the mesh for rendering, the scalar field will be rendered on the mesh.

Best, Paul

Le jeu. 4 juil. 2024 à 17:27, niklesh98 @.***> a écrit :

Hi Paul,

Thanks for your answer. I am able to do it now. I use Windows.

I was wondering if it is possible to set the scalar fields based on distances, on a mesh and try to visualise it using render()? I am able to do it currently using a cloud.

Cheers, Nik

— Reply to this email directly, view it on GitHub https://github.com/CloudCompare/CloudComPy/issues/178#issuecomment-2209229788, or unsubscribe https://github.com/notifications/unsubscribe-auth/APFRPQ7MIBMVKSIJFPZDMR3ZKVSUNAVCNFSM6AAAAABKH3ZNQWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBZGIZDSNZYHA . You are receiving this because you commented.Message ID: @.***>