Fixed issue #923. Valentina produces wrong seam allowance for rollback case.

--HG--
branch : release
This commit is contained in:
Roman Telezhynskyi 2019-01-07 18:20:36 +02:00
parent e1dc566265
commit 38d8342b57
7 changed files with 5585 additions and 27 deletions

View file

@ -6,6 +6,7 @@
- [#913] Unable to save changes for piece path if it doesn't contain a point.
- [#914] Filtering custom seam allowance paths prevent including more than one.
- [#915] Valentina produces wrong seam allowance for acute angle.
- [#923] Valentina produces wrong seam allowance for rollback case.
# Version 0.6.1 October 23, 2018
- [#885] Regression. Broken support for multi size measurements.

View file

@ -0,0 +1,359 @@
<?xml version="1.0" encoding="UTF-8"?>
<pattern>
<!--Pattern created with Valentina v0.6.2.0 (https://valentinaproject.bitbucket.io/).-->
<version>0.7.12</version>
<unit>cm</unit>
<description/>
<notes/>
<patternName>Блуза</patternName>
<patternNumber>№14</patternNumber>
<company/>
<patternLabel dateFormat="MM-dd-yyyy" timeFormat="hh:mm:ss">
<line alignment="4" bold="true" italic="false" sfIncrement="4" text="%author%"/>
<line alignment="4" bold="false" italic="false" sfIncrement="2" text="%patternName%"/>
<line alignment="4" bold="false" italic="false" sfIncrement="0" text="Размер 28"/>
<line alignment="4" bold="false" italic="false" sfIncrement="0" text="Рост 110"/>
<line alignment="4" bold="false" italic="false" sfIncrement="0" text="%patternNumber%"/>
</patternLabel>
<measurements>Issue_#923.vit</measurements>
<increments>
<increment description="Прибавка на уработку." formula="0.3" name="#Пур"/>
<increment description="" formula="1.6" name="#М"/>
<increment description="Плечевая вытачка" formula="1.2" name="#Пв"/>
<increment description="Припуск на посадку." formula="0.3" name="#Ппос"/>
<increment description="Баланс платья. Он изменяется по размерам на 0.2" formula="4.3" name="#б"/>
<increment description="" formula="0.4" name="#Пур_1"/>
<increment description="" formula="0.7" name="#Пур_2"/>
<increment description="" formula="0.5" name="#Пур_3"/>
<increment description="Раствор вытачки" formula="3" name="#Рв"/>
</increments>
<previewCalculations>
<increment description="Прибавка на свободное облегание по груди." formula="8.5" name="#Пг_1"/>
<increment description="Ширина платья по линии груди. Шиг равна измерению полуобхвата груди третьему СгІІІ плюс прибавка на сободное облегание по груди Пг" formula="@СгІІІ+#Пг_1" name="#Шиг_1"/>
<increment description="Ширина спинки Шсп равна измерению ширины спины Шс плюс 1.4" formula="@Шс+1.4" name="#Шсп_1"/>
<increment description="Ширина полы на уровне груди Шгпол равна измерению ширины груди Шг плюс 1.3" formula="@Шг+1.3" name="#Шгпол_1"/>
<increment description="Ширина проймы Шпр равна ширине платья по линии грди Шиг минус ширина спинки Шсп и ширина полы на уровне груди" formula="#Шиг_1-(#Шсп_1+#Шгпол_1)" name="#Шпр_1"/>
</previewCalculations>
<draw name="Спинка">
<calculation>
<point id="1" mx="0.132292" my="0.264583" name="А" type="single" x="-21.556" y="-0.234005"/>
<point angle="270" basePoint="1" id="2" length="@Дтс+#Пур" lineColor="blue" mx="0.132292" my="0.264583" name="Т" type="endLine" typeLine="hair"/>
<point firstPoint="2" id="3" length="#Пур" lineColor="blue" mx="0.309469" my="-0.732036" name="оз" secondPoint="1" type="alongLine" typeLine="none"/>
<point angle="0" basePoint="1" id="4" length="@Сш/3+1.3" lineColor="black" mx="0.170457" my="0.0928427" name="А1" type="endLine" typeLine="hair"/>
<point angle="90" basePoint="4" id="5" length="(0.15*@Сш)-0.4" lineColor="black" mx="-0.602755" my="-1.78694" name="А2" type="endLine" typeLine="hair"/>
<point firstPoint="5" id="6" length="1.5" lineColor="black" mx="-1.13677" my="-1.77626" name="А3" secondPoint="4" thirdPoint="1" type="bisector" typeLine="hair"/>
<spline color="blue" id="7" penStyle="hair" type="pathInteractive">
<pathPoint angle1="33.2366" angle2="213.237" length1="0" length2="0.217465" pSpline="5"/>
<pathPoint angle1="26.7192" angle2="206.719" length1="0.807377" length2="1.84187" pSpline="6"/>
<pathPoint angle1="180" angle2="0" length1="0" length2="0" pSpline="1"/>
</spline>
<point angle="0" basePoint="1" id="8" length="#Шсп_1" lineColor="black" mx="0.132292" my="0.264583" name="а" type="endLine" typeLine="hair"/>
<point c1Center="5" c1Radius="@Шп+#М+#Ппос" c2Center="3" c2Radius="@Впк" crossPoint="2" id="9" mx="0.132292" my="0.264583" name="П" type="pointOfIntersectionCircles"/>
<line firstPoint="5" id="10" lineColor="blue" secondPoint="9" typeLine="hair"/>
<point firstPoint="8" id="11" mx="0.132292" my="0.264583" name="П1" secondPoint="9" type="pointOfIntersection"/>
<line firstPoint="9" id="12" lineColor="black" secondPoint="11" typeLine="dashLine"/>
<point angle="270" basePoint="11" id="13" length="0.4*@СгІІІ+2.2" lineColor="black" mx="0.132292" my="0.264583" name="Г1" type="endLine" typeLine="hair"/>
<point firstPoint="2" id="14" mx="0.132292" my="0.208554" name="Г" secondPoint="13" type="pointOfIntersection"/>
<line firstPoint="13" id="15" lineColor="black" secondPoint="14" typeLine="hair"/>
<line firstPoint="8" id="16" lineColor="black" secondPoint="11" typeLine="hair"/>
<point firstPoint="13" id="17" length="6" lineColor="black" mx="0.132292" my="0.264583" name="П2" secondPoint="11" type="alongLine" typeLine="none"/>
<point angle="0" basePoint="13" id="18" length="#Шпр_1/2-1.4" lineColor="black" mx="0.132292" my="0.264583" name="Г2" type="endLine" typeLine="hair"/>
<point firstPoint="17" id="19" length="1.9" lineColor="black" mx="0.132292" my="0.264583" name="I" secondPoint="13" thirdPoint="18" type="bisector" typeLine="hair"/>
<spline color="blue" id="20" penStyle="hair" type="pathInteractive">
<pathPoint angle1="70.1645" angle2="250.164" length1="0" length2="3.11186" pSpline="9"/>
<pathPoint angle1="90" angle2="270" length1="2.15999" length2="1.47142" pSpline="17"/>
<pathPoint angle1="123.093" angle2="303.093" length1="1.05178" length2="1.37047" pSpline="19"/>
<pathPoint angle1="3.90346" angle2="183.903" length1="0.426519" length2="0" pSpline="18"/>
</spline>
<line firstPoint="1" id="48" lineColor="blue" secondPoint="14" typeLine="hair"/>
<line firstPoint="14" id="59" lineColor="black" secondPoint="18" typeLine="hair"/>
<point angle="270" basePoint="1" id="186" length="@Ди+#Пур_3" lineColor="black" mx="0.132292" my="0.264583" name="Н" type="endLine" typeLine="hair"/>
<point angle="0" basePoint="186" id="187" length="Line_Г1_Г+Line_Г1_Г2" lineColor="black" mx="0.132292" my="0.264583" name="Н1" type="endLine" typeLine="hair"/>
<line firstPoint="18" id="188" lineColor="black" secondPoint="187" typeLine="hair"/>
<point firstPoint="1" id="250" length="9" lineColor="black" mx="0.132292" my="0.264583" name="А4" secondPoint="14" type="alongLine" typeLine="none"/>
<point angle="0" basePoint="250" curve="20" id="360" lineColor="black" mx="0.132292" my="0.264583" name="А5" showLabel="true" type="curveIntersectAxis" typeLine="none"/>
<spline aScale="2.3" angle1="318.43" angle2="209.346" color="black" id="363" length1="1.00806" length2="1.763" penStyle="dotLine" point1="250" point4="360" type="simpleInteractive"/>
</calculation>
<modeling>
<point id="373" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="374" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="375" idObject="7" inUse="false" type="modelingPath"/>
<point id="376" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="377" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="378" idObject="20" inUse="false" type="modelingPath"/>
<point id="379" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="380" idObject="363" inUse="false" type="modelingSpline"/>
<point id="382" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="383" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="384" idObject="7" inUse="false" type="modelingPath"/>
<point id="385" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="386" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="387" idObject="20" inUse="false" type="modelingPath"/>
<point id="388" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="389" idObject="363" inUse="false" type="modelingSpline"/>
<point id="391" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="392" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="393" idObject="7" inUse="false" type="modelingPath"/>
<point id="394" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="395" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="396" idObject="20" inUse="false" type="modelingPath"/>
<point id="397" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="398" idObject="363" inUse="false" type="modelingSpline"/>
<point id="400" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="401" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="402" idObject="7" inUse="false" type="modelingPath"/>
<point id="403" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="404" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="405" idObject="20" inUse="false" type="modelingPath"/>
<point id="406" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="407" idObject="363" inUse="false" type="modelingSpline"/>
<point id="409" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="410" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="411" idObject="7" inUse="false" type="modelingPath"/>
<point id="412" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="413" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="414" idObject="20" inUse="false" type="modelingPath"/>
<point id="415" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="416" idObject="363" inUse="false" type="modelingSpline"/>
<point id="418" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="419" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="420" idObject="7" inUse="false" type="modelingPath"/>
<point id="421" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="422" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="423" idObject="20" inUse="false" type="modelingPath"/>
<point id="424" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="425" idObject="363" inUse="false" type="modelingSpline"/>
<point id="427" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="428" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="429" idObject="7" inUse="false" type="modelingPath"/>
<point id="430" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="431" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="432" idObject="20" inUse="false" type="modelingPath"/>
<point id="433" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="434" idObject="363" inUse="false" type="modelingSpline"/>
<point id="436" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="437" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="438" idObject="7" inUse="false" type="modelingPath"/>
<point id="439" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="440" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="441" idObject="20" inUse="false" type="modelingPath"/>
<point id="442" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="443" idObject="363" inUse="false" type="modelingSpline"/>
<point id="445" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="446" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="447" idObject="7" inUse="false" type="modelingPath"/>
<point id="448" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="449" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="450" idObject="20" inUse="false" type="modelingPath"/>
<point id="451" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="452" idObject="363" inUse="false" type="modelingSpline"/>
<point id="454" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="455" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="456" idObject="7" inUse="false" type="modelingPath"/>
<point id="457" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="458" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="459" idObject="20" inUse="false" type="modelingPath"/>
<point id="460" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="461" idObject="363" inUse="false" type="modelingSpline"/>
<point id="463" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="464" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="465" idObject="7" inUse="false" type="modelingPath"/>
<point id="466" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="467" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="468" idObject="20" inUse="false" type="modelingPath"/>
<point id="469" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="470" idObject="363" inUse="false" type="modelingSpline"/>
<point id="472" idObject="250" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<point id="473" idObject="1" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="474" idObject="7" inUse="false" type="modelingPath"/>
<point id="475" idObject="5" inUse="false" mx="-0.602755" my="-1.78694" showLabel="true" type="modeling"/>
<point id="476" idObject="9" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="477" idObject="20" inUse="false" type="modelingPath"/>
<point id="478" idObject="360" inUse="false" mx="0.132292" my="0.264583" showLabel="true" type="modeling"/>
<spline id="479" idObject="363" inUse="false" type="modelingSpline"/>
</modeling>
<details>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="381" inLayout="true" mx="0.851574" my="-55.8515" name="Test 1" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" before="1" idObject="373" type="NodePoint"/>
<node after="1" before="0" idObject="374" type="NodePoint"/>
<node idObject="375" reverse="1" type="NodeSplinePath"/>
<node idObject="376" type="NodePoint"/>
<node idObject="377" type="NodePoint"/>
<node idObject="378" reverse="0" type="NodeSplinePath"/>
<node idObject="379" type="NodePoint"/>
<node idObject="380" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="390" inLayout="true" mx="24.067" my="-56.4319" name="Test 2" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" angle="1" before="1" idObject="382" type="NodePoint"/>
<node after="1" before="0" idObject="383" type="NodePoint"/>
<node idObject="384" reverse="1" type="NodeSplinePath"/>
<node idObject="385" type="NodePoint"/>
<node idObject="386" type="NodePoint"/>
<node idObject="387" reverse="0" type="NodeSplinePath"/>
<node idObject="388" type="NodePoint"/>
<node idObject="389" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="399" inLayout="true" mx="46.5569" my="-56.577" name="Test 3" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" angle="2" before="1" idObject="391" type="NodePoint"/>
<node after="1" before="0" idObject="392" type="NodePoint"/>
<node idObject="393" reverse="1" type="NodeSplinePath"/>
<node idObject="394" type="NodePoint"/>
<node idObject="395" type="NodePoint"/>
<node idObject="396" reverse="0" type="NodeSplinePath"/>
<node idObject="397" type="NodePoint"/>
<node idObject="398" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="408" inLayout="true" mx="69.7722" my="-56.2868" name="Test 4" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" before="1" idObject="400" type="NodePoint"/>
<node after="1" before="0" idObject="401" type="NodePoint"/>
<node idObject="402" reverse="1" type="NodeSplinePath"/>
<node idObject="403" type="NodePoint"/>
<node idObject="404" type="NodePoint"/>
<node idObject="405" reverse="0" type="NodeSplinePath"/>
<node idObject="406" type="NodePoint"/>
<node idObject="407" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="417" inLayout="true" mx="90.6661" my="-55.8515" name="Test 5" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" angle="4" before="1" idObject="409" type="NodePoint"/>
<node after="1" before="0" idObject="410" type="NodePoint"/>
<node idObject="411" reverse="1" type="NodeSplinePath"/>
<node idObject="412" type="NodePoint"/>
<node idObject="413" type="NodePoint"/>
<node idObject="414" reverse="0" type="NodeSplinePath"/>
<node idObject="415" type="NodePoint"/>
<node idObject="416" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="426" inLayout="true" mx="111.85" my="-56.2868" name="Test 6" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="0" angle="5" before="1" idObject="418" type="NodePoint"/>
<node after="1" before="0" idObject="419" type="NodePoint"/>
<node idObject="420" reverse="1" type="NodeSplinePath"/>
<node idObject="421" type="NodePoint"/>
<node idObject="422" type="NodePoint"/>
<node idObject="423" reverse="0" type="NodeSplinePath"/>
<node idObject="424" type="NodePoint"/>
<node idObject="425" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="435" inLayout="true" mx="1.15535" my="-39.6503" name="Test 1.1" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" before="1" idObject="427" type="NodePoint"/>
<node after="1" before="0" idObject="428" type="NodePoint"/>
<node idObject="429" reverse="1" type="NodeSplinePath"/>
<node idObject="430" type="NodePoint"/>
<node idObject="431" type="NodePoint"/>
<node idObject="432" reverse="0" type="NodeSplinePath"/>
<node idObject="433" type="NodePoint"/>
<node idObject="434" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="444" inLayout="true" mx="24.4296" my="-39.4766" name="Test 2.2" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" angle="1" before="1" idObject="436" type="NodePoint"/>
<node after="1" before="0" idObject="437" type="NodePoint"/>
<node idObject="438" reverse="1" type="NodeSplinePath"/>
<node idObject="439" type="NodePoint"/>
<node idObject="440" type="NodePoint"/>
<node idObject="441" reverse="0" type="NodeSplinePath"/>
<node idObject="442" type="NodePoint"/>
<node idObject="443" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="453" inLayout="true" mx="46.1406" my="-39.824" name="Test 3.3" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" angle="2" before="1" idObject="445" type="NodePoint"/>
<node after="1" before="0" idObject="446" type="NodePoint"/>
<node idObject="447" reverse="1" type="NodeSplinePath"/>
<node idObject="448" type="NodePoint"/>
<node idObject="449" type="NodePoint"/>
<node idObject="450" reverse="0" type="NodeSplinePath"/>
<node idObject="451" type="NodePoint"/>
<node idObject="452" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="462" inLayout="true" mx="68.8937" my="-39.4766" name="Test 4.4" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" angle="3" before="1" idObject="454" type="NodePoint"/>
<node after="1" before="0" idObject="455" type="NodePoint"/>
<node idObject="456" reverse="1" type="NodeSplinePath"/>
<node idObject="457" type="NodePoint"/>
<node idObject="458" type="NodePoint"/>
<node idObject="459" reverse="0" type="NodeSplinePath"/>
<node idObject="460" type="NodePoint"/>
<node idObject="461" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="471" inLayout="true" mx="91.1258" my="-38.7819" name="Test 5.5" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" angle="4" before="1" idObject="463" type="NodePoint"/>
<node after="1" before="0" idObject="464" type="NodePoint"/>
<node idObject="465" reverse="1" type="NodeSplinePath"/>
<node idObject="466" type="NodePoint"/>
<node idObject="467" type="NodePoint"/>
<node idObject="468" reverse="0" type="NodeSplinePath"/>
<node idObject="469" type="NodePoint"/>
<node idObject="470" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
<detail forbidFlipping="false" forceFlipping="false" hideMainPath="false" id="480" inLayout="true" mx="112.142" my="-38.4345" name="Test 6.6" seamAllowance="true" united="false" version="2" width="1">
<data annotation="" foldPosition="" fontSize="0" height="1" letter="" mx="0" my="0" onFold="false" orientation="" quantity="1" rotation="0" rotationWay="" tilt="" visible="false" width="1"/>
<patternInfo fontSize="0" height="1" mx="0" my="0" rotation="0" visible="false" width="1"/>
<grainline arrows="0" length="1" mx="0" my="0" rotation="90" visible="false"/>
<nodes>
<node after="4" angle="5" before="1" idObject="472" type="NodePoint"/>
<node after="1" before="0" idObject="473" type="NodePoint"/>
<node idObject="474" reverse="1" type="NodeSplinePath"/>
<node idObject="475" type="NodePoint"/>
<node idObject="476" type="NodePoint"/>
<node idObject="477" reverse="0" type="NodeSplinePath"/>
<node idObject="478" type="NodePoint"/>
<node idObject="479" reverse="1" type="NodeSpline"/>
</nodes>
</detail>
</details>
<groups/>
</draw>
</pattern>

View file

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<vit>
<!--Measurements created with Valentina v0.6.0.433a (https://valentinaproject.bitbucket.io/).-->
<version>0.4.0</version>
<read-only>false</read-only>
<notes/>
<unit>cm</unit>
<pm_system>998</pm_system>
<personal>
<customer/>
<birth-date>1800-01-01</birth-date>
<gender>unknown</gender>
<email/>
</personal>
<body-measurements>
<m full_name="Полуобхват шеи" name="@Сш" value="13.9"/>
<m full_name="Полуобхват груди третий" name="@СгІІІ" value="28"/>
<m full_name="Полуобхват талии" name="@Ст" value="25.8"/>
<m full_name="Полуобхват бедер" name="@Сб" value="30.5"/>
<m full_name="Длина спины до талии" name="@Дтс" value="27.2"/>
<m full_name="Высота плеча косая" name="@Впк" value="28.9"/>
<m full_name="Ширина спины" name="@Шс" value="12.6"/>
<m full_name="Ширина плечевого ската" name="@Шп" value="8.6"/>
<m full_name="Ширина груди" name="@Шг" value="11"/>
<m full_name="Обхват плеча" name="@Оп" value="17.6"/>
<m full_name="Расстояние от линии талии до пола сбоку" name="@Дсб" value="65.5"/>
<m full_name="Высота подъягодичной складки" name="@Впс" value="45.9"/>
<m full_name="Длина рукава" name="@Др" value="14.5"/>
<m description=" По шкале длин или по модели." full_name="Длина изделия (блуза)" name="@Ди" value="42"/>
<m name="@Шр" value="26"/>
<m name="@Дрлок" value="15"/>
<m name="@Вк" value="28.7"/>
<m full_name="Длина изделия (штаны)" name="@Диш" value="22"/>
</body-measurements>
</vit>

View file

@ -191,7 +191,8 @@ QVector<QPointF> RollbackSeamAllowance(QVector<QPointF> points, const QLineF &cu
QPointF crosPoint;
const QLineF::IntersectType type = cuttingEdge.intersect(segment, &crosPoint);
if (type != QLineF::NoIntersection
&& VGObject::IsPointOnLineSegment(crosPoint, segment.p1(), segment.p2()))
&& VGObject::IsPointOnLineSegment(crosPoint, segment.p1(), segment.p2())
&& IsOutsidePoint(cuttingEdge.p2(), cuttingEdge.p1(), crosPoint))
{
clipped.append(crosPoint);
for (int j=i-1; j>=0; --j)
@ -200,6 +201,7 @@ QVector<QPointF> RollbackSeamAllowance(QVector<QPointF> points, const QLineF &cu
}
points = VGObject::GetReversePoints(clipped);
*success = true;
break;
}
}
@ -220,8 +222,13 @@ QVector<QPointF> RollbackSeamAllowance(QVector<QPointF> points, const QLineF &cu
//---------------------------------------------------------------------------------------------------------------------
QVector<QPointF> AngleByLength(QVector<QPointF> points, QPointF p2, const QLineF &bigLine1, QPointF sp2,
const QLineF &bigLine2, const VSAPoint &p, qreal width)
const QLineF &bigLine2, const VSAPoint &p, qreal width, int *needRollback = nullptr)
{
if (needRollback != nullptr)
{
*needRollback = -1;
}
const QPointF sp1 = bigLine1.p1();
const QPointF sp3 = bigLine2.p2();
const qreal localWidth = p.MaxLocalSA(width);
@ -267,6 +274,10 @@ QVector<QPointF> AngleByLength(QVector<QPointF> points, QPointF p2, const QLineF
{
bool success = false;
points = RollbackSeamAllowance(points, bigLine2, &success);
if (needRollback != nullptr)
{
*needRollback = 0;
}
}
else
{
@ -281,7 +292,7 @@ QVector<QPointF> AngleByLength(QVector<QPointF> points, QPointF p2, const QLineF
QLineF loop1(sp2, sp1);
loop1.setLength(loop1.length()*0.1);
points.append(loop1.p2()); // Nedd for the main path rule
points.append(loop1.p2()); // Need for the main path rule
loop1.setAngle(loop1.angle() + 180);
loop1.setLength(localWidth);
@ -300,8 +311,13 @@ QVector<QPointF> AngleByLength(QVector<QPointF> points, QPointF p2, const QLineF
//---------------------------------------------------------------------------------------------------------------------
QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1, QPointF p2, QPointF p3,
const QLineF &bigLine1, QPointF sp2, const QLineF &bigLine2,
const VSAPoint &p, qreal width)
const VSAPoint &p, qreal width, int *needRollback = nullptr)
{
if (needRollback != nullptr)
{
*needRollback = -1;
}
const qreal localWidth = p.MaxLocalSA(width);
QVector<QPointF> pointsIntr = points;
@ -315,6 +331,7 @@ QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1,
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
bool rollbackFlag = false;
if (IsOutsidePoint(bigLine1.p1(), bigLine1.p2(), px))
{
if (QLineF(p2, px).length() > localWidth*maxL)
@ -327,6 +344,7 @@ QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1,
{// Because artificial loop can lead to wrong clipping we must rollback current seam allowance points
bool success = false;
pointsIntr = RollbackSeamAllowance(pointsIntr, edge2, &success);
rollbackFlag = true;
}
// Second point
@ -341,6 +359,11 @@ QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1,
if (IsOutsidePoint(bigLine2.p2(), bigLine2.p1(), px))
{
pointsIntr.append(px);
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 1;
}
}
else
{
@ -349,6 +372,11 @@ QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1,
allowance.setLength(allowance.length() + localWidth * 3.);
pointsIntr.append(allowance.p2());
pointsIntr.append(bigLine2.p2());
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 3;
}
}
return pointsIntr;
@ -357,8 +385,13 @@ QVector<QPointF> AngleByIntersection(const QVector<QPointF> &points, QPointF p1,
//---------------------------------------------------------------------------------------------------------------------
QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1, QPointF p2,
const QLineF &bigLine1, QPointF sp2, const QLineF &bigLine2,
const VSAPoint &p, qreal width)
const VSAPoint &p, qreal width, int *needRollback = nullptr)
{
if (needRollback != nullptr)
{
*needRollback = -1;
}
const qreal localWidth = p.MaxLocalSA(width);
QVector<QPointF> pointsIntr = points;
@ -371,6 +404,7 @@ QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
bool rollbackFlag = false;
if (IsOutsidePoint(bigLine1.p1(), bigLine1.p2(), px))
{
if (QLineF(p2, px).length() > localWidth*maxL)
@ -383,6 +417,7 @@ QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1
{// Because artificial loop can lead to wrong clipping we must rollback current seam allowance points
bool success = false;
pointsIntr = RollbackSeamAllowance(pointsIntr, bigLine2, &success);
rollbackFlag = true;
}
type = sEdge.intersect(bigLine2, &px);
@ -398,6 +433,11 @@ QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
pointsIntr.append(px);
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 1;
}
}
else
{
@ -405,6 +445,11 @@ QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1
allowance.setAngle(allowance.angle() + 90);
pointsIntr.append(allowance.p2());
pointsIntr.append(bigLine2.p1());
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 2;
}
}
return pointsIntr;
@ -413,8 +458,13 @@ QVector<QPointF> AngleByFirstSymmetry(const QVector<QPointF> &points, QPointF p1
//---------------------------------------------------------------------------------------------------------------------
QVector<QPointF> AngleBySecondSymmetry(const QVector<QPointF> &points, QPointF p2, QPointF p3,
const QLineF &bigLine1, QPointF sp2, const QLineF &bigLine2,
const VSAPoint &p, qreal width)
const VSAPoint &p, qreal width, int *needRollback = nullptr)
{
if (needRollback != nullptr)
{
*needRollback = -1;
}
const qreal localWidth = p.MaxLocalSA(width);
QVector<QPointF> pointsIntr = points;
@ -427,6 +477,7 @@ QVector<QPointF> AngleBySecondSymmetry(const QVector<QPointF> &points, QPointF p
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
bool rollbackFlag = false;
if (IsOutsidePoint(bigLine1.p1(), bigLine1.p2(), px))
{
if (QLineF(p2, px).length() > localWidth*maxL)
@ -439,6 +490,7 @@ QVector<QPointF> AngleBySecondSymmetry(const QVector<QPointF> &points, QPointF p
{// Because artificial loop can lead to wrong clipping we must rollback current seam allowance points
bool success = false;
pointsIntr = RollbackSeamAllowance(pointsIntr, bigLine2, &success);
rollbackFlag = true;
}
type = sEdge.intersect(bigLine2, &px);
@ -453,7 +505,16 @@ QVector<QPointF> AngleBySecondSymmetry(const QVector<QPointF> &points, QPointF p
{
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
pointsIntr.append(px);
if (not rollbackFlag)
{
pointsIntr.append(px);
}
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 0;
}
}
else
{
@ -463,6 +524,11 @@ QVector<QPointF> AngleBySecondSymmetry(const QVector<QPointF> &points, QPointF p
allowance.setLength(allowance.length() + localWidth * 3.);
pointsIntr.append(allowance.p2());
pointsIntr.append(bigLine2.p2());
if (needRollback != nullptr && rollbackFlag)
{
*needRollback = 3;
}
}
return pointsIntr;
@ -517,8 +583,13 @@ QVector<QPointF> AngleByFirstRightAngle(const QVector<QPointF> &points, QPointF
//---------------------------------------------------------------------------------------------------------------------
QVector<QPointF> AngleBySecondRightAngle(QVector<QPointF> points, QPointF p2, QPointF p3,
const QLineF &bigLine1, QPointF sp2, const QLineF &bigLine2,
const VSAPoint &p, qreal width)
const VSAPoint &p, qreal width, int *needRollback = nullptr)
{
if (needRollback != nullptr)
{
*needRollback = -1;
}
const qreal localWidth = p.MaxLocalSA(width);
QLineF edge(p2, p3);
@ -529,8 +600,6 @@ QVector<QPointF> AngleBySecondRightAngle(QVector<QPointF> points, QPointF p2, QP
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
if (IsOutsidePoint(bigLine1.p1(), bigLine1.p2(), px))
{
if (QLineF(p2, px).length() > localWidth*maxL)
@ -538,22 +607,39 @@ QVector<QPointF> AngleBySecondRightAngle(QVector<QPointF> points, QPointF p2, QP
return AngleByLength(points, p2, bigLine1, sp2, bigLine2, p, width);
}
points.append(px);
QLineF seam(px, p3);
seam.setAngle(seam.angle()+90);
seam.setLength(p.GetSAAfter(width));
points.append(seam.p2());
}
else
{
// Because artificial loop can lead to wrong clipping we must rollback current seam allowance points
bool success = false;
const int countBefore = points.size();
points = RollbackSeamAllowance(points, edge, &success);
if (success)
{
px = points.last();
}
}
QLineF seam(px, p3);
seam.setAngle(seam.angle()+90);
seam.setLength(p.GetSAAfter(width));
points.append(seam.p2());
if (countBefore > 0)
{
QLineF seam(px, p3);
seam.setAngle(seam.angle()+90);
seam.setLength(p.GetSAAfter(width));
points.append(seam.p2());
}
else
{
if (needRollback != nullptr)
{
*needRollback = 0;
}
}
}
return points;
}
@ -886,13 +972,14 @@ QVector<QPointF> VAbstractPiece::Equidistant(QVector<VSAPoint> points, qreal wid
points.append(points.at(0));// Should be always closed
}
int needRollback = -1; // no need for rollback
QVector<QPointF> ekvPoints;
for (qint32 i = 0; i < points.size(); ++i )
{
if ( i == 0)
{//first point
ekvPoints = EkvPoint(ekvPoints, points.at(points.size()-2), points.at(points.size()-1), points.at(1),
points.at(0), width);
points.at(0), width, &needRollback);
continue;
}
@ -900,7 +987,7 @@ QVector<QPointF> VAbstractPiece::Equidistant(QVector<VSAPoint> points, qreal wid
{//last point
if (not ekvPoints.isEmpty())
{
ekvPoints.append(ekvPoints.at(0));
ekvPoints.append(ekvPoints.first());
}
continue;
}
@ -908,6 +995,82 @@ QVector<QPointF> VAbstractPiece::Equidistant(QVector<VSAPoint> points, qreal wid
ekvPoints = EkvPoint(ekvPoints, points.at(i-1), points.at(i), points.at(i+1), points.at(i), width);
}
if (needRollback != -1)
{
auto Rollback = [&ekvPoints, needRollback](const QLineF &edge)
{
if (not ekvPoints.isEmpty())
{
ekvPoints.removeLast();
QVector<QPointF> head = ekvPoints.mid(0, needRollback);
ekvPoints.remove(0, needRollback);
bool success = false;
ekvPoints = RollbackSeamAllowance(ekvPoints, edge, &success);
ekvPoints = head + ekvPoints;
if (not ekvPoints.isEmpty())
{
ekvPoints.append(ekvPoints.first());
}
}
};
QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Wswitch-default")
// This check helps to find missed angle types in the switch
Q_STATIC_ASSERT_X(static_cast<int>(PieceNodeAngle::LAST_ONE_DO_NOT_USE) == 7, "Not all types were handled.");
switch (points.last().GetAngleType())
{
case PieceNodeAngle::LAST_ONE_DO_NOT_USE:
case PieceNodeAngle::ByFirstEdgeRightAngle:
Q_UNREACHABLE(); //-V501
break;
case PieceNodeAngle::ByLength:
case PieceNodeAngle::ByLengthCurve:
case PieceNodeAngle::ByFirstEdgeSymmetry:
case PieceNodeAngle::BySecondEdgeSymmetry:
Rollback(ParallelLine(points.at(0), points.at(1), width));
break;
case PieceNodeAngle::ByPointsIntersection:
Rollback(QLineF(points.last(), points.at(1)));
break;
case PieceNodeAngle::BySecondEdgeRightAngle:
if (not ekvPoints.isEmpty())
{
const QLineF edge(points.last(), points.at(1));
const QLineF bigLine1 = ParallelLine(points.at(points.size()-2), points.at(0), width);
QPointF px;
edge.intersect(bigLine1, &px);
ekvPoints.removeLast();
bool success = false;
ekvPoints = RollbackSeamAllowance(ekvPoints, edge, &success);
if (success)
{
px = ekvPoints.last();
}
QLineF seam(px, points.at(1));
seam.setAngle(seam.angle()+90);
seam.setLength(points.at(0).GetSAAfter(width));
ekvPoints.append(seam.p2());
if (not ekvPoints.isEmpty())
{
ekvPoints.append(ekvPoints.first());
}
}
break;
}
QT_WARNING_POP
}
const bool removeFirstAndLast = false;
ekvPoints = CheckLoops(CorrectEquidistantPoints(ekvPoints, removeFirstAndLast));//Result path can contain loops
ekvPoints = CheckLoops(CorrectEquidistantPoints(ekvPoints, removeFirstAndLast));//Result path can contain loops
@ -1099,7 +1262,7 @@ QVector<QPointF> VAbstractPiece::CheckLoops(const QVector<QPointF> &points)
* @return seam aloowance points.
*/
QVector<QPointF> VAbstractPiece::EkvPoint(QVector<QPointF> points, const VSAPoint &p1Line1, VSAPoint p2Line1,
const VSAPoint &p1Line2, VSAPoint p2Line2, qreal width)
const VSAPoint &p1Line2, VSAPoint p2Line2, qreal width, int *needRollback)
{
if (width < 0)
{ // width can't be < 0
@ -1164,8 +1327,8 @@ QVector<QPointF> VAbstractPiece::EkvPoint(QVector<QPointF> points, const VSAPoin
const qreal angle = AngleBetweenBisectors(b1, b2);
// Comparison bisector angles helps to find direction
if (angle < 90
|| VFuzzyComparePossibleNulls(angle, 90.0))// Go in a same direction
if (angle < 135
|| VFuzzyComparePossibleNulls(angle, 135.0))// Go in a same direction
{//Regular equdistant case
QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Wswitch-default")
@ -1179,22 +1342,23 @@ QT_WARNING_DISABLE_GCC("-Wswitch-default")
break;
case PieceNodeAngle::ByLength:
case PieceNodeAngle::ByLengthCurve:
return AngleByLength(points, p2Line1, bigLine1, crosPoint, bigLine2, p2Line1, width);
return AngleByLength(points, p2Line1, bigLine1, crosPoint, bigLine2, p2Line1, width,
needRollback);
case PieceNodeAngle::ByPointsIntersection:
return AngleByIntersection(points, p1Line1, p2Line1, p1Line2, bigLine1, crosPoint, bigLine2,
p2Line1, width);
p2Line1, width, needRollback);
case PieceNodeAngle::ByFirstEdgeSymmetry:
return AngleByFirstSymmetry(points, p1Line1, p2Line1, bigLine1, crosPoint, bigLine2,
p2Line1, width);
p2Line1, width, needRollback);
case PieceNodeAngle::BySecondEdgeSymmetry:
return AngleBySecondSymmetry(points, p2Line1, p1Line2, bigLine1, crosPoint, bigLine2,
p2Line1, width);
p2Line1, width, needRollback);
case PieceNodeAngle::ByFirstEdgeRightAngle:
return AngleByFirstRightAngle(points, p1Line1, p2Line1, bigLine1, crosPoint, bigLine2,
p2Line1, width);
case PieceNodeAngle::BySecondEdgeRightAngle:
return AngleBySecondRightAngle(points, p2Line1, p1Line2, bigLine1, crosPoint, bigLine2,
p2Line1, width);
p2Line1, width, needRollback);
}
QT_WARNING_POP
}

View file

@ -187,7 +187,8 @@ public:
static qreal SumTrapezoids(const QVector<QPointF> &points);
static QVector<QPointF> CheckLoops(const QVector<QPointF> &points);
static QVector<QPointF> EkvPoint(QVector<QPointF> points, const VSAPoint &p1Line1, VSAPoint p2Line1,
const VSAPoint &p1Line2, VSAPoint p2Line2, qreal width);
const VSAPoint &p1Line2, VSAPoint p2Line2, qreal width,
int *needRollback = nullptr);
static QLineF ParallelLine(const VSAPoint &p1, const VSAPoint &p2, qreal width);
template <class T>

File diff suppressed because it is too large Load diff

View file

@ -125,6 +125,42 @@ private:
QVector<VSAPoint> InputPointsIssue646() const;
QVector<QPointF> OutputPointsIssue646() const;
QVector<VSAPoint> InputPointsIssue923Test1();
QVector<QPointF> OutputPointsIssue923Test1();
QVector<VSAPoint> InputPointsIssue923Test2();
QVector<QPointF> OutputPointsIssue923Test2();
QVector<VSAPoint> InputPointsIssue923Test3();
QVector<QPointF> OutputPointsIssue923Test3();
QVector<VSAPoint> InputPointsIssue923Test4();
QVector<QPointF> OutputPointsIssue923Test4();
QVector<VSAPoint> InputPointsIssue923Test5();
QVector<QPointF> OutputPointsIssue923Test5();
QVector<VSAPoint> InputPointsIssue923Test6();
QVector<QPointF> OutputPointsIssue923Test6();
QVector<VSAPoint> InputPointsIssue923Test1_1();
QVector<QPointF> OutputPointsIssue923Test1_1();
QVector<VSAPoint> InputPointsIssue923Test2_2();
QVector<QPointF> OutputPointsIssue923Test2_2();
QVector<VSAPoint> InputPointsIssue923Test3_3();
QVector<QPointF> OutputPointsIssue923Test3_3();
QVector<VSAPoint> InputPointsIssue923Test4_4();
QVector<QPointF> OutputPointsIssue923Test4_4();
QVector<VSAPoint> InputPointsIssue923Test5_5();
QVector<QPointF> OutputPointsIssue923Test5_5();
QVector<VSAPoint> InputPointsIssue923Test6_6();
QVector<QPointF> OutputPointsIssue923Test6_6();
};
#endif // TST_VABSTRACTPIECE_H