summaryrefslogtreecommitdiff
path: root/doc/classes/ImmediateMesh.xml
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes/ImmediateMesh.xml')
-rw-r--r--doc/classes/ImmediateMesh.xml13
1 files changed, 12 insertions, 1 deletions
diff --git a/doc/classes/ImmediateMesh.xml b/doc/classes/ImmediateMesh.xml
index a6d2e3e249..81fd62f85f 100644
--- a/doc/classes/ImmediateMesh.xml
+++ b/doc/classes/ImmediateMesh.xml
@@ -4,9 +4,20 @@
Mesh optimized for creating geometry manually.
</brief_description>
<description>
- Mesh optimized for creating geometry manually, similar to OpenGL1.x immediate mode.
+ A mesh type optimized for creating geometry manually, similar to OpenGL 1.x immediate mode.
+ Here's a sample on how to generate a triangular face:
+ [codeblocks]
+ var mesh = ImmediateMesh.new()
+ mesh.surface_begin(Mesh.PRIMITIVE_TRIANGLES)
+ mesh.surface_add_vertex(Vector3.LEFT)
+ mesh.surface_add_vertex(Vector3.FORWARD)
+ mesh.surface_add_vertex(Vector3.ZERO)
+ mesh.surface_end()
+ [/codeblocks]
+ [b]Note:[/b] Generating complex geometries with [ImmediateMesh] is highly inefficient. Instead, it is designed to generate simple geometry that changes often.
</description>
<tutorials>
+ <link title="Using ImmediateMesh">$DOCS_URL/tutorials/3d/procedural_geometry/immediatemesh.html</link>
</tutorials>
<methods>
<method name="clear_surfaces">