C++ CadCam program development with CodeBlocks instead of QT

More
31 May 2021 06:40 #210774 by Joco
A little bit of logical thinking and code detective work and I have found where to change the colours for the occ viewport widget. So now have something with better contrast.

Please Log in or Create an account to join the conversation.

More
04 Jun 2021 09:35 #211134 by Joco
I have the cavalier contours lib compiling correctly and processing a test contour on a shape. Working through how to best integrate that into the over all data model and then render it.

Still moving forward if a little slowly. Happy to post a zip file or expose the code base off a github account if anyone is keen to follow or play with it themselves.

Cheers - James.
The following user(s) said Thank You: Grotius

Please Log in or Create an account to join the conversation.

More
05 Jun 2021 14:36 - 05 Jun 2021 14:36 #211215 by Grotius
Hi James,

Nice to read about your progress.

I have done some extra research for opencascade.

1. An sich it is usefull to use the occt "wire" primitive. This is as a dxf lwpolyline we talked
about earlyer. A occt wire is easy to create. A wire may contain lines, arc's etc.
2. If you click a primitive on the screen, i can now show what item is selected by iterating over the selection list.
3. When doing a contour offset, you can add the contour offset as a occt "child" member. When deleting the primary path for example, the child's are deleted in the occt preview. This is quite handy.

If you need one of above examples, let me know.

One tiny problem i have to solve is when for example a line is clicked, i want to edit the line points to another value.
This is for live preview mode how a line should look like. The line endpoint is following the machine tcp point.
This sound's simple. But i think i have to ask this at the occt website help section how to do this.
Last edit: 05 Jun 2021 14:36 by Grotius.
The following user(s) said Thank You: Joco

Please Log in or Create an account to join the conversation.

More
05 Jun 2021 21:28 #211250 by Joco
Ive also been pondering and think i need to refactor a lot of what I have done to be using occ types. It was faster to define my own primitives/classes for a lot of things as I learned. It also got my head back into c++ a lot faster.

On the wire primitive, just to check you mean
dev.opencascade.org/doc/refman/html/class_topo_d_s___wire.html

And using the relevant api from
dev.opencascade.org/doc/refman/html/package_brepbuilderapi.html

Cheers - J.

Please Log in or Create an account to join the conversation.

More
06 Jun 2021 08:25 #211281 by Grotius
Hi James,

Yes, A wire is handy for clicking (selecting) contours by one mouseclick.
Attached my current opencascade class where you can find the occt object selecting function and how to create a wire.
It also show's how to create child members.

If you know how to edit a existing line point in occt, please let me know.
Attachments:
The following user(s) said Thank You: Joco

Please Log in or Create an account to join the conversation.

More
07 Jun 2021 07:57 #211406 by Joco

Grotius wrote: If you know how to edit a existing line point in occt, please let me know.


Not yet. If I come across a method I will sing out. At the moment still coming to grips with the patterns to be used with the occ framework.

Please Log in or Create an account to join the conversation.

Moderators: Skullworks
Time to create page: 0.105 seconds
Powered by Kunena Forum