当前位置: 首页>>代码示例>>C#>>正文


C# Geometry.ConstPointer方法代码示例

本文整理汇总了C#中Geometry.ConstPointer方法的典型用法代码示例。如果您正苦于以下问题:C# Geometry.ConstPointer方法的具体用法?C# Geometry.ConstPointer怎么用?C# Geometry.ConstPointer使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Geometry的用法示例。


在下文中一共展示了Geometry.ConstPointer方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: NativeGeometryConstPointer

 /// <summary>
 /// Returns the underlying const ON_Geometry* for a RhinoCommon class. You should only
 /// be interested in using this function if you are writing C++ code.
 /// </summary>
 /// <param name="geometry">A geometry object. This can be null and in such a case <see cref="IntPtr.Zero"/> is returned.</param>
 /// <returns>A pointer to the const geometry.</returns>
 public static IntPtr NativeGeometryConstPointer(Geometry.GeometryBase geometry)
 {
   IntPtr rc = IntPtr.Zero;
   if (geometry != null)
     rc = geometry.ConstPointer();
   return rc;
 }
开发者ID:jackieyin2015,项目名称:rhinocommon,代码行数:13,代码来源:interop.cs

示例2: UpdateToLeader

 public bool UpdateToLeader(Geometry.Leader leader, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstLeader = leader.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToLeader(m_parent.m_pObjectPairArray, m_index, pConstLeader, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例3: UpdateToBrep

 public bool UpdateToBrep(Geometry.Brep brep, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstBrep = brep.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToBrep(m_parent.m_pObjectPairArray, m_index, pConstBrep, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例4: UpdateToExtrusion

 public bool UpdateToExtrusion(Geometry.Extrusion extrusion, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstExtrusion = extrusion.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToExtrusion(m_parent.m_pObjectPairArray, m_index, pConstExtrusion, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例5: UpdateToSurface

 public bool UpdateToSurface(Geometry.Surface surface, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstSurface = surface.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToSurface(m_parent.m_pObjectPairArray, m_index, pConstSurface, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例6: UpdateToText

 public bool UpdateToText(Geometry.TextEntity text, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstText = text.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToText2(m_parent.m_pObjectPairArray, m_index, pConstText, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例7: Constrain

 /// <summary>Constrains the picked point to lie on a surface.</summary>
 /// <param name="surface">A surface to use as constraint.</param>
 /// <param name="allowPickingPointOffObject">
 /// defines whether the point pick is allowed to happen off object. When false,
 /// a "no no" cursor is shown when the cursor is not on the object. When true,
 /// a normal point picking cursor is used and the marker is visible also when
 /// the cursor is not on the object.
 /// </param>
 /// <returns>true if constraint could be applied.</returns>
 /// <example>
 /// <code source='examples\vbnet\ex_orientonsrf.vb' lang='vbnet'/>
 /// <code source='examples\cs\ex_orientonsrf.cs' lang='cs'/>
 /// <code source='examples\py\ex_orientonsrf.py' lang='py'/>
 /// </example>
 public bool Constrain(Geometry.Surface surface, bool allowPickingPointOffObject)
 {
   IntPtr ptr = NonConstPointer();
   IntPtr pSurface = surface.ConstPointer();
   return UnsafeNativeMethods.CRhinoGetPoint_Constrain8(ptr, pSurface, allowPickingPointOffObject);
 }
开发者ID:kalvo,项目名称:rhinocommon,代码行数:20,代码来源:rhinosdkgetpoint.cs

示例8: Add

 /// <summary>
 /// Adds a mesh to the list.
 /// </summary>
 /// <param name="mesh">A mesh to add.</param>
 /// <param name="asConst">Whether this mesh should be treated as non-modifiable.</param>
 public void Add(Geometry.Mesh mesh, bool asConst)
 {
   if (null != mesh)
   {
     IntPtr pMesh = mesh.ConstPointer();
     if (!asConst)
       pMesh = mesh.NonConstPointer();
     IntPtr ptr = NonConstPointer();
     UnsafeNativeMethods.ON_MeshArray_Append(ptr, pMesh);
   }
 }
开发者ID:kalvo,项目名称:rhinocommon,代码行数:16,代码来源:opennurbs_array.cs

示例9: SetBrep

 public bool SetBrep(int id, Geometry.Brep value)
 {
   IntPtr pThis = NonConstPointer();
   IntPtr pConstBrep = value.ConstPointer();
   return UnsafeNativeMethods.CRhinoHistory_SetBrep(pThis, id, pConstBrep);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例10: SetSurface

 public bool SetSurface(int id, Geometry.Surface value)
 {
   IntPtr pThis = NonConstPointer();
   IntPtr pConstSurface = value.ConstPointer();
   return UnsafeNativeMethods.CRhinoHistory_SetSurface(pThis, id, pConstSurface);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例11: DrawCurvatureGraph

 /// <summary>
 /// Draw a typical Rhino Curvature Graph.
 /// </summary>
 /// <param name="curve">Base curve for curvature graph.</param>
 /// <param name="color">Color of curvature graph.</param>
 /// <param name="hairScale">100 = true length, &gt; 100 magnified, &lt; 100 shortened.</param>
 /// <param name="hairDensity">&gt;= 0 larger numbers = more hairs (good default is 1).</param>
 /// <param name="sampleDensity">Between 1 and 10. Higher numbers draw smoother outer curves. (good default is 2).</param>
 public void DrawCurvatureGraph(Geometry.Curve curve, System.Drawing.Color color, int hairScale, int hairDensity, int sampleDensity)
 {
   int argb = color.ToArgb();
   IntPtr pCurve = curve.ConstPointer();
   UnsafeNativeMethods.CRhinoDisplayPipeline_DrawCurvatureGraph(m_ptr, pCurve, argb, hairScale, hairDensity, sampleDensity);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:14,代码来源:rhinosdkdisplaypipeline.cs

示例12: UpdateToHatch

 public bool UpdateToHatch(Geometry.Hatch hatch, DocObjects.ObjectAttributes attributes)
 {
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   IntPtr pConstHatch = hatch.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateToHatch(m_parent.m_pObjectPairArray, m_index, pConstHatch, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例13: SetMesh

 public bool SetMesh(int id, Geometry.Mesh value)
 {
   IntPtr pThis = NonConstPointer();
   IntPtr pConstMesh = value.ConstPointer();
   return UnsafeNativeMethods.CRhinoHistory_SetMesh(pThis, id, pConstMesh);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs

示例14: UpdateToAngularDimension

 public bool UpdateToAngularDimension(Geometry.AngularDimension dimension, ObjectAttributes attributes)
 {
   IntPtr pConstDimension = dimension.ConstPointer();
   IntPtr pConstAttributes = (attributes == null) ? IntPtr.Zero : attributes.ConstPointer();
   return UnsafeNativeMethods.CRhinoObjectPairArray_UpdateResult7(m_parent.m_pObjectPairArray, m_index, pConstDimension, pConstAttributes);
 }
开发者ID:gwinsky,项目名称:rhinocommon,代码行数:6,代码来源:rhinosdkcommand.cs


注:本文中的Geometry.ConstPointer方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。