LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

3D objects are cut when adding mesh objects

Hy everyone

I have a problem in my 3D scene project. I creat several 3D object (sphere), than I add a mesh object that descrips a circle around the sphere. What happen is, that the surface of the sphere is cut.

Here are two picture, one without the mesh, one with mesh. If anybody is interested I can post some example Vis. Let me know.

I tried many things, I search the internet many hours,but no hints.It seems, that somehow the mesh that cross the 3D object cause this strange thing.

Has anyone an idea?

Alessandro

Download All
0 Kudos
Message 1 of 8
(3,532 Views)

Hi Alessandro,

 

can you please post your code that produces the behavior?

 

Best regards,

Melanie

Best regards,
Melanie Eisfeld
Senior Applications Engineer, National Instruments Germany
Certified LabVIEW Developer
Certified TestStand Architect
0 Kudos
Message 2 of 8
(3,261 Views)

Hi Melanie

 

Here it is.

 

Thank you for having a look at it.

 

Best regards, Alessandro

Download All
0 Kudos
Message 3 of 8
(3,246 Views)

Hi Alessandro,

 

thank you for the code.

 

I ran it several times with some parts deactiavted but I receive the same result everytime.

 

Did you get the program work, so in some configuration the surface is not cut?

 

It may be that the surface is cut because the "camera" in inside the sphere, but we should be able to see that, when drawing spheres with smaller radius or remove the mesh.

 

Please let me know about any configuration that shows the correct spheres.

 

Best regards,

Melanie

Best regards,
Melanie Eisfeld
Senior Applications Engineer, National Instruments Germany
Certified LabVIEW Developer
Certified TestStand Architect
0 Kudos
Message 4 of 8
(3,226 Views)

Hi Melanie

When you use the Zoom in/out option (that thing with the mouse and the shift key pressed) or by rotating with the mouse you can get states where the sphere isn't cut.

Kind ragards, Alessandro

PS: I have to leave now. I'm back in a few hours.

Thank you

0 Kudos
Message 5 of 8
(3,222 Views)

Hi Melanie

You can also just desable the execution of the Bahnkurven_Versuch.vi. Then you have all the spheres but now mesh an everything looks grate.

Thank you.

Kind regards, Alessandro

0 Kudos
Message 6 of 8
(3,199 Views)

Hi Alessandro,

 

I am back again now, too.

 

I did some playing arround yesterday and found, that, when zooming out, the sphere is complete. So this seems to be related to the camera position in the 3D picture control.

 

When the camera is located inside the sphere, you can only see the part of the sphere, that is in front of the camera. the rest is cut.

 

I modified your code a bit and put a while loop around the 3D picture control, since I was not able to zoom otherwise. So, I do not recreate any items in your model, only redraw the existing data to zoom.

 

Best regards,

Melanie

Best regards,
Melanie Eisfeld
Senior Applications Engineer, National Instruments Germany
Certified LabVIEW Developer
Certified TestStand Architect
0 Kudos
Message 7 of 8
(3,173 Views)

Hi Melanie
Thanks for the reply.
The point is that without the mesh around the sphere you got different behaviour than with the mesh. It seems, that adding the mesh to the 3D scene change the clip plane. When I'm near the sphere and the whole sphere is show properly, the sphere disappears when adding the mesh.
There is another interesting thing. By rotating the whole scene you can also influence this cutting. It seems that when you are looking on the sphere horizontal to the mesh the sphere is cut. Not so when you look vertical to the mesh on the sphere .
I tried many things and read many articles.
The following approaches I have followed:
•    The meshes are much bigger than the sphere, I thought, that the depth of the 3D scene cause changing the clip plane of the camera somehow. I tried playing with clip plane properties.
•    I changed the order of adding objects to the 3D scene. I thought that probably the order of adding influence the order of rendering.
•    I played around with the orthographical and spherical properties of the 3D picture control. By using the orthographical properties everything works well.
•    I have read that the normal array of the mesh influence the rendering of the objects. I tried a while.
•    I played with the culling properties, the blending modes and almost all other properties.
Finally I think that it has something to do with the viewing volume.
The goal is to have a spherical 3D scene in which I can move all objects by using transformations. I would like to go as near as possible to an object and that adding other objects do not affect the 3D scene, except that I see the added object.
Do you think there is any solution? It doesn’t matter what kind of solution. If necessary I can change the whole software.
Thanks for reading.
Kind regards, Alessandro

 

 

0 Kudos
Message 8 of 8
(3,160 Views)