Beispiel #1
0
 /// <summary>
 /// Return number of commands.
 /// </summary>
 private uint GetNumCommands()
 {
     Runtime.ValidateRefCounted(this);
     return(RenderPath_GetNumCommands(handle));
 }
Beispiel #2
0
 private string GetTypeName()
 {
     Runtime.ValidateRefCounted(this);
     return(Marshal.PtrToStringAnsi(DebugRenderer_GetTypeName(handle)));
 }
Beispiel #3
0
 private static string GetTypeNameStatic()
 {
     Runtime.Validate(typeof(DebugRenderer));
     return(Marshal.PtrToStringAnsi(DebugRenderer_GetTypeNameStatic()));
 }
Beispiel #4
0
 /// <summary>
 /// Return the projection transform.
 /// </summary>
 private Urho.Matrix4 GetProjection()
 {
     Runtime.ValidateRefCounted(this);
     return(DebugRenderer_GetProjection(handle));
 }
Beispiel #5
0
 /// <summary>
 /// Return whether has something to render.
 /// </summary>
 public bool HasContent()
 {
     Runtime.ValidateRefCounted(this);
     return(DebugRenderer_HasContent(handle));
 }
Beispiel #6
0
 /// <summary>
 /// Add a quad on the XZ plane.
 /// </summary>
 public void AddQuad(Urho.Vector3 center, float width, float height, Urho.Color color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddQuad(handle, ref center, width, height, ref color, depthTest);
 }
Beispiel #7
0
 /// <summary>
 /// Return whether line antialiasing is enabled.
 /// </summary>
 private bool GetLineAntiAlias()
 {
     Runtime.ValidateRefCounted(this);
     return(DebugRenderer_GetLineAntiAlias(handle));
 }
Beispiel #8
0
 public TriangleMeshData(CustomGeometry custom)
 {
     Runtime.Validate(typeof(TriangleMeshData));
 }
Beispiel #9
0
 /// <summary>
 /// Set line antialiasing on/off. Default false.
 /// </summary>
 private void SetLineAntiAlias(bool enable)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_SetLineAntiAlias(handle, enable);
 }
Beispiel #10
0
 /// <summary>
 /// Enable/disable commands and rendertargets by tag.
 /// </summary>
 public void SetEnabled(string tag, bool active)
 {
     Runtime.ValidateRefCounted(this);
     RenderPath_SetEnabled(handle, tag, active);
 }
Beispiel #11
0
 public TriangleMeshData(Model model, uint lodLevel)
 {
     Runtime.Validate(typeof(TriangleMeshData));
 }
Beispiel #12
0
 /// <summary>
 /// Append data from an XML file. Return true if successful.
 /// </summary>
 public bool Append(Urho.Resources.XmlFile file)
 {
     Runtime.ValidateRefCounted(this);
     return(RenderPath_Append(handle, (object)file == null ? IntPtr.Zero : file.Handle));
 }
Beispiel #13
0
 /// <summary>
 /// Clone the rendering path.
 /// </summary>
 public RenderPath Clone()
 {
     Runtime.ValidateRefCounted(this);
     return(Runtime.LookupRefCounted <RenderPath> (RenderPath_Clone(handle)));
 }
Beispiel #14
0
 /// <summary>
 /// Return command at index, or null if does not exist.
 /// </summary>
 public RenderPathCommand *GetCommand(uint index)
 {
     Runtime.ValidateRefCounted(this);
     return(RenderPath_GetCommand(handle, index));
 }
Beispiel #15
0
 /// <summary>
 /// Add a circle.
 /// </summary>
 public void AddCircle(Urho.Vector3 center, Urho.Vector3 normal, float radius, Urho.Color color, int steps, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddCircle(handle, ref center, ref normal, radius, ref color, steps, depthTest);
 }
Beispiel #16
0
 /// <summary>
 /// Set the camera viewpoint. Call before rendering, or before adding geometry if you want to use culling.
 /// </summary>
 public void SetView(Camera camera)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_SetView(handle, (object)camera == null ? IntPtr.Zero : camera.Handle);
 }
