当前位置: 首页 > news >正文

网站首页seo怎么做想做电商需要投资多少钱

网站首页seo怎么做,想做电商需要投资多少钱,邵阳找工作网站,企业网站样板制作目录 1、把曲线离散成点 1.1按数量离散 1.2按长度离散 1.3按弦高离散 2、由点合成曲线 2.1B样条插值 2.2B样条近似 1、把曲线离散成点 计算机图形学中绘制曲线#xff0c;无论是绘制参数曲线还是非参数曲线#xff0c;都需要先将参数曲线进行离散化#xff0c;通过离… 目录 1、把曲线离散成点 1.1按数量离散 1.2按长度离散 1.3按弦高离散 2、由点合成曲线 2.1B样条插值 2.2B样条近似 1、把曲线离散成点 计算机图形学中绘制曲线无论是绘制参数曲线还是非参数曲线都需要先将参数曲线进行离散化通过离散化得到一组离散化的点集然后再将点集发送给图形渲染管线进行处理最终生成我们想要的曲线。 OpenCASCADE中提供了GCPnts包。利用GCPnts包中提供的类我们可以很方便的将三维曲线进行离散化。 1.1按数量离散 #include Geom_CylindricalSurface.hxx#include gp_Ax3.hxx#include GeomAPI_Interpolate.hxx#include BRepAdaptor_Curve.hxx#include BRepBuilderAPI_MakeEdge.hxx#include Geom2d_TrimmedCurve.hxx#include GCE2d_MakeSegment.hxx​#include GeomAPI_PointsToBSpline.hxx#include BRepBuilderAPI_MakeFace.hxx#include GC_MakeCircle.hxx#include BRepBuilderAPI_MakeWire.hxx#include BRepOffsetAPI_MakePipe.hxx#include GC_MakeArcOfCircle.hxx#include BRepAlgoAPI_Fuse.hxx​#include gp_GTrsf.hxx#include BRepBuilderAPI_MakeVertex.hxx​#includeViewer.h​#include BRepAdaptor_CompCurve.hxx#include GCPnts_UniformAbscissa.hxx​int main(int argc, char* argv[]){ gp_Dir Z(0.0, 0.0, 1.0); gp_Pnt center(0, 0, 0.0); gp_Pnt xr(0.5, 0, 0.0); gp_Pnt yr(0.0, 1.0, 0.0); gp_Pnt zr(0.0, 0.0, 7.0); gp_Ax2 wb(center, Z); gp_Circ wbcircle(wb, 0.125 / 2); TopoDS_Edge wbe BRepBuilderAPI_MakeEdge(wbcircle); TopoDS_Wire te BRepBuilderAPI_MakeWire(wbe); BRepAdaptor_CompCurve compCurve(te); GCPnts_UniformAbscissa uniAbs(compCurve, 100, -1); gp_Pnt p; Viewer vout(50, 50, 500, 500); vout te; if (uniAbs.IsDone()) { for (Standard_Integer i 1; i uniAbs.NbPoints(); i) { Standard_Real u uniAbs.Parameter(i); compCurve.D0(u, p);//获取每个离散点 TopoDS_Vertex verti BRepBuilderAPI_MakeVertex(p); vout verti; }​ } vout.StartMessageLoop(); return 0;} 1.2按长度离散 #include Geom_CylindricalSurface.hxx#include gp_Ax3.hxx#include GeomAPI_Interpolate.hxx#include BRepAdaptor_Curve.hxx#include BRepBuilderAPI_MakeEdge.hxx#include Geom2d_TrimmedCurve.hxx#include GCE2d_MakeSegment.hxx​#include GeomAPI_PointsToBSpline.hxx#include BRepBuilderAPI_MakeFace.hxx#include GC_MakeCircle.hxx#include BRepBuilderAPI_MakeWire.hxx#include BRepOffsetAPI_MakePipe.hxx#include GC_MakeArcOfCircle.hxx#include BRepAlgoAPI_Fuse.hxx​#include gp_GTrsf.hxx#include BRepBuilderAPI_MakeVertex.hxx​#includeViewer.h​#include BRepAdaptor_CompCurve.hxx#include GCPnts_UniformAbscissa.hxx​int main(int argc, char* argv[]){ gp_Dir Z(0.0, 0.0, 1.0); gp_Pnt center(0, 0, 0.0); gp_Pnt xr(0.5, 0, 0.0); gp_Pnt yr(0.0, 1.0, 0.0); gp_Pnt zr(0.0, 0.0, 7.0); gp_Ax2 wb(center, Z); gp_Circ wbcircle(wb, 0.125 / 2); TopoDS_Edge wbe BRepBuilderAPI_MakeEdge(wbcircle); TopoDS_Wire te BRepBuilderAPI_MakeWire(wbe); BRepAdaptor_CompCurve compCurve(te); GCPnts_UniformAbscissa uniAbs; uniAbs.Initialize(compCurve, 0.05, -1); gp_Pnt p; Viewer vout(50, 50, 500, 500); vout te; if (uniAbs.IsDone()) { for (Standard_Integer i 1; i uniAbs.NbPoints(); i) { Standard_Real u uniAbs.Parameter(i); compCurve.D0(u, p);//获取每个离散点 TopoDS_Vertex verti BRepBuilderAPI_MakeVertex(p); vout verti; }​ } vout.StartMessageLoop(); return 0;} 1.3按弦高离散 #include Geom_CylindricalSurface.hxx#include gp_Ax3.hxx#include GeomAPI_Interpolate.hxx#include BRepAdaptor_Curve.hxx#include BRepBuilderAPI_MakeEdge.hxx#include Geom2d_TrimmedCurve.hxx#include GCE2d_MakeSegment.hxx​#include GeomAPI_PointsToBSpline.hxx#include BRepBuilderAPI_MakeFace.hxx#include GC_MakeCircle.hxx#include BRepBuilderAPI_MakeWire.hxx#include BRepOffsetAPI_MakePipe.hxx#include GC_MakeArcOfCircle.hxx#include BRepAlgoAPI_Fuse.hxx​#include GCPnts_QuasiUniformDeflection.hxx#include BRepBuilderAPI_MakeVertex.hxx​#includeViewer.h​#include BRepAdaptor_CompCurve.hxx#include GCPnts_UniformAbscissa.hxx​int main(int argc, char* argv[]){ gp_Dir Z(0.0, 0.0, 1.0); gp_Pnt center(0, 0, 0.0); gp_Pnt xr(0.5, 0, 0.0); gp_Pnt yr(0.0, 1.0, 0.0); gp_Pnt zr(0.0, 0.0, 7.0); gp_Ax2 wb(center, Z); gp_Circ wbcircle(wb, 0.125 / 2); TopoDS_Edge wbe BRepBuilderAPI_MakeEdge(wbcircle); TopoDS_Wire te BRepBuilderAPI_MakeWire(wbe); BRepAdaptor_CompCurve compCurve(te); GCPnts_QuasiUniformDeflection quasiUniDef; quasiUniDef.Initialize(compCurve, 0.08, GeomAbs_C0); gp_Pnt p; Viewer vout(50, 50, 500, 500); vout te; if (quasiUniDef.IsDone()) { for (Standard_Integer i 1; i quasiUniDef.NbPoints(); i) { pquasiUniDef.Value(i);//获取每个离散点 TopoDS_Vertex verti BRepBuilderAPI_MakeVertex(p); vout verti; }​ } vout.StartMessageLoop(); return 0;} 2、由点合成曲线 曲线曲面拟合Curve and Surface Fitting的方式可以分为两类插值interpolation和逼近approximation。采用插值的方式时所创建的曲线或曲面必须精确地满足所给的数据条件例如曲线通过所给的插值点。采用逼近的方式时创建的曲线或曲面不必精确地满足所给的数据条件只要在一定的误差范围内接近即可。 2.1B样条插值 #include Geom_CylindricalSurface.hxx #include gp_Ax3.hxx #include GeomAPI_Interpolate.hxx #include BRepAdaptor_Curve.hxx #include BRepBuilderAPI_MakeEdge.hxx #include Geom2d_TrimmedCurve.hxx #include GCE2d_MakeSegment.hxx ​ #include GeomAPI_PointsToBSpline.hxx #include BRepBuilderAPI_MakeFace.hxx #include GC_MakeCircle.hxx #include BRepBuilderAPI_MakeWire.hxx #include BRepOffsetAPI_MakePipe.hxx #include GC_MakeArcOfCircle.hxx #include BRepAlgoAPI_Fuse.hxx ​ #include GCPnts_QuasiUniformDeflection.hxx #include BRepBuilderAPI_MakeVertex.hxx ​ #includeViewer.h ​ #include BRepAdaptor_CompCurve.hxx #include GeomTools.hxx ​ int main(int argc, char* argv[]) {Handle(TColgp_HArray1OfPnt) aPoints new TColgp_HArray1OfPnt(1, 3);Handle(Geom_BSplineCurve) aBSplineCurve; ​aPoints-SetValue(1, gp_Pnt(0.0, 0.0, 0.0));aPoints-SetValue(2, gp_Pnt(1.0, 1.0, 0.0));aPoints-SetValue(3, gp_Pnt(2.0, 6.0, 3.0)); ​GeomAPI_Interpolate aInterpolater(aPoints, Standard_False, Precision::Approximation());aInterpolater.Perform();aBSplineCurve aInterpolater.Curve();//std::cout ok;TopoDS_Edge s BRepBuilderAPI_MakeEdge(aBSplineCurve);Viewer vout(50, 50, 500, 500);vout s;vout BRepBuilderAPI_MakeVertex(aPoints-Value(1));vout BRepBuilderAPI_MakeVertex(aPoints-Value(2));vout BRepBuilderAPI_MakeVertex(aPoints-Value(3));vout.StartMessageLoop();return 0; } 2.2B样条近似 #include Geom_CylindricalSurface.hxx#include gp_Ax3.hxx#include GeomAPI_Interpolate.hxx#include BRepAdaptor_Curve.hxx#include BRepBuilderAPI_MakeEdge.hxx#include Geom2d_TrimmedCurve.hxx#include GCE2d_MakeSegment.hxx​#include GeomAPI_PointsToBSpline.hxx#include BRepBuilderAPI_MakeFace.hxx#include GC_MakeCircle.hxx#include BRepBuilderAPI_MakeWire.hxx#include BRepOffsetAPI_MakePipe.hxx#include GC_MakeArcOfCircle.hxx#include BRepAlgoAPI_Fuse.hxx​#include GCPnts_QuasiUniformDeflection.hxx#include BRepBuilderAPI_MakeVertex.hxx​#includeViewer.h​#include BRepAdaptor_CompCurve.hxx#include GeomTools.hxx​int main(int argc, char* argv[]){ Handle(TColgp_HArray1OfPnt) aPoints new TColgp_HArray1OfPnt(1, 3); Handle(Geom_BSplineCurve) aBSplineCurve;​ aPoints-SetValue(1, gp_Pnt(0.0, 0.0, 0.0)); aPoints-SetValue(2, gp_Pnt(1.0, 1.0, 0.0)); aPoints-SetValue(3, gp_Pnt(2.0, 6.0, 3.0));​ GeomAPI_PointsToBSpline Approx(aPoints-Array1()); Handle(Geom_BSplineCurve) K Approx.Curve(); TopoDS_Edge s BRepBuilderAPI_MakeEdge(K); Viewer vout(50, 50, 500, 500); vout s; vout BRepBuilderAPI_MakeVertex(aPoints-Value(1)); vout BRepBuilderAPI_MakeVertex(aPoints-Value(2)); vout BRepBuilderAPI_MakeVertex(aPoints-Value(3)); vout.StartMessageLoop(); return 0;} ​
http://www.pierceye.com/news/717489/

