Menu

SourceCode Merge Request #20: Two bugfixes: one in ShapeOffset and one in LWPOLYLINE loading (merged)

Merging...

Merged

Something went wrong. Please, merge manually

Checking if merge is possible...

Something went wrong. Please, merge manually

Andrey Zabolotnyi wants to merge 3 commits from /u/andyz/dxf2gcode/ to develop, 2020-02-04

This merge provides fixes for two bugs:
1. On some geometries creating a ShapeOffset (e.g. with G41 or G42) would fail. This happens due to Arc.dif_ang returning 2*pi (full circle) instead of 0, which is not what ShapeOffset expects.
2. Import of LWPOLYLINE shapes with bulges was wrong. The bulge was attributed to the wrong segment, and the import result was looking ugly.

Commit Date  
[3737ba] by Andrey Zabolotnyi Andrey Zabolotnyi

Fixed bug in LWPOLYLINE shape loading. Bulges were wrongly attributed to the segment that was preceeding the really "bulged" segment.

2020-02-02 21:55:18 Tree
[b02bb5] by Andrey Zabolotnyi Andrey Zabolotnyi

Fixed a bug in ShapeOffset class that would refuse in some case to create a offset shape.
The bug was in the fact, that Arc.diff_ang will always return 2*pi instead of 0, and
the logic of ShapeOffset supposes 0 is returned for zero angle.

2020-02-02 20:01:44 Tree
[34670f] by Andrey Zabolotnyi Andrey Zabolotnyi

More conversions of __str__ to __repr__ as it allows easier debugging.
Overriding __repr__ for class Geos to print the list not as a list (in one line), but each geometric object on a separate line (easier to read).

2020-02-02 19:55:24 Tree

Discussion

  • chrisko

    chrisko - 2020-02-04

    Hi Andrey,
    do i need to merge this one too, or have those changes been implemented in the other one alraedy. However this one shows that there are conflicts ...
    regards
    Christian

     
  • Andrey Zabolotnyi

    Yes, this is a totally different fix.
    See dxf/lwpoly-bulge.dxf test I've added in this patch.
    Try to load it without this patch, and with in, you will see the big difference.
    I've solved the conflicts, this can be safely merged.

     
  • chrisko

    chrisko - 2020-02-04
    • Status: open --> merged
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.