Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_ui/properties_physics_fluid.py
| Show First 20 Lines • Show All 433 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| col.prop(domain, "flame_ignition", text="Minimum") | col.prop(domain, "flame_ignition", text="Minimum") | ||||
| row = col.row() | row = col.row() | ||||
| row.prop(domain, "flame_smoke_color", text="Flame Color") | row.prop(domain, "flame_smoke_color", text="Flame Color") | ||||
| class PHYSICS_PT_liquid(PhysicButtonsPanel, Panel): | class PHYSICS_PT_liquid(PhysicButtonsPanel, Panel): | ||||
| bl_label = "Liquid" | bl_label = "Liquid" | ||||
| bl_parent_id = 'PHYSICS_PT_fluid' | bl_parent_id = 'PHYSICS_PT_fluid' | ||||
| COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_OPENGL'} | COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'} | ||||
| @classmethod | @classmethod | ||||
| def poll(cls, context): | def poll(cls, context): | ||||
| if not PhysicButtonsPanel.poll_liquid_domain(context): | if not PhysicButtonsPanel.poll_liquid_domain(context): | ||||
| return False | return False | ||||
| return (context.engine in cls.COMPAT_ENGINES) | return (context.engine in cls.COMPAT_ENGINES) | ||||
| ▲ Show 20 Lines • Show All 84 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| sub = col.column() | sub = col.column() | ||||
| sub.active = flow.use_particle_size | sub.active = flow.use_particle_size | ||||
| sub.prop(flow, "particle_size") | sub.prop(flow, "particle_size") | ||||
| class PHYSICS_PT_flow_initial_velocity(PhysicButtonsPanel, Panel): | class PHYSICS_PT_flow_initial_velocity(PhysicButtonsPanel, Panel): | ||||
| bl_label = "Initial Velocity" | bl_label = "Initial Velocity" | ||||
| bl_parent_id = 'PHYSICS_PT_settings' | bl_parent_id = 'PHYSICS_PT_settings' | ||||
| COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_OPENGL'} | COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'} | ||||
| @classmethod | @classmethod | ||||
| def poll(cls, context): | def poll(cls, context): | ||||
| if not PhysicButtonsPanel.poll_fluid_flow(context): | if not PhysicButtonsPanel.poll_fluid_flow(context): | ||||
| return False | return False | ||||
| if PhysicButtonsPanel.poll_fluid_flow_outflow(context): | if PhysicButtonsPanel.poll_fluid_flow_outflow(context): | ||||
| return False | return False | ||||
| ▲ Show 20 Lines • Show All 76 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| sub.prop(flow_smoke, "texture_offset") | sub.prop(flow_smoke, "texture_offset") | ||||
| class PHYSICS_PT_adaptive_domain(PhysicButtonsPanel, Panel): | class PHYSICS_PT_adaptive_domain(PhysicButtonsPanel, Panel): | ||||
| bl_label = "Adaptive Domain" | bl_label = "Adaptive Domain" | ||||
| bl_parent_id = 'PHYSICS_PT_settings' | bl_parent_id = 'PHYSICS_PT_settings' | ||||
| bl_options = {'DEFAULT_CLOSED'} | bl_options = {'DEFAULT_CLOSED'} | ||||
| COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_OPENGL'} | COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'} | ||||
| @classmethod | @classmethod | ||||
| def poll(cls, context): | def poll(cls, context): | ||||
| if not PhysicButtonsPanel.poll_gas_domain(context): | if not PhysicButtonsPanel.poll_gas_domain(context): | ||||
| return False | return False | ||||
| md = context.fluid | md = context.fluid | ||||
| domain = md.domain_settings | domain = md.domain_settings | ||||
| ▲ Show 20 Lines • Show All 192 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| else: | else: | ||||
| split.operator("fluid.free_mesh", text="Free Mesh") | split.operator("fluid.free_mesh", text="Free Mesh") | ||||
| class PHYSICS_PT_particles(PhysicButtonsPanel, Panel): | class PHYSICS_PT_particles(PhysicButtonsPanel, Panel): | ||||
| bl_label = "Particles" | bl_label = "Particles" | ||||
| bl_parent_id = 'PHYSICS_PT_liquid' | bl_parent_id = 'PHYSICS_PT_liquid' | ||||
| bl_options = {'DEFAULT_CLOSED'} | bl_options = {'DEFAULT_CLOSED'} | ||||
| COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_OPENGL'} | COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'} | ||||
| @classmethod | @classmethod | ||||
| def poll(cls, context): | def poll(cls, context): | ||||
| if not PhysicButtonsPanel.poll_liquid_domain(context): | if not PhysicButtonsPanel.poll_liquid_domain(context): | ||||
| return False | return False | ||||
| return (context.engine in cls.COMPAT_ENGINES) | return (context.engine in cls.COMPAT_ENGINES) | ||||
| ▲ Show 20 Lines • Show All 150 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| col = flow.column() | col = flow.column() | ||||
| col.prop(domain, "surface_tension", text="Surface Tension") | col.prop(domain, "surface_tension", text="Surface Tension") | ||||
| class PHYSICS_PT_guide(PhysicButtonsPanel, Panel): | class PHYSICS_PT_guide(PhysicButtonsPanel, Panel): | ||||
| bl_label = "Guides" | bl_label = "Guides" | ||||
| bl_parent_id = 'PHYSICS_PT_fluid' | bl_parent_id = 'PHYSICS_PT_fluid' | ||||
| bl_options = {'DEFAULT_CLOSED'} | bl_options = {'DEFAULT_CLOSED'} | ||||
| COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_OPENGL'} | COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'} | ||||
| @classmethod | @classmethod | ||||
| def poll(cls, context): | def poll(cls, context): | ||||
| if not PhysicButtonsPanel.poll_fluid_domain(context): | if not PhysicButtonsPanel.poll_fluid_domain(context): | ||||
| return False | return False | ||||
| return (context.engine in cls.COMPAT_ENGINES) | return (context.engine in cls.COMPAT_ENGINES) | ||||
| ▲ Show 20 Lines • Show All 341 Lines • Show Last 20 Lines | |||||