- Posts: 2419
- Thank you received: 2349
QT C++ code samples
- Grotius
- Offline
- Platinum Member
-
Less
More
7 years 2 days ago - 7 years 2 days ago #149090
by Grotius
Replied by Grotius on topic QT C++ code samples
Little project update..
Made a sample drawing to find out the program functionality at the moment.
I have work on several tiny cases.
To make this drawing, multiple modify functions are used like :
- offset, rotate, copy, move, mirror, chamfer, fillet
The used draw functions :
- line, line_strip, 2p_circle, 6 side polygon, ellipse, arc
For now i am satisfied so far.
Hopely within a few day's we can start with the g_code processing part.. This will become fun for sure..
I wish everyone a good day !
Made a sample drawing to find out the program functionality at the moment.
I have work on several tiny cases.
To make this drawing, multiple modify functions are used like :
- offset, rotate, copy, move, mirror, chamfer, fillet
The used draw functions :
- line, line_strip, 2p_circle, 6 side polygon, ellipse, arc
For now i am satisfied so far.
Hopely within a few day's we can start with the g_code processing part.. This will become fun for sure..
I wish everyone a good day !
Last edit: 7 years 2 days ago by Grotius.
The following user(s) said Thank You: phillc54, tommylight, Clive S
Please Log in or Create an account to join the conversation.
- tommylight
- Offline
- Moderator
-
Less
More
- Posts: 22011
- Thank you received: 7491
7 years 2 days ago #149130
by tommylight
Replied by tommylight on topic QT C++ code samples
Never mind us, we're just drooling here !
Please Log in or Create an account to join the conversation.
- Grotius
- Offline
- Platinum Member
-
Less
More
- Posts: 2419
- Thank you received: 2349
7 years 1 day ago - 7 years 1 day ago #149239
by Grotius
Replied by Grotius on topic QT C++ code samples
@Thank you Tom..
I googled "drooling", i understand it now.
Today i solved most of the tiny cases..
Added today :
-add shift key for anti select an item.
-keyboard input distance for copy with ortho
-added a angle start and angle recalculate function after a arc mirror
-added midpoint for chamfer line
-added arc curve midpoint for fillet arc
-added arc fillet endpoints to curve.
Have to do left :
-expand the dxf write file and read file class for ellipse and bezier curve and spline.. This is not difficult to do
-add arc-arc trim, arc-line trim, arc-arc extend, arc-line extend
-add arc-line fillet, arc-arc fillet
-add select previous object
-add dimension class
-change the extend and trim icons into a more fancy icon
Thinking about :
1. Excel file output on top of a dxf file output.
This excel file output is usefull when a calculation program is linked with python. All drawing parameters are available.
2. Autonesting algoritme..
3. Fractal based patterns.. or something to do with fractals and random calculation. Also a time based or animation based
calculation is interesting to do. But it has to be usefull within the cad cam program.
For autonesting the output must be something like this :
-orange = 1500x3000mm plate
-red = outside contour
-yellow = inside contour
How would you code this? :whistle:
if else.. area 1 > area 2.. check longest object, etc.. Input about autonesting thought's is welcome !
I googled "drooling", i understand it now.
Today i solved most of the tiny cases..
Added today :
-add shift key for anti select an item.
-keyboard input distance for copy with ortho
-added a angle start and angle recalculate function after a arc mirror
-added midpoint for chamfer line
-added arc curve midpoint for fillet arc
-added arc fillet endpoints to curve.
Have to do left :
-expand the dxf write file and read file class for ellipse and bezier curve and spline.. This is not difficult to do
-add arc-arc trim, arc-line trim, arc-arc extend, arc-line extend
-add arc-line fillet, arc-arc fillet
-add select previous object
-add dimension class
-change the extend and trim icons into a more fancy icon
Thinking about :
1. Excel file output on top of a dxf file output.
This excel file output is usefull when a calculation program is linked with python. All drawing parameters are available.
2. Autonesting algoritme..
3. Fractal based patterns.. or something to do with fractals and random calculation. Also a time based or animation based
calculation is interesting to do. But it has to be usefull within the cad cam program.
For autonesting the output must be something like this :
-orange = 1500x3000mm plate
-red = outside contour
-yellow = inside contour
How would you code this? :whistle:
if else.. area 1 > area 2.. check longest object, etc.. Input about autonesting thought's is welcome !
Last edit: 7 years 1 day ago by Grotius.
The following user(s) said Thank You: tommylight, Clive S
Please Log in or Create an account to join the conversation.
- tommylight
- Offline
- Moderator
-
Less
More
- Posts: 22011
- Thank you received: 7491
7 years 1 day ago #149241
by tommylight
Replied by tommylight on topic QT C++ code samples
At the moment i have no idea about autonesting, well i have no idea about anything, been working to much lately !
Regards,
Tom.
Regards,
Tom.
The following user(s) said Thank You: Grotius
Please Log in or Create an account to join the conversation.
- Grotius
- Offline
- Platinum Member
-
Less
More
- Posts: 2419
- Thank you received: 2349
6 years 11 months ago #149513
by Grotius
Replied by Grotius on topic QT C++ code samples
Hi Tom,
Take your free time !
A little project update..
Picture one is a normal drawing.. 1128 objects..
Picture two is the same drawing, but then calculated by the contour recognize class. It's an algoritme that took me about 2 - 3 day's.
I had to use the while c++ function's...
The cad array's stay orginal, unmodified & unsorted, but the output
is rearranged by the algoritme in one flow and can be directly converted to g-code later on in the process.
This contour recognize class is used after the contour offset class is done, wich i will make soon !!
The logic about smaller object's into the bigger objects has to be written coming time. Have to make some area calculations..
and see if contours are inside each other.. I hope this is easy..
This important logic works nice :
color yellow = rearranged to ccw
color red = rearranged to cw
color grey = no offset
the cw, ccw for circles has to be done.
When we know wich object is inside each other, we can change object direction to outside or inside offset,
because we now know the predefined rearranged direction, that is currently visible with different colors.
Anyone idea's about autonesting?
picture 1, raw cad drawing
picture 2, contour recognized..
Take your free time !
A little project update..
Picture one is a normal drawing.. 1128 objects..
Picture two is the same drawing, but then calculated by the contour recognize class. It's an algoritme that took me about 2 - 3 day's.
I had to use the while c++ function's...
The cad array's stay orginal, unmodified & unsorted, but the output
is rearranged by the algoritme in one flow and can be directly converted to g-code later on in the process.
This contour recognize class is used after the contour offset class is done, wich i will make soon !!
The logic about smaller object's into the bigger objects has to be written coming time. Have to make some area calculations..
and see if contours are inside each other.. I hope this is easy..
This important logic works nice :
color yellow = rearranged to ccw
color red = rearranged to cw
color grey = no offset
the cw, ccw for circles has to be done.
When we know wich object is inside each other, we can change object direction to outside or inside offset,
because we now know the predefined rearranged direction, that is currently visible with different colors.
Anyone idea's about autonesting?
picture 1, raw cad drawing
picture 2, contour recognized..
The following user(s) said Thank You: phillc54, tommylight, Clive S
Please Log in or Create an account to join the conversation.
- tommylight
- Offline
- Moderator
-
Less
More
- Posts: 22011
- Thank you received: 7491
6 years 11 months ago #149516
by tommylight
All i can think about is i have machine parts waiting to be painted and they are outside while it is raining since last night. Not good.
Thank you.
Regards,
Tom.
Replied by tommylight on topic QT C++ code samples
Nope ! Sorry.Grotius wrote: Anyone idea's about autonesting?
All i can think about is i have machine parts waiting to be painted and they are outside while it is raining since last night. Not good.
Thank you.
Regards,
Tom.
The following user(s) said Thank You: Grotius
Please Log in or Create an account to join the conversation.
Time to create page: 3.004 seconds