Click or drag to resize

VisualServer.CanvasItemAddPrimitive Method

Adds a primitive to the CanvasItem's draw commands.

Namespace:  Godot
Assembly:  GodotSharp (in GodotSharp.dll) Version: 1.0.0
Syntax
C#
public static void CanvasItemAddPrimitive(
	RID item,
	Vector2[] points,
	Color[] colors,
	Vector2[] uvs,
	RID texture,
	float width = 1f,
	RID normalMap = null
)

Parameters

item
Type: Godot.RID

[Missing <param name="item"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

points
Type:Godot.Vector2[]

[Missing <param name="points"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

colors
Type:Godot.Color[]

[Missing <param name="colors"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

uvs
Type:Godot.Vector2[]

[Missing <param name="uvs"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

texture
Type: Godot.RID

[Missing <param name="texture"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

width (Optional)
Type: System.Single

[Missing <param name="width"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

normalMap (Optional)
Type: Godot.RID

[Missing <param name="normalMap"/> documentation for "M:Godot.VisualServer.CanvasItemAddPrimitive(Godot.RID,Godot.Vector2[],Godot.Color[],Godot.Vector2[],Godot.RID,System.Single,Godot.RID)"]

See Also