Page MenuHome

Mantaflow [Part 3]: Customized UI for Manta fluids
ClosedPublic

Authored by Sebastián Barschkis (sebbas) on Oct 29 2018, 5:05 PM.

Diff Detail

Repository
rB Blender
Branch
pythonScripts (branched from master)
Build Status
Buildable 4642
Build 4642: arc lint + arc unit

Event Timeline

UI improvement for particle settings and path field in fluid domain settings.

Hi @Sebastián Barschkis (sebbas)! Is there a particular design you'd like for @William Reynish (billreynish) and I to review or give feedback?

With the new single-column layout and sub-panels it should be much easier to organize. I don't have a lot of experience with MantaFlow but if you could share some screenshots we can give you feedback.

Thanks!

Hi @Pablo Vazquez (pablovazquez)! Yes, right, I've made use of the single column layout for the new Mantaflow options too.

It looks all good except for one part where I am not sure: The check boxes for domain borders.

Right now, there is no indication that "Front", "Left", etc. actually refer to "Front Border", "Left Border", etc.

One could have added "Border" to all of the checkbox texts ... but I felt it would clutter the UI too much.

Any idea how we can make it more clear that these checkboxes refer to borders? In 2.79 it just uses a label (which seems to be used less in 2.8)

@Sebastián Barschkis (sebbas): In the example you posted, a sub-panel could be useful. You could call it 'Borders Collisions' and put the checkboxes inside. Simple.

Update manta files after merge with master.

Harbormaster completed remote builds in B3293: Diff 14644.

@William Reynish (billreynish) That's in fact a good idea! Thx! Would look like this:

Think it's a solid solution. Was just wondering though if it is possible to define the placement of a sub-panel in the parent panel. Or do they always sit at the bottom?

I find it a bit hard to test this given that this seems to be split over several different patches. But I think the UI layouts of the properties is not likely to be an issue, unless you are doing something very weird or out of the ordinary - and we can easily move things around a bit if needed, post-merge.

@Sebastián Barschkis (sebbas) Maybe I could get you to post just an image which includes all the panels?

Again, it seems very unlikely that there will be something in the UI that would be blocking in terms of a merge.

Yep, I agree. Picture of the whole UI is definitely helpful too, will post one.

To see all the diffs in action you can build the "fluid-mantaflow" branch. It has all the diffs in it.

One UI feature that would be "new to Blender in this extent" are the Bake buttons. I guess they should be fine but maybe this is one last thing to confirm.

And here is the UI overview (domain settings only). The left is for smoke, the right for liquids. Again, nothing too crazy. It's mostly fields for factors.

I would say that looks fine. Probably we should put the Viscosity Preset in the header like we do for other presets now, but other than that I see no real issues - nothing blocking anyway.

@Sebastián Barschkis (sebbas), How far off is your branch from this patch set? applying 10 patches may be pushing it, but if all the same stuff is in the branch that'll make testing a little easier.

@Ray Molenkamp (LazyDodo) At this point branch "fluid-mantaflow" is 100% the same as these diffs, i.e. after updating the diffs I merged everything back into fluid-mantaflow (which still had been on 2.79). So yes, to see everything in action "fluid-mantaflow" will be helpful.

Not much to say here, besides the style issue (double empty lines between py classes definitions please ;) ).

release/scripts/startup/bl_operators/object_quick_effects.py
548–549

This one and its whole class should be removed I guess? You already remove it from the quick effect menu…

release/scripts/startup/bl_ui/properties_physics_smoke.py
30

Please leave two empty lines between class definitions, this is part of PEP8 rules (same below too).

Updated diff with latest changes from fluid-mantaflow branch

Updated diff with latest changes from fluid-mantaflow branch

@William Reynish (billreynish) The current UI still looks similar to the one from here (there are just some additional float parameters here and there).

And here is the UI overview (domain settings only). The left is for smoke, the right for liquids. Again, nothing too crazy. It's mostly fields for factors.

