mirror of
https://github.com/godotengine/godot.git
synced 2024-12-04 18:14:14 +00:00
6f51eca1e3
* Previous "virtual" classes (which can't be instantiated) are not corretly named "abstract". * Added a new "virtual" category for classes, they can't be instantiated from the editor, but can be inherited from script and extensions. * Converted a large amount of classes from "abstract" to "virtual" where it makes sense. Most classes that make sense have been converted. Missing: * Physics servers * VideoStream * Script* classes. which will go in a separate PR due to the complexity involved.
60 lines
2.7 KiB
XML
60 lines
2.7 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<class name="Material" inherits="Resource" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
|
|
<brief_description>
|
|
Abstract base [Resource] for coloring and shading geometry.
|
|
</brief_description>
|
|
<description>
|
|
Material is a base [Resource] used for coloring and shading geometry. All materials inherit from it and almost all [VisualInstance3D] derived nodes carry a Material. A few flags and parameters are shared between all material types and are configured here.
|
|
</description>
|
|
<tutorials>
|
|
<link title="3D Material Testers Demo">https://godotengine.org/asset-library/asset/123</link>
|
|
<link title="Third Person Shooter Demo">https://godotengine.org/asset-library/asset/678</link>
|
|
</tutorials>
|
|
<methods>
|
|
<method name="_can_do_next_pass" qualifiers="virtual const">
|
|
<return type="bool" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
<method name="_can_use_render_priority" qualifiers="virtual const">
|
|
<return type="bool" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
<method name="_get_shader_mode" qualifiers="virtual const">
|
|
<return type="int" enum="Shader.Mode" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
<method name="_get_shader_rid" qualifiers="virtual const">
|
|
<return type="RID" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
<method name="inspect_native_shader_code">
|
|
<return type="void" />
|
|
<description>
|
|
</description>
|
|
</method>
|
|
</methods>
|
|
<members>
|
|
<member name="next_pass" type="Material" setter="set_next_pass" getter="get_next_pass">
|
|
Sets the [Material] to be used for the next pass. This renders the object again using a different material.
|
|
[b]Note:[/b] This only applies to [StandardMaterial3D]s and [ShaderMaterial]s with type "Spatial".
|
|
</member>
|
|
<member name="render_priority" type="int" setter="set_render_priority" getter="get_render_priority">
|
|
Sets the render priority for transparent objects in 3D scenes. Higher priority objects will be sorted in front of lower priority objects.
|
|
[b]Note:[/b] This only applies to [StandardMaterial3D]s and [ShaderMaterial]s with type "Spatial".
|
|
[b]Note:[/b] This only applies to sorting of transparent objects. This will not impact how transparent objects are sorted relative to opaque objects. This is because opaque objects are not sorted, while transparent objects are sorted from back to front (subject to priority).
|
|
</member>
|
|
</members>
|
|
<constants>
|
|
<constant name="RENDER_PRIORITY_MAX" value="127">
|
|
Maximum value for the [member render_priority] parameter.
|
|
</constant>
|
|
<constant name="RENDER_PRIORITY_MIN" value="-128">
|
|
Minimum value for the [member render_priority] parameter.
|
|
</constant>
|
|
</constants>
|
|
</class>
|