Considerations about modelling huge and micro objects both present in a scene at same time.

Next
 From:  mkdm
7920.1 
Hi Michael,

I don't know if i'm asking you something banal or boring, but i've been considering if and how it's possible to model in Moi,
huge and micro objects both present in the scene at same time, without having any precision loss in the modelling workflow.

My current Moi's settings regarding the tolerance are :
Unit System = Millimeters, Decimal Display = 1.000,
Unit Options : Default Unit System = Millimeters, Both scale options set to TRUE

In order to explain my considerations, i'm posting here a .3dm file, complemented by some screen captures, of a scene where are present a huge object,
the pseudo bridge, and some small and micro objects, the little magenta cylinder and a little sphere.

Bounding box sizes of these objects are respectively :

pseudo bridge : X = 1166563.786 mm, Y = 73353.9095 mm, Z = 583281.893
little magenta cylinder : Radius = 150 mm, Height = 1000 mm
little sphere : X = 40 mm, Y = 40 mm, Z = 35.9809

Furthermore, the little sphere has some edges filleted with a radius of 0.05 mm

With that said, i currently have 2 main questions :

1) What about the internal tolerance and precision of the modelling operations when i have to operate on huge and micro objects in the same scene ?
That is, can i operate on both type of objects without any modelling precision loss ?

2) The attached pictures from 01... to 07..., show what happens when zooming closer and closer to the scene's objects.
As you can see, there's something strange that happens to the magnified objects.


My actual config is :
Latest Moi V3,
Windows 8.1 Pro 64 Bit English,
32 Gb Ram
Intel i4790K 4.4 Ghz
Nvidia Quadro K3100m 4Gb

Thanks for all and have a nice day,

Marco.

Image Attachments:
Size: 39.8 KB, Downloaded: 18 times, Dimensions: 843x511px
Size: 144.4 KB, Downloaded: 19 times, Dimensions: 1919x1035px
Size: 330.2 KB, Downloaded: 14 times, Dimensions: 1915x1036px
Size: 234.1 KB, Downloaded: 12 times, Dimensions: 1920x1035px
Size: 326.9 KB, Downloaded: 20 times, Dimensions: 1917x1035px
Size: 379.3 KB, Downloaded: 18 times, Dimensions: 1920x1035px
Size: 308.9 KB, Downloaded: 14 times, Dimensions: 1911x1030px
Size: 193.4 KB, Downloaded: 16 times, Dimensions: 1917x1033px
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
7920.2 In reply to 7920.1 
Hi Marco, it kind of fundamentally does not work very well with the computer's floating point math calculations to work on much larger sized objects, or on objects far away from the origin. The way the math functions is when you have a larger number, the numbers are using more of their bits for the larger scale and you lose numeric precision in the lower range.

So really I would generally recommend not making scenes like you've done here with an object that has large numeric values in it, either for size or location really in any CAD program unless they are designed to use special custom math functions to deal with that (which will have a huge performance loss and so only done for special cases). Try to limit things to maybe less than 10,000 units or so instead of in the millions.

Some of the more heavy duty geometry kernels like Parasolid for example actually limit sizes to less than something like 1000 units as a maximum coordinate value in order to enforce this.

But MoI does actually try to accommodate a varying range of sizes by adapting the tolerance used for calculations to be a fraction of the bounding box size of the object (or to the smallest feature on an object depending on the particular operation). So for example if you fillet your large million-sized object by a radius of 10000, the fillet tolerance will be something like 10 units, while if you fillet an object that's between 1 and 50 units in bounding box diagonal size it will use a tolerance of 0.001 units. Basically the tolerance automatically adjusts to the particular objects being worked on. If you have an operation where 2 objects are interacting with each other generally the smaller of the 2 tolerances will be used.

There are various different problems that can happen if the calculation tolerance is either too tight or too loose, so it's not a great idea to try and combine objects of hugely different scale with each other. But the "relative tolerance" size-relative mechanism that I've set MoI up with now seems to work a lot better for general use than just having a single fixed value which tends to be a big problem in Rhino. Originally MoI did use just a fixed tolerance of 0.001 but to solve various bugs I started to use the relative tolerance mechanism in some areas in MoI version 2, and moved more things over to use it in v3. I think there are still a few areas that aren't switched over yet though, I have mostly switched things when fixing specific bug cases.