相关文章:

  • 常平哪里有招计算机网站开发的商业网站制作
  • 手机关键词点击排名软件长春seo排名扣费
  • 海晏县公司网站建设湖南省郴州市汝城县
  • 蒙阴做网站做网站怎么提取视频无广告
  • 整个网站都在下雪特效怎么做贵州省住房与城乡建设厅网站
  • 腾讯合作网站建设有哪些公司自己的网站做防伪码
  • 网站制作完成ks刷粉网站推广马上刷
  • 网站注册域名位置网上买一个商标多少钱
  • 网站开发 无形资产门户网站搭建方案
  • 湘西北京网站建设网站建设好发信息网
  • 淄博公司网站建设网站设计编程有哪些
  • 如何获取网站访客qq如何知道一个网站用什么建设的
  • 快站app客户管理软件多少钱
  • 山西教育学会的网站建设工作做ppt课件的网站
  • 网站开发还有哪些班级网站如何去建设
  • 学校网站框架wordpress 多个网址导航
  • 茶叶红酒网站建设关键词的优化方法
  • 做网站后台用什么语言好吴川市建设工程公司网站
  • 海口专业网站建设公司怎样利用网站做淘宝客
  • 雄安专业网站建设方案长沙做网站建设
  • 微信上的网站实物黄金哪个网站做的好
  • 网站建设的作用和用途wordpress外网固定链接
  • 网站做多长时间才有流量上海商城网站制作公司
  • 做电影网站服务器网站如何备案 流程图
  • 太原建站模板搭建wordpress attachment
  • 购买腾讯备案网站网站错误列表
  • 怎么查看网站的外链php网站建设流程图
  • 顺企网萍乡网站建设wordpress 读者墙
  • 电力建设期刊网站投稿域名提供商
  • 广东网站备案需要多久oa信息化管理系统平台