Displaced surface and Object not lining up

Next question from me…

I started on a Boat wake setup now, linking the grid to the Boat. I used the infinite ocean extension and the same map for displacement in the grid.
But now I´m getting a displaced surface, that doesn´t line up with the Boat, where they are in contact.
Any Idea what I´m doing wrong?

here is an Image showing the Issue.
For further explanation: The grid is position constrained to the boat, the boat itself is animated in position and rotation.

well, no idea yet, if you can attach the scene that may help

I´m attaching the scene below. Notice that I had to switch out the Boat used for collision with a dummy due to the NDA.
I tried turning off the displacement in the grid and it worked as it should, so it´s probably a problem with some displacement setting.
If you could have a look at the scene, maybe you can also tell me why there is that straight wave going through the surface?
Guess it has to do with the inertia and i´m hoping it will dissapear after it goes through the grid once, I haven´t simulated more than the first 50 frames yet…
And I also have the clipping issue I already read about in some other posts, the cameras are not fixed yet, but we will have some shots pretty close to the surface. So should I reduce the wind speed and increase the height to get proper results or was it the other way around?
3055_Phoenix_Ocean_TestA_001_NDA.zip (1.49 MB)

I just saw the video you posted on vimeo, the ship in ocean simulation. I´d love to see the scene setup and i read in the comments that you would sent them to customers! Would be a great help, since we need a very similar shot.

do you have nightly build access? i can’t see nothing disturbing in the simulation, and suppose you are using the official version, that can not simulate this scene, because the technique allowing you to bind the simulator to the boat and to simulate only the near surface was not implemented in it.
besi this, some optimization tricks, you will need them because the simulation scenes are always time consuming
- your grid have huge empty space above the sea. keep the empty space as low as possible! phoenix is grid based, and the entire area in the grid takes CPU resource, do not assume that the empty spaces are not simulated. if you expect that some splash droplets may fly up to this zone, don’t worry, the splash and foam are able to leave the container, use the outside life option
- do not use GI when render atmosphere effects, this include splash and foam. i specially asked about this people with deep fx experience in this area, the GI is faked with ambient light and/or multiple direct lights.
- keep the grid in front of the boat as low as possible, there are nothing to simulate in this area.
one trouble that may be expected: when the speed or the resolution increases, the classic advection start to form self-arising waves along the movement, in your case they will be placed in the back side of the grid, because in the front side a fresh water is incoming that have no waves, and they grow during the water passes the grid and near to the end may become visible. one tested solution for this problem is to increase the SPF, however this increases the simulation time too. another possible but not tested solution is to switch to FT advection, it does not have this issue, but it can’t keep flat surface for long time, however in our case this may be not a problem, because the water stays in the grid few seconds. but never tested it, if you have waves problem, try it.
on the beginning of the simulation a shock wave starts from the front and you have to simulate until it reaches the end. this is not a big problem, because you have to wait the wake formation anyway. you can see the shock wave in the attached picture just behind the boat.
one more tip - do not produce foam directly, use the “foam on hit” option of the splash. be careful with the splash and the foam, they can easily overload the system. the parameters you have to observe:
- their count. the splash must be about 1-3M, the foam must be bigger in count, because it forms the wake. the amount is controlled by the birth rate for the splash, but the foam is more complex. the birth is controlled by the foam on hit parameter of the splash, and the lifespan is controlled by the halflife parameter.
- the parameters b2b of the foam and “liquid like” of the splash. these parameters can increase the simulation time dramatically, they produce particle-particle forces and are really important for the good appearance, but must be kept as low as possible. for the foam use b2b about 200-500, for the splash 1-3 depending on the dynamics.

hey, thanks for the quick reply!

I think we just downloaded the latest Version from the download area for 3DS Max 2013. How do I get access to the nightly builds?

your grid have huge empty space above the sea.

Thats great, and yeah, I actually was afraid about the splashes, thats why I was wasting so much space! So I guess i´ll just simulate a couple of frames without splashes to see how high the grid needs to be above the water level and go from there.

do not use GI when render atmosphere effects, this include splash and foam

So for the right workflow I would just add a Vray Atmospheric Element and exclude the foam/splash objects from GI?

one trouble that may be expected: when the speed or the resolution increases, the classic advection start to form self-arising waves along the movement, in your case they will be placed in the back side of the grid, because in the front side a fresh water is incoming that have no waves, and they grow during the water passes the grid and near to the end may become visible. one tested solution for this problem is to increase the SPF, however this increases the simulation time too. another possible but not tested solution is to switch to FT advection

Yeah, I noticed this effect wehn I simulated a grid with about 70m cells over night, the artifacts became clearly visible.
I´ll try both methods and will report back!

one more tip - do not produce foam directly, use the “foam on hit” option of the splash. be careful with the splash and the foam, they can easily overload the system. the parameters you have to observe:
- their count. the splash must be about 1-3M, the foam must be bigger in count, because it forms the wake. the amount is controlled by the birth rate for the splash, but the foam is more complex. the birth is controlled by the foam on hit parameter of the splash, and the lifespan is controlled by the halflife parameter.

