DiscussionsIssue archiveOther usage issues

Forum archive

Other usage issues

Technical discussions preserved from the public OCCT community forum.

Topics
5,359
Replies
16,480
Files
825

Discussions

Page 7 of 90

Showing 60 discussions, ordered by the latest archived activity.

Build new project using ImportExport

Hello, I try to build a new project using ImportExport from OpenCascade. I created a new MFC project in VS 2005, set the include paths and insert "#include ". Then I started building and got the following error: "fatal error C1189: #error : 'Wrong compiler options has been detected. Add /DWNT option

10 replies

how to create a Geom_BSplineSurface

Hi All, I was trying to get the Geom_BSplineSurface to generate a B-Spline surface by putting inputs as the control points/ poles, u and v knot, u and v degree. I do not know how to input knots, as in if it is [0 0 0 1 2 3 3 3] (just an example), how do I type that in the Geom_BSplineSurface . Secon

6 replies2 files

What is DEFINE_HSEQUENCE good for?

Hi, I have been using DEFINE_HSEQUENCE and IMPLEMENT_HSEQUENCE to define individual sequences like that: DEFINE_HSEQUENCE(AttributeHandleSequence, NCollection_Sequence<Handle(TDF_Attribute)>) IMPLEMENT_HSEQUENCE(AttributeHandleSequence) but the more I think about it, the more I wonder why I have don

1 reply

OpenGl_GraphicDriver on OCCT 6.8.0

Hello, I have recently updated from OCCT 6.7.9 to OCCT 6.8.0, and according to the release notes, I had to do the following change (since it seems Graphic3D.hxx no longer exists): From this: ================================================================================================== #include C

3 replies

Message_ProgressIndicator::NewScope()

Hello, I am a new user of OpenCacade Library. I am facing an issue while using the Message_ProgressIndicator class of the library. I have overridden the Show() method in the my own child class of Message_ProgressIndicator where I get the name and position of the Message_ProgressScale using GetName()

3 replies

BRepOffsetAPI_MakeOffset

Hi Body, I use "BRepOffsetAPI_MakeOffset" in OCC4.0 and OCC3.1 to create a offset wire and try to use different Join type(GeomAbs_Tangent,GeomAbs_Arc,GeomAbs_Tangent), but the results are the same, the Join type seems always keep GeomAbs_Arc. Who can tell me, it is OCC Bug or my way is wrong. my cod

5 replies

Get shape from name of label from STEP/IGES file

How do I get the shape given a name? I've tried the following with no success for IGES and STEP files: char shapeName = "M-11"; IGESCAFControl_Reader::GiveList(shapeName); It is returning a null list and the following message: Neither Entity Number/Label nor Selection :M-11 The name is shown when vi

5 replies2 files

Memory leak in OpenCascade

