示例#1
0
 public void Transform(Matrix3 m, Chart3D chart3d, Axes ax, 
     ChartStyle cs, ChartLabels cl)
 {
     // Normalize the point:
     float x1 = (X - ax.XMin) / (ax.XMax - ax.XMin) - 0.5f;
     float y1 = (Y - ax.YMin) / (ax.YMax - ax.YMin) - 0.5f;
     float z1 = (Z - ax.ZMin) / (ax.ZMax - ax.ZMin) - 0.5f;
     // Perform transformation on the point using matrix m:
     float[] result = m.VectorMultiply(new float[4] { x1, y1, z1, W });
     X = result[0];
     Y = result[1];
     // Coordinate transformation from World to Device system:
     float xShift = 1.05f;
     float xScale = 1;
     float yShift = 1.05f;
     float yScale = 0.9f;
     if (cl.Title == "No Title")
     {
         yShift = 0.95f;
         yScale = 1;
     }
     if (cs.IsColorBar)
     {
         xShift = 0.95f;
         xScale = 0.9f;
     }
     X = (xShift + xScale * X) * chart3d.Width / 2;
     Y = (yShift - yScale * Y) * chart3d.Height / 2;
 }
示例#2
0
 public ChartStyle2D(Chart3D ct3d)
 {
     chart3d = ct3d;
     chartArea = chart3d.ClientRectangle;
     plotArea = chartArea;
     chartBackColor = chart3d.BackColor;
     chartBorderColor = chart3d.BackColor;
 }
示例#3
0
 public ChartStyle(Chart3D ct3d)
 {
     chart3d = ct3d;
 }
示例#4
0
 public Axes(Chart3D ct3d)
 {
     chart3d = ct3d;
     axisStyle = new LineStyle();
 }
示例#5
0
 public ChartLabels(Chart3D ct3d)
 {
     chart3d = ct3d;
     tickFont = ct3d.Font;
 }
示例#6
0
 public ViewAngle(Chart3D ct3d)
 {
     chart3d = ct3d;
 }
示例#7
0
 public Grid(Chart3D ct3d)
 {
     chart3d = ct3d;
     gridStyle = new LineStyle();
 }
示例#8
0
 public DrawChart(Chart3D ct3d)
 {
     chart3d = ct3d;
 }