I already noticed the huge amount of foam particles created with the foam emitted separately, so I´ll avoid that.
Is there a way to get the count after simulating a couple of frames, or a formula to calculate the expected count for the Splash / Foam-Particles?
And what about the splash-size? Right now I got it at 0.05m, but that seemed to big, so I put a multiplier of 0.5 in the PHXFoam object.
or would you recommend using the PA-button in the PHX Object? I´m not completely sure I understood how this would work- I would animate the multiplier lets say from 1 to 01. over the course of 2 seconds, as far as I understood.

Sorry for asking so many questions, trying to learn everything from scratch in the middle of a production can be quite stressful..:wink:

And now I almost forgot my original question…
I´ll post a picturecomparison of the displacement issue as soon as I get the time.
It was clearly visible in my test, wehn I switched off the displacement in the Sim…

I attached both pictures for comparison below.
Since I used an initial fill up of 20, I als input that value in the Rendering Tab behind the checkbox for “ocean”.
I also enabled displacement and just left the value at 1.0, type to surface driven.
I haven´t quite understood what effect the Surface level in the Rendering Tab has, it´s at 0.4 now

Here is the pic with displacement disabled:

And here it is with displacement enabled:


write to the support for nightly access, i hope tomorrow the ship scene will be included in the samples and when you install the product you can find it in my documents/phoenix fd/samples
about the displacement issue - the mesher takes the camera parameters and builds “infinite” surface only in the visible area. despite the fact that it is 20% wider, the displacement may push the border inside that visible area. that is very annoying, but we have no good solution yet. you can try to avoid it by rendering bigger area and cutting the frame, or by changing the seed of the ocean texture, or to change the waves direction.

Thanks for the reply, that is also good to know, but it wasn´t the issue I meant.
The displaced ocean seems to get pushed down and to the side, and that way it doesn´t line up with the ship anymore.

I guess I could just try and offset the ship to be rendered from the ship used as simulation dummy, but of course it would be easier, if there was just some setting I´m missing or doing wrong.
I´ll try to upload some more screenshots, when I find the time.

I´ll write support, I already got the ship scene from this morning.

do you have nightly build access? you CAN’T simulate any scenes of this type with the official release.
there are significant changes made after the official release.

Not yet, I´ll write back, once I got access and time to resim with nightly build.

there are at least three major changes
- in the official release the water is supported by walls, and if you move the container they become visible. these walls were replaced by pressure support later
- there is a bug in the inertial forces, that produces wrong centrifugal forces if the container is rotated, this means only the linear movement is correct
- the splash birth is not precise enough and you can’t get these sharp foamy crests that you can see in the ship scene
if you need a nightly today for weekend experiments, i can send you a build, just tell me max/vray version

Nightly build for the weekend would actually be great, I´ll send you my mail adress per PM.

I already noticed the container rotation problem, for now I just position constrained the container to the boat, so when the boat rotates the container doesn´t.

Still no Idea on the displacement issue though, once I have time to test the ship scene I´ll maybe get a clue what I did wrong.

Thank you for the nightly build, great help in figuring out a good setup!
It also showed, that the displacement is working correctly if done right.
The reason it is not lining up in my scene must have to do something with the way I linked the grid with the boat in some way.
I linked the grid to a dummy object (via a position constraint with “keep initial offset” checked) that is moving straight forward and then i linked the Ship object to the dummy object, so i could animate some secondary movement.
This must somehow have messed with the displacement.
I still can´t get it to work, it´s probably best if I just start from scratch.
Unless I´m still doing something wrong in my workflow. For example:
Does the displacement need to be checked in the rendering Tab before or after simulation, so that the splashes and foam line up with the core fluid?
I´m currently simulating the grid without splash and foam and then resim.
This creates two extra objects (PG of system…etc).
Do I need to link those objects to the moving dummy object aswell?

I finally found the splash and particle count now aswell!

the displacement is added to the particles rendertime, so no need to enable it during the simulation.
the splash and foam nodes in the scene are just helper objects and do not play any role in the rendering, they exist only to allow us to use the “pick object” function of max and all the other parameter tools like undo, redo, save in file etc…

I see. So my issue with displacement must definitely be because of the way I linked the grid to the moving boat. I´ll try it again tomorrow, when I start on the fluid simulations.

Is the ship scene only in the maya nightlies?

We are using max and you can ask support nicely to send you the demo scene…:wink:

By the way: I figured out what caused the problem in the first place: I rotated the coordinates in the Phoenix Ocean texture map by 60° when testing to get different direction of the waves. Once I rotated those back to zero, the displacement lined up perfectly. So I guess it´s best to just build your scene and orient the grid in a way, that you get waves to flow in the direction you want, right?