コード例 #1
0
 public bool ChangePlane(int index, Plane plane)
 {
     CudaUtil.ChangePrimitiveColor(index, plane.materialColor);
     CudaUtil.ChangePrimitiveNormal(index, plane.normal);
     CudaUtil.ChangePrimitiveCentre(index, plane.centre);
     Log.instance.writeLog("将平面的参数变为,质心:" + plane.centre.x.ToString() + plane.centre.y.ToString() + plane.centre.z.ToString());
     Log.instance.writeLog("法向量" + plane.normal.x.ToString() + plane.normal.y.ToString() + plane.normal.z.ToString());
     return(true);
 }
コード例 #2
0
        public bool ChangeSphere(int index, Sphere sphere)
        {
            CudaUtil.ChangePrimitiveCentre(index, sphere.centre);
            CudaUtil.ChangePrimitiveColor(index, sphere.materialColor);
            CudaUtil.ChangePrimitiveRadius(index, sphere.radius);
            Log.instance.writeLog("将球的参数变为,质心:" + sphere.centre.x.ToString() + sphere.centre.y.ToString() + sphere.centre.z.ToString());

            return(true);
        }