So if nothing else blocks, can the UI team approve the layout?

For now, I left the viscosity settings you mentioned earlier as they are. I think the entire Manta viscosity setup will change in the future - I just don't know how it will look like.
And so I found that keeping it identical to the current fluids UI would be the best solution.

Sergey Sharybin (sergey) added inline comments.
release/scripts/startup/bl_ui/properties_data_modifier.py
948 ↗(On Diff #19923)

Is "manta" a really generic term, or is it something related to a specific implementation/library integration?

Sebastián Barschkis (sebbas) marked an inline comment as done.Dec 10 2019, 7:14 PM
Sebastián Barschkis (sebbas) added inline comments.
release/scripts/startup/bl_ui/properties_data_modifier.py
948 ↗(On Diff #19923)

"manta" is just the shortcut of mantaflow that some people like to use (including me). So it is related to a library and, I agree, shouldn't be used in the UI.
Right now, the name manta should not show up in the actual GUI. Of course, scripts could still access "manta".

Sebastián Barschkis (sebbas) marked an inline comment as done.Dec 10 2019, 9:53 PM

f4db26f01b78 fixes two more cases where "Manta" was still showing up in the UI (replaced it with "Fluid").

@Sergey Sharybin (sergey) for the rest of the Python scripts where "manta" is being used, should this be changed to "fluid" too? I.e. get rid of "manta" and replace it with "fluid"?

Or were you just referring two "Manta" in the GUI?

Well, if there is too much discontinuity between UI and API and internal code it's not that great. Having those in sync helps a lot figuring out where things came from and where to look for them.

Unfortunately, i don't have strong suggestion here. Calling things "fluid" isn't 100% correct because it also covers "smoke", and i am unaware of a technical term which will cover both of them.

Braindump on possible ways:

  • Accept the confusion, move on with the current state, refine/adjust as we go later on
  • Have Smoke and Fluid exposed as separate modifiers (same as it is currently), have Mata as a backend.
  • Converge everything to Fluid
  • Find a proper common term for fluids and smoke.

But Iam also curios to hear from @Campbell Barton (campbellbarton) on this topic/

Well, if there is too much discontinuity between UI and API and internal code it's not that great. Having those in sync helps a lot figuring out where things came from and where to look for them.

Unfortunately, i don't have strong suggestion here. Calling things "fluid" isn't 100% correct because it also covers "smoke", and i am unaware of a technical term which will cover both of them.

Braindump on possible ways:

  • Accept the confusion, move on with the current state, refine/adjust as we go later on
  • Have Smoke and Fluid exposed as separate modifiers (same as it is currently), have Mata as a backend.
  • Converge everything to Fluid
  • Find a proper common term for fluids and smoke.

But Iam also curios to hear from @Campbell Barton (campbellbarton) on this topic/

In fact AFAIK smoke and liquid are both fluids, gaseous fluid and liquid fluid, people tend to relate fluid with liquid but if I’m not wrong that’s not correct, so fluid should be correct and embraces both gaseous and liquid fluids, but @Sebastián Barschkis (sebbas) may confirm this or correct me :)

  • Find a proper common term for fluids and smoke.

Just like @Juan Gea (juang3d) said, fluid seems to be the correct word for both, according to Oxford dictionary:
https://www.lexico.com/en/definition/fluid

A substance that has no fixed shape and yields easily to external pressure; a gas or (especially) a liquid.

I would also say "fluid" is the best term for this. "manta" was only chosen because "fluid" was taken by the old fluid simulator. But now that that's gone it should be possible to use "fluid" again.

This comment was removed by Juan Gea (juang3d).

Updated diff with latest changes from fluid-mantaflow branch

There are still possible renaming from manta to fluid, but it doesn't seem to be intrusive for users.

So once again, i'd rather see movement towards having manta in Blender and address those non-intrusive refactors during bcon2.

This revision is now accepted and ready to land.Dec 13 2019, 12:26 PM

Updated diff with latest changes from fluid-mantaflow branch