34 lines
747 B
C#
34 lines
747 B
C#
using System.ComponentModel.DataAnnotations;
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace RobotNet.VDA5050.Order;
|
|
|
|
public class ControlPoint
|
|
{
|
|
[Required]
|
|
[JsonPropertyName("x")]
|
|
public double X { get; set; }
|
|
|
|
[Required]
|
|
[JsonPropertyName("y")]
|
|
public double Y { get; set; }
|
|
|
|
[JsonPropertyName("weight")]
|
|
public double? Weight { get; set; }
|
|
}
|
|
|
|
public class Trajectory
|
|
{
|
|
[Required]
|
|
[JsonPropertyName("degree")]
|
|
public int Degree { get; set; }
|
|
|
|
[Required]
|
|
[JsonPropertyName("knotVector")]
|
|
public double[] KnotVector { get; set; } = [];
|
|
|
|
[Required]
|
|
[JsonPropertyName("controlPoints")]
|
|
public ControlPoint[] ControlPoints { get; set; } = [];
|
|
}
|