Skip to content

Commit

Permalink
Merge pull request #76023 from Ansraer/3.x_orm
Browse files Browse the repository at this point in the history
[3.x] Add ORMSpatialMaterial
  • Loading branch information
akien-mga authored Feb 8, 2024
2 parents cc4492f + b9cbffd commit 354404d
Show file tree
Hide file tree
Showing 59 changed files with 1,568 additions and 1,444 deletions.
8 changes: 4 additions & 4 deletions doc/classes/CPUParticles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -128,15 +128,15 @@
</member>
<member name="color" type="Color" setter="set_color" getter="get_color" default="Color( 1, 1, 1, 1 )">
Each particle's initial color.
[b]Note:[/b] [member color] multiplies the particle mesh's vertex colors. To have a visible effect on a [SpatialMaterial], [member SpatialMaterial.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color] will have no visible effect.
[b]Note:[/b] [member color] multiplies the particle mesh's vertex colors. To have a visible effect on a [Material3D], [member Material3D.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color] will have no visible effect.
</member>
<member name="color_initial_ramp" type="Gradient" setter="set_color_initial_ramp" getter="get_color_initial_ramp">
Each particle's initial color will vary along this [GradientTexture] (multiplied with [member color]).
[b]Note:[/b] [member color_initial_ramp] multiplies the particle mesh's vertex colors. To have a visible effect on a [SpatialMaterial], [member SpatialMaterial.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color_initial_ramp] will have no visible effect.
[b]Note:[/b] [member color_initial_ramp] multiplies the particle mesh's vertex colors. To have a visible effect on a [Material3D], [member Material3D.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color_initial_ramp] will have no visible effect.
</member>
<member name="color_ramp" type="Gradient" setter="set_color_ramp" getter="get_color_ramp">
Each particle's color will vary along this [GradientTexture] over its lifetime (multiplied with [member color]).
[b]Note:[/b] [member color_ramp] multiplies the particle mesh's vertex colors. To have a visible effect on a [SpatialMaterial], [member SpatialMaterial.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color_ramp] will have no visible effect.
[b]Note:[/b] [member color_ramp] multiplies the particle mesh's vertex colors. To have a visible effect on a [Material3D], [member Material3D.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member color_ramp] will have no visible effect.
</member>
<member name="damping" type="float" setter="set_param" getter="get_param" default="0.0">
The rate at which particles lose velocity.
Expand All @@ -158,7 +158,7 @@
</member>
<member name="emission_colors" type="PoolColorArray" setter="set_emission_colors" getter="get_emission_colors">
Sets the [Color]s to modulate particles by when using [constant EMISSION_SHAPE_POINTS] or [constant EMISSION_SHAPE_DIRECTED_POINTS].
[b]Note:[/b] [member emission_colors] multiplies the particle mesh's vertex colors. To have a visible effect on a [SpatialMaterial], [member SpatialMaterial.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member emission_colors] will have no visible effect.
[b]Note:[/b] [member emission_colors] multiplies the particle mesh's vertex colors. To have a visible effect on a [Material3D], [member Material3D.vertex_color_use_as_albedo] [i]must[/i] be [code]true[/code]. For a [ShaderMaterial], [code]ALBEDO *= COLOR.rgb;[/code] must be inserted in the shader's [code]fragment()[/code] function. Otherwise, [member emission_colors] will have no visible effect.
</member>
<member name="emission_normals" type="PoolVector3Array" setter="set_emission_normals" getter="get_emission_normals">
Sets the direction the particles will be emitted in when using [constant EMISSION_SHAPE_DIRECTED_POINTS].
Expand Down
4 changes: 2 additions & 2 deletions doc/classes/EditorSpatialGizmoPlugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<method name="add_material">
<return type="void" />
<argument index="0" name="name" type="String" />
<argument index="1" name="material" type="SpatialMaterial" />
<argument index="1" name="material" type="Material3D" />
<description>
Adds a new material to the internal material list for the plugin. It can then be accessed with [method get_material]. Should not be overridden.
</description>
Expand Down Expand Up @@ -90,7 +90,7 @@
</description>
</method>
<method name="get_material">
<return type="SpatialMaterial" />
<return type="Material3D" />
<argument index="0" name="name" type="String" />
<argument index="1" name="gizmo" type="EditorSpatialGizmo" default="null" />
<description>
Expand Down
4 changes: 2 additions & 2 deletions doc/classes/Label3D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@
<member name="autowrap" type="bool" setter="set_autowrap" getter="get_autowrap" default="false">
If [code]true[/code], wraps the text to the [member width].
</member>
<member name="billboard" type="int" setter="set_billboard_mode" getter="get_billboard_mode" enum="SpatialMaterial.BillboardMode" default="0">
The billboard mode to use for the label. See [enum SpatialMaterial.BillboardMode] for possible values.
<member name="billboard" type="int" setter="set_billboard_mode" getter="get_billboard_mode" enum="Material3D.BillboardMode" default="0">
The billboard mode to use for the label. See [enum Material3D.BillboardMode] for possible values.
</member>
<member name="double_sided" type="bool" setter="set_draw_flag" getter="get_draw_flag" default="true">
If [code]true[/code], text can be seen from the back as well, if [code]false[/code], it is invisible when looking at it from behind.
Expand Down
Loading

0 comments on commit 354404d

Please sign in to comment.