Beispiel #17
0
 /// <summary>
 /// Add a cross.
 /// </summary>
 public void AddCross(Urho.Vector3 center, float size, Urho.Color color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddCross(handle, ref center, size, ref color, depthTest);
 }
Beispiel #18
0
 /// <summary>
 /// Add a line with color already converted to unsigned.
 /// </summary>
 public void AddLine(Urho.Vector3 start, Urho.Vector3 end, uint color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddLine0(handle, ref start, ref end, color, depthTest);
 }
Beispiel #19
0
 /// <summary>
 /// Update vertex buffer and render all debug lines. The viewport and rendertarget should be set before.
 /// </summary>
 public void Render()
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_Render(handle);
 }
Beispiel #20
0
 /// <summary>
 /// Add a triangle with color already converted to unsigned.
 /// </summary>
 public void AddTriangle(Urho.Vector3 v1, Urho.Vector3 v2, Urho.Vector3 v3, uint color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddTriangle1(handle, ref v1, ref v2, ref v3, color, depthTest);
 }
Beispiel #21
0
 /// <summary>
 /// Return the view transform.
 /// </summary>
 private Urho.Matrix3x4 GetView()
 {
     Runtime.ValidateRefCounted(this);
     return(DebugRenderer_GetView(handle));
 }
Beispiel #22
0
 /// <summary>
 /// Add a scene node represented as its coordinate axes.
 /// </summary>
 public void AddNode(Node node, float scale, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddNode(handle, (object)node == null ? IntPtr.Zero : node.Handle, scale, depthTest);
 }
Beispiel #23
0
 /// <summary>
 /// Check whether a bounding box is inside the view frustum.
 /// </summary>
 public bool IsInside(Urho.BoundingBox box)
 {
     Runtime.ValidateRefCounted(this);
     return(DebugRenderer_IsInside(handle, ref box));
 }
Beispiel #24
0
 /// <summary>
 /// Add a bounding box with transform.
 /// </summary>
 public void AddBoundingBox(Urho.BoundingBox box, Urho.Matrix3x4 transform, Urho.Color color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddBoundingBox2(handle, ref box, ref transform, ref color, depthTest);
 }
Beispiel #25
0
 private StringHash UrhoGetType()
 {
     Runtime.ValidateRefCounted(this);
     return(new StringHash(DebugRenderer_GetType(handle)));
 }
Beispiel #26
0
 /// <summary>
 /// Add a cylinder
 /// </summary>
 public void AddCylinder(Urho.Vector3 position, float radius, float height, Urho.Color color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddCylinder(handle, ref position, radius, height, ref color, depthTest);
 }
Beispiel #27
0
 private static StringHash GetTypeStatic()
 {
     Runtime.Validate(typeof(DebugRenderer));
     return(new StringHash(DebugRenderer_GetTypeStatic()));
 }
Beispiel #28
0
 /// <summary>
 /// Add a triangle mesh.
 /// </summary>
 public void AddTriangleMesh(void *vertexData, uint vertexSize, void *indexData, uint indexSize, uint indexStart, uint indexCount, Urho.Matrix3x4 transform, Urho.Color color, bool depthTest)
 {
     Runtime.ValidateRefCounted(this);
     DebugRenderer_AddTriangleMesh(handle, vertexData, vertexSize, indexData, indexSize, indexStart, indexCount, ref transform, ref color, depthTest);
 }
Beispiel #29
0
 /// <summary>
 /// Register object factory.
 /// </summary>
 public new static void RegisterObject(Context context)
 {
     Runtime.Validate(typeof(DebugRenderer));
     DebugRenderer_RegisterObject((object)context == null ? IntPtr.Zero : context.Handle);
 }
Beispiel #30
0
 /// <summary>
 /// Set a shader parameter in all commands that define it.
 /// </summary>
 public void SetShaderParameter(string name, bool value)
 {
     Runtime.ValidateRefCounted(this);
     RenderPath_SetShaderParameter_12(handle, name, value);
 }