I got memory leak when I use OpenCascade and got following memory issue. How do I clean it up? I am not familiar with OpenCascade. Thanks for your help. Author ==6867== 40,168 bytes in 3 blocks are still reachable in loss record 785 of 793 ==6867== at 0x4C2CC70: calloc (in /usr/lib/valgrind/vgpreloa

7 replies1 file

Memory leak using IGESControl_Reader

We are using IGESControl_Reader we noticed that there is memory leak when using IGESControl_Reader we found this memory leak when working on using VRAM for our software we tried the following instructions to free memory used by IGESControl_Reader without success 1) myIgesReader.IGESModel()->Destroy(

2 replies

point inside a shape speedup hints?

Hello, I have to perform a lot of "is point inside a shape" queries in my application. Currently I am doing the query through the BRepClass3d_SolidClassifier with some preliminary filtering (bounding box) but the code is quite slow so I am looking for some hints how to speed it up. The points (x,y,z

2 replies

Speed Depends on Number of Faces

Hi, I have found a strange behaviour of Open CASCADE 6.8.0 (but using the community edition) and I would like to share my measurements with you and ask for your experiences. My code is doing computations on shells by iterating over their faces and evaluating points and derivatives (D0 and D1). I hav

7 replies

DownCast to find Geom_TrimmedCurve

Hi All, I have a small problem !. I create an arc using, Handle(Geom_TrimmedCurve) curve = GC_MakeArcOfCircle(...) however, when I examine the type of this curve later on using downcasting..... Handle(Geom_TrimmedCurve)::DownCast(curve).IsNull() returns true but..... Handle(Geom_Circle)::DownCast(cu

2 replies

bug in 6.9.1

hello, the following code causes a crash in the oc6.9.1: TopoDS_Shape o_face; BRep_Builder o_builder; BRepTools::Read (o_face, "c:\\cylface.brep", o_builder); //attached file gp_Trsf o_trafo; o_trafo.SetTranslation (gp_Vec(500,0,0)); BRepBuilderAPI_Transform o_trafo_algo (o_face, o_trafo); o_face =

1 reply1 file

Error while Conversting from IGES to STL in VS2013 & OCC 6.9.1

Hi Everyone, I have written a code to convert from IGES/IGS file to STL file. When i was using OCC-6.6.0 this code was working perfectly, Due to some reasons i had to migrate to Visual studio 2013 so i downloaded OCC 6.9.1, Now i am facing with weird issue which i am not able to resolve. I have atta

1 reply2 files

Wrong Compiler Option

Hi all, I am using Qt 4.2.2 with VC++ 8.0 & OCC 6.1 and getting the folllowing compile time error: 1>c:\OpenCASCADE6.1.0\ros\inc\Standard_values.h(22) : fatal error C1189: #error : "Wrong compiler options has been detected. Add /DWNT option for proper compilation!!!!!" What could be the probable rea

3 replies

Sweep rotating the profile along the spine

Hi, I'm trying to sweep a profile on a spline but it seems that the profile remains in the same orientation... I'm using the BRepOffsetAPI_MakePipe(spine, profile) function. The attachment is a drawing that shows the desired result...

1 reply3 files

BSplCLib::Bohm

Dear All, I have been trying to figure out how the following function work in TKMath, in the package for BSplines: void BSplCLib::Bohm(const Standard_Real U, const Standard_Integer Degree, const Standard_Integer N, Standard_Real& Knots, const Standard_Integer Dimension, Standard_Real& Poles) Accordi

8 replies

Deflection and mesher

Hi, Looking for a mesher to convert from STEP/IGES to my own data format, I need to use a mesher. 1st question : What is the deflection ? I didn't found anything about that. And what about the Angle ? (default = 0.5) 2d question : Why is there so much mesher ? is there a best one ? * BRepMesh_Increm

12 replies2 files

How to Load STL File

Hi I can i load .STL file in OpenCasCade ? I found STL writer but not STL reader in ImportExport sample.

3 replies2 files

Display text in TPrsStd_Driver

Hello, I have implemented a presentation driver for my own OCAF attribute. The presentation driver inherits from TPrsStd_Driver. Now I would like to add text output at several different positions to the presentation. Is there an easy way to do that? I have stumbled over the class QABugs_MyText, whic

1 reply

HOW TO TRANSLATE BOUNDING BOX ?

Hi I have a question I have created bounding box. I want to translate it does anyone know how to do it thanks

1 reply

Point of Intersection Between Two Lines

I have two gp_Lin elements (lin1 and lin2), and I know that they intersect in 3D space (the value of lin1.distance(lin2) is 0). Is there a function I can use to find the point at which they intersect instead of coding it all by hand (I could not find one)? Thanks for any help! Author

2 replies

ComputedMode parameter of V3d_Viewer constructor

The contstructor of V3d_Viewer has two parameters which refer to the computed mode: const Standard_Boolean theComputedMode= Standard_True , const Standard_Boolean theDefaultComputedMode= Standard_True According to the documentation, these parameters refer to HLR (hidden line removal). If our applica

1 reply

Boolean Operation of 2d Faces in the same plane

Hi, I am trying to do a simple boolean operation in 2d. Essentially, all I need is the common area between a circle and another face. Unfortunately, I could not find any algorithm that would do this directly in 2d. Does anyone know an algorithm here? Then, I tried to produce 3d TopoDS_Faces from it

1 reply1 file

Split curve a set of curve with a same lenght

Hello, I tried to split a curve in set of curve with a same lenght. for a straight line , it is very simple, but in my case i have a general curve Geom_Curve. Does anyone have any suggestions for me? Thanks in advance

1 reply

Standard_Failure::Throw()

Dear all, I configure my development environment with occ6.9.1 successfully, But when I debug it ,there is a problem and turn to " void Standard_Failure::Throw() const { #ifndef NO_CXX_EXCEPTION throw *this; #endif }" I found thir program have problem "Handle(WNT_Window) aWNTWindow = new WNT_Window(

10 replies

BRepFeat_SplitShape with multiple wires

Is it possible to use BRepFeat_SplitShape functionality with more then one (intersecting) edge/wire? See the attached picture. Archived image: external image

2 replies1 file

IGESControl_Writer for vertex

I'm using the IGESControl_Writer to write out some points. I use the "write.iges.faces.mode" for the writer. The problem is that the points in the IGES file can be imported by OpenCASCADE IGESControl_Reader properly. Solidworks can detect the points in the IGES file, but I can't import them. I put a

1 reply2 files

How to merge or add several bounding boxes ?

Hello Im new to opencascade. I have a question i want to add/merge 2 bounding boxes ... i know how to make a bounding box but i dont know how to merge/add them ? your suggestions or remarks would be highly appreciated thanks

1 reply

OpenCascade ErrorStatus

i use OpenCasCade 6.7.0. When I Call the function BRepAlgoAPI_Cut and check ErrorStatus() i get 114 as result. Watching in documentation i got following Information: 0 - Ok 1 - The Object is created but Nothing is Done 2 - Null source shapes isstrong text not allowed 3 - Check types of the arguments

4 replies

OCCT6.8 WITH vs2010

Dear ALL, I want to use occt 6.8 with vs 2010 to develop my application ,but I am new to use it , Do you have a very simple demo? Regards,

1 reply

AIS_Trihedron

Hi, Does AIS_Trihedron support a shading mode? By default, its appears to be rendered as a wireframe mode, and by glancing the source code it seems like a shaded mode ( like the GraduatedTrihedronDisplay method of the V3d_View class ) is not support. That said, the documentation is not explicit abou

1 reply

how to search in the forum ?

Hi, I cannot find any way to search for an question o aswer in this new forum. How can I do it ?

3 replies

Flaw of void BSplCLib::LocateParameter

In BSplCLib::LocateParameter (called by SameParameter API), it will produce crash bug in some extreme case (OCC6.5.3 and OCC6.7.1). If your program got crash after stitching(sewing) in release version, it may be produced by BSplCLib::LocateParameter. Here is the code: void BSplCLib::LocateParameter

1 reply

OpenGl_GraphicDriver on OCCT 6.9.0

Hello eryar, I had to do the following change (since it seems Graphic3D.hxx no longer exists): From this: ================================================================================================== #include Create a Graphic Driver from the default Aspect_DisplayConnection Handle(Aspect_Displa

2 replies

Easier BRepBuilderAPI_MakeFace

I have been trying to get BRepBuilderAPI_MakeFace working but I have had some issues. First it was that the edges weren't connected into wires, so I used ShapeAnalysis_FreeBounds::ConnectEdgesToWires to get a closed wire, then I have seen other posts were they specify tolerances for the wire before

3 replies1 file

Error Making Spring!!

Hello! I am trying to draw a spring but i am doing one turn at once and then another turn until n(number of turns), but when i use BRepOffsetAPI_MakePipeShell or another function to do a pipe always remains a blank space where the Shapes doesn't fits, so my final shape when a use the BRepAlgoAPI_Fus

1 reply1 file

How to find end-start point of a arc

Hi I drew a arc. I want to know end Point and start point of arc. I wrote This Code gp_Ax2 a2(gp::Origin(), gp::DZ()); gp_Circ c(a2, 10); double startAngle = 180.0; double endAngle = 90.0; TopoDS_Edge arc = BRepBuilderAPI_MakeEdge(c, DEGTORAD(startAngle), DEGTORAD(endAngle)); draw(arc); BRepAdaptor_

1 reply

Resize trouble with porting bottle example to Qt 5.4

Hello, I have tried to port the OCC bottle example (samples/qt/tutorial) to Qt 5.4. Since there is no QWorkspace anymore, I have replaced it by QMdiArea. The windows for a document (in the sample called MDIWindow) inherit from QMainWindow (then I can add a tool bar). I add them to the QMdiArea with

6 replies1 file

Fix blanks spaces between Shapes!!

Hello! I am trying to draw a spring but i am doing one turn at once and then another turn until n(number of turns), but when i use BRepOffsetAPI_MakePipeShell or another function to do a pipe always remains a blank space where the Shapes doesn\'t fits, so my final shape when a use the BRepAlgoAPI_Fu

1 reply1 file

0025854: Visualization, TKOpenGl - add option to request Core profile 3.2+

Since OCC 6.9.0 there is an option to explicitly request OpenGL core profile (see http://tracker.dev.opencascade.org/view.php?id=25854 ). By default, compatibility profile is requested on Desktops. Does anything speak against requesting core profile if my application does not use custom OpenGL comma

1 reply

performance loss in 6.9.0 version

I have ported an application from version 6.6.0(32bit) to 6.9.0(64bit). The application is a toolpath simulator and displays, one by one, entities like segments and arcs using AIS_* objects. The application loads all the objects in an Interactive context, hide them , and than display one object a ti

5 replies

Geom_BezierCurve Bug. Please confirm or exclude.

Dear sirs May you please confirm or exclude that the crash occurring at the last line of following code is due to bug of the Geom_BezierCurve constructor ? main.cpp: ---------------------------------------------------------- #include #include #include #include #include int main(int argc, char *argv[

3 replies

StlMesh_Mesh destructor very slowly

I figured out that the destructor of a StlMesh_Mesh is very slowly. It takes about one or two minutes till it is finished. In this thread http://www.opencascade.org/org/forum/thread_24440/?forum=3 there is exactly the same problem with another class, but no solution was posted. Is there a way to mak

4 replies

About OCAF attribute TDataXtd_Point, TDataXtd_Point, TDataXtd_Plane

Hi, a main rule concerning OCAF is that is not possible to add two identical attributes (same classes) to a given label. Let us consider the TDataXtd_Point attribute. By adding this attribute in the label LAB, automatically a TNaming_NamedShape (BRep_TVertex) is added. Let us consider the TDataXtd_A

1 reply

TopoDS_Edge to TopoDS_Wire

Hi I have many connected and disconnected edges(vector). I'm want to convert TopoDS_Wire(vector thanks.

3 replies1 file

GeomAPI_PointsToBSpline not working properly

Hello All, I used GeomAPI_PointsToBSpline to generate a bspline curve. when I use the high tolerances such as 0.5 it seems that the output is not within the specified tolerance. I attached the pic of output which is plotted in MS Excel shows a deviation much more than 0.5. Any idea would be apprecia

2 replies1 file

BRepFeat does not work even though edge has PCurve on Face to split.

Dear all, I am trying to split a face using one edge (which intersects two edges and split the face in two) using the BRepFeat_SplitShape class. I am absolutely positive the edge has got a PCurve on the face. Indeed, I do a test using BRep_Tool::CurveOnSurface and the Handle to the Geom2d_Curve is a

3 replies1 file

TopoDS_Edge built from Geom2d_Curve and Geom_Surface has not PCurve on face

Dear Sirs, There is something I am not able to understand. I have a Handle(Geom2d_Curve) and an Handle(Geom_Surface)from which I create a TopoDS_Edge using the corresponding constructor from the BRepBuilderAPI_MakeEdge class. Note that the Handle(Geom2d_Curve) has been computed by projecting a Geom_

2 replies

undesired behavior of BRepOffset_MakeOffset

Hello, I found when the shape geometry has narrow gap, "BRepOffset_MakeOffset" may cause fault result. For example, I create a box as base, place another two boxes with space of 0.2 onto the base and fuse the three shapes together. Then if I set the "Offset" value smaller than 0.1, I can get correct

1 reply1 file

Units in STEP Files

Hi, with my OCCT based program I check and modify geometry and I am expecting lengths to be given in millimeter. For example when I measure distances between shapes, I expect the distance value to have unit millimeter. Now I have recognized that STEP files can define geometry with arbitrary units an

4 replies

scale of a curve

Dear all, I am working on scaling a curve only in x direction and the Y and Z value of the curve keep the same. The class used is BRepBuilderAPI_Transform which required a gp_Trsf as an iput. However, the SetScale() function in gp_Trsf only accept a scale center and a scale value. It can not do this

4 replies

Projecta 2d poin in to 3D plane

Hi I would like to know is there any API which support 2D coordinates projection into to arbitrary 3D plane.

3 replies

opencascade 6.7.1 g++ compile error in ubuntu 14.10 qt creator

hello, I tried to compiler my application from windows MSVC 2013 to ubuntu g++. I could configure and make opencascade 6.7.1 form source package in my ubuntu computer,but I could't use qt creator to compiler my application. The error message is: /home/cglab/opencascade-6.7.1/inc/Standard_Macro.hxx:4

2 replies2 files