> As you can see, there's something strange that happens to the magnified objects.

That's a display artifact where you're ending up seeing the near clipping plane in the perspective view. That's a limitation of 3D display hardware that's hard to avoid, every perspective view must have a near clipping plane that chops off things close to the eye point, and MoI tries to place it only a small distance in front of the eye so under regular circumstances with normal sized objects you won't see it. You will probably get better results for your case here if you switch the 3D view to a parallel projection instead of perspective projection.

Hope this was some of the information you were looking for.

- Michael

EDITED: 14 Apr 2016 by MICHAEL GIBSON

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  mkdm
7920.3 In reply to 7920.2 
Hi Michael,

I can't express how much i appreciated the way you explained the concepts about which I asked you.
Thank you very much!

More or less now all is clear in my mind, regarding the way Moi deals with the tolerance, and also, as a result, the way Rhino does it.

So, given everything that you told me, i want to ask you the these questions :

Now, let's say that i have to do a science fiction movie, and i want to model all the involved "actors" in Moi and Rhino,
and as final stage, animate all in a dedicated animation software, like Modo or Lightwave, or also Rhino with Bongo for very simple animation.

Given that, let's say again, the actors are a spaceship fleet, varying in size in the range of 10-100 meters, and a planet sized like the Earth.
What's a real good modelling workflow ?

Model the spaceship fleet and the planet in two separated stages, that is, two distinct .3dm files ?
But, in this case, how can i place all the objects together in any scene ?

Or did you mean that not with Moi nor in Rhino, is possible to do that ?

So, what i have to do in this situation ?
Maybe export all the objects in .obj format and only then i'll be able to assemble all the actors, in order to do the movie ?

If so, that means that the objects in .obj format can get rid of the tolerance, while until i'm working with nurb objects i always have to think about the tolerance ?

I'sorry if i ask you so many things, but if i don't gain in these concepts, it's as i'm swimming in the mud :)

Thank you very much again for you patience and good job!

Marco.

EDITED: 14 Apr 2016 by MKDM

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
7920.4 In reply to 7920.3 
Hi Marco,

> Given that, let's say again, the actors are a spaceship fleet, varying in size in the
> range of 10-100 meters, and a planet sized like the Earth.

I guess I'd recommend only modeling the spaceships in a CAD program like either MoI or Rhino, and create the planet only inside the animation program and not in CAD at all.

Or maybe you could render the planet separately using different unit scales for each in the modeles, and composite the renders together rather than trying to model the planet using the same units as your spaceships.

I'm not sure which way would be the best, you'd probably have to try a couple different ways. In some ways the animation programs will be less sensitive to tolerances at least at modeling time because they usually don't do operations using iterative solvers like CAD programs do where they refine a result like an intersection curve until it is within the target tolerance level. But with rendering as opposed to modeling there can still be tolerance issues in the animation program as well for stuff like bias factors in ray tracing where the start point of a shadow ray has to be moved slightly above a polygon so it doesn't hit the same polygon it's coming off of and result in self shadowing. Often times that's a fixed distance value and might need to be set to different values that are relative to the scale of the objects being rendered.


> If so, that means that the objects in .obj format can get rid of the tolerance, while until i'm
> working with nurb objects i always have to think about the tolerance ?

You may still need to worry about tolerances at render time if there are things like bias factors involved. You should probably do some simplified test runs using different methods to see if there are problems or not.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  mkdm
7920.5 In reply to 7920.4 
Michael, thank you very much for your recommendations and for your suggestions !

> But with rendering as opposed to modeling there can still be tolerance issues in the animation program as well for stuff
> like bias factors in ray tracing where the start point of a shadow ray has to be moved slightly above a polygon
> so it doesn't hit the same polygon it's coming off of and result in self shadowing.

Thanks for reminding me the existence of the "Trace Bias" involved in the calculations of the shadows inside of ray-tracing software. :)

> I guess I'd recommend only modeling the spaceships in a CAD program like either MoI or Rhino,
> and create the planet only inside the animation program and not in CAD at all.
>...
> I'm not sure which way would be the best, you'd probably have to try a couple different ways.

I'm going to do what you suggested in order to investigate the different approaches, and to experience at first hand the different results.

Thank you for all, and have a good night.

Marco.
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All