HEX
Server: Apache
System: Linux opal14.opalstack.com 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
User: curbgloabal_opal (1234)
PHP: 8.1.29
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //usr/share/inkscape/extensions/cubicsuperpath.pyo
�
��Yc@sqdZddlZddlTd�Zd�Zd�Zd�Zd�Zd	�Zd
�Z	d�Z
d�ZdS(
s�
cubicsuperpath.py

Copyright (C) 2005 Aaron Spike, aaron@ekips.org

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.

i����N(t*cCs|d}x�|dD]�}|dd|dd|dd|dd}|dd|dd|dd|dd}|dd|dd|dd|dd}|dd|dd|dd|dd}||g||gg}qW|S(Nii((tmlisttprodtmta00ta01ta10ta11((s0/usr/share/inkscape/extensions/cubicsuperpath.pytmatprods
2222cCs/t|�t|�gt|�t|�ggS(N(tcostsin(tteta((s0/usr/share/inkscape/extensions/cubicsuperpath.pytrotmat"scCsl|dd|d|dd|d}|dd|d|dd|d}||d<||d<dS(Nii((tmattpttxty((s0/usr/share/inkscape/extensions/cubicsuperpath.pytapplymat$s**
cCs&t|d|d|d|d�S(Nii(tsqrt(R((s0/usr/share/inkscape/extensions/cubicsuperpath.pytnorm)sc
Cs�|}|\}}}}}}}	|td}||	g}
|dksa|dksa||
kr�|||g|
|
|
ggStt|�d|dgdd|ggt|�f�}t||�t||
�|
d|d|
d|dg}|d|d|d|d}
|dct|
�:<|dct|
�:<ttdd|
d��}
||kr�|
d9}
n|
d|dd|
|d|
d|dd|
|dg}|d|d|d|dg}|
d|d|
d|dg}t|dt|��}|ddkrE|d9}nt|dt|��}|ddkr||d9}n|r�||kr�|dt7}n|r�||kr�|dt8}ntt	||�dt�d}|||}dt
|d�d}g}x�td|dd�D]�}|||}|dt|�|t
|�|dt
|�|t|�g}|dt|�|dt
|�g}|dt|�|t
|�|dt
|�|t|�g}|j|||g�q(W|dd|dd<|dd|dd<tt|�|dgd|ggt|�f�}xA|D]9}t||d�t||d�t||d�qqW|S(Ng�f@iiii����ii(tpiRRRRtmaxtacosRtinttabsttantrangeR	R
tappend(tp1tparamstAtrxtryRtlongflagt	sweepflagtx2ty2tBR
tktdtOtOAtOBtstarttendt	NbSectorstdTetatvtptitangletv1Rtv2tpts((s0/usr/share/inkscape/extensions/cubicsuperpath.pyt	ArcToPath,s^$"<

%"
D$$

"F(D4
cCs�g}d}g}g}g}x�|D]�}|\}}|dkr�|ri||j|||g�n|d7}|jg�|}|}|}q%|dkr�||j|||g�|}|}q%|dkr||j|||d g�|d}|dd!}q%|d	kr7|}	|d
d!}
|dd!}|	d
}dd|	d
d
d|
d
}
d
d|
d
dd|d
}|d
}|	d}dd|	dd
d|
d}d
d|
ddd|d}|d}||j|||g|
|gg�||g}||g}q%|dkr�t||�}||d
d
<|dd}|dd
}||c|d 7<q%|dkr%||j|||g�|}|}q%q%W||j|||g�|S(Ni����tMitLtCii����itQig�?ig@RtZ(RR6(t
simplepathtcsptsubpathtsubpathstarttlasttlastctrltstcmdRtq0tq1tq2tx0tx1R#tx3ty0ty1R$ty3tarcp((s0/usr/share/inkscape/extensions/cubicsuperpath.pytCubicSuperPathdsd
 



 



""

""
'cCs�g}x�|D]�}|r
|jd|ddg�xZtdt|��D]@}|jd||dd||d||dg�qKWq
q
W|S(NR7iiR9i(RRtlen(R=taR>R1((s0/usr/share/inkscape/extensions/cubicsuperpath.pytunCubicSuperPath�s
EcCsttj|��S(N(RNR<t	parsePath(R'((s0/usr/share/inkscape/extensions/cubicsuperpath.pyRR�scCstjt|��S(N(R<t
formatPathRQ(R0((s0/usr/share/inkscape/extensions/cubicsuperpath.pyRS�s(t__doc__R<tmathRRRRR6RNRQRRRS(((s0/usr/share/inkscape/extensions/cubicsuperpath.pyt<module>s
						8	5