Search results

  1. B

    why is GC_MakeArcOfCircle function not behaving as expected?

    I looked into this briefly and have a couple of points to make. 1) you are using the constructor of gp_Ax2 that only takes one axis, the normal/z axis. OCCT is deriving the x axis. That x axis is currently unknown in your code. 2) the radian angle in the GC_MakeArcOfCircle constructor is from...
  2. B

    How to get correct stitching results?(BRepBuilderAPI_Sewing program)

    When I examine your file there are 2 shapes. One is a closed shell and the other is a face. I am not sure what you are trying to sew from this file.
  3. B

    How to get correct stitching results?(BRepBuilderAPI_Sewing program)

    Can you post the brep/step data?
  4. B

    Visualize PCurves of a face

  5. B

    Visualize PCurves of a face

    Can Drawexe or Analysis Situs create a graphical view of the pcurves of a face?
  6. B

    is there any tools to analysize OCC codes?

    Great question! I wish I had an answer and would love to hear other opinions. dynamic dispatch obfuscates IDE static analysis tools ... At least my IDE. So I worked on a dynamic call graph generation project where I: - made a custom build of occ turning off the compiler wizardry, so no inline -...
  7. B

    Unexpected Results from BRepFill_Filling() with Non-Planar Offset Wire

    I don't know how you derived the offset curves, but I am thinking: create the surface first by sweeping a line along helix, making sure things are bigger than the finished face. project helix onto surface making a pcurve. create offset edges in 2d parametric space. use the offset edges. as a...
  8. B

    why does GeomFill class break the creation of surface into three procedures?

    I agree that is pretty verbose for what you are trying to do. I started looking around and didn't find anything. Checked in on romans blog and he has pretty much the same procedure as you. I guess that is it for doing 'through curves' at the geometry level. Things are better at the topology...
  9. B

    Maybe there is a bug on Handle(Geom_Curve)->value()? Hope I am wrong T.T

    No you don't want to run that through sew. Can't you just write each shape individual to the step file? If not, you can wrap them in a compound.
  10. B

    OCC+VTK Interactor

    I used the same method of altering colors for selection highlights in cadseer. I can remembering reading a post by Robert Osfield (lead on OSG, VSG) where he was suggesting the copy method. I think the idea is that it is faster to make a small copy of data and push it across to the GPU, than it...
  11. B

    Splitting a shell into two shells by a plane

    Maybe: use BRepPrimAPI_MakeHalfSpace to turn you plane into a solid. Then run 2 boolean operations. Both with the shell as the argument and the halfspace as the tool. The first boolean operation is a cut and the second is a common. If concerned about performance, maybe the BOPAlgo_PaveFiller...
  12. B

    Something wrong when use BRepBuilderAPI_MakeFace to build a face through a face and wire.

    Welcome to opencascade. ;) It is probably because the wire is crossing the periodic boundary of your surface. If you rotate the surface 180 degrees around it's axis, it will probably work.
  13. B

    How to reverse the TopoDS_Edge, the TopoDS_Edge. Reversed() seems don't work.

    I finally realized that also. Whoops.
  14. B

    How to reverse the TopoDS_Edge, the TopoDS_Edge. Reversed() seems don't work.

    I made notes as I was looking at the code. Don't take what I wrote on faith and don't be offended, if I come across to opinionated. Why are you writing a step file from opencascade? use opencascades native format '.brep' for exchanging to other occt users. You should pass the occt allocator to...
  15. B

    How to reverse the TopoDS_Edge, the TopoDS_Edge. Reversed() seems don't work.

    TopoDS_Shape::Reversed() is a const function and returns a copy. Did you mean to call Reverse() instead?. If you would post some code, the people trying to help won't have to guess.
  16. B

    How to extend face on OCCT?

    I don't think opencascade has any ready made routines for what you are trying to do. Probably the closest is bopalgo remove features. I described a work around in another thread
  17. B

    Convert Handle(Geom2d_BSplineCurve) to Handle(Geom2d_Curve)

    Geom2d_BSpline curve is derived from Geom2d_Curve so you should be able to pass that handle straight into BRepBuilderAPI_MakeEdge. If you can't, I am guessing: const Handle(Geom2d_BSplineCurve) curve = interp.Curve(); needs to be changed to: const Handle(Geom2d_BSplineCurve) &curve =...
  18. B

    BOPAlgo_InvalidCurveOnSurface and tolerances.

    IMHO: It looks like the magic number of sample points was accepted practice in the early days of opencascade and has since fell out of favor for logical algos. I think BRepLib_ValidateEdge is an attempt to bridge between the two. If I understand it correctly...
  19. B

    BOPAlgo_InvalidCurveOnSurface and tolerances.

    I was experimenting with tightening tolerances when I noticed the tightening operation was causing BOPAlgo_InvalidCurveOnSurface errors in BOPAlgo_ArgumentAnalyzer. I see BOPAlgo_InvalidCurveOnSurface errors quite frequently so decided to look into it. Here is my unit test. It should be self...
  20. B

    How to rotate around pivot

    rotate about a point