[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gzz-commits] libvob/vob/buoy buoymanager.py
From: |
Matti Katila |
Subject: |
[Gzz-commits] libvob/vob/buoy buoymanager.py |
Date: |
Fri, 23 May 2003 11:03:17 -0400 |
CVSROOT: /cvsroot/libvob
Module name: libvob
Changes by: Matti Katila <address@hidden> 03/05/23 11:03:17
Modified files:
vob/buoy : buoymanager.py
Log message:
shifting for buoys
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/libvob/libvob/vob/buoy/buoymanager.py.diff?tr1=1.22&tr2=1.23&r1=text&r2=text
Patches:
Index: libvob/vob/buoy/buoymanager.py
diff -u libvob/vob/buoy/buoymanager.py:1.22 libvob/vob/buoy/buoymanager.py:1.23
--- libvob/vob/buoy/buoymanager.py:1.22 Wed May 21 14:09:21 2003
+++ libvob/vob/buoy/buoymanager.py Fri May 23 11:03:16 2003
@@ -100,13 +100,23 @@
def link(self, *args):
self.links.append(args)
- def _linkReally(self, direction, anchorCS, otherNode, linkId, otherAnchor):
+ def _linkReally(self, direction, anchorCS, otherNode, linkId, otherAnchor,
shift=0):
"""Create the real buoy.
"""
if dbg: pa('link really')
+ ### Shift the anchorCS for some degrees
+ if shift > 0:
+ # evens 2,4,6 -> 1,2,3,4,..
+ # odds 1,3,5,7 -> -1,-2,-3,-4
+ if shift%2 == 1:
+ shift += 1
+ shift *= -1
+ shift *= 0.5
+ shiftedAnchorCS = self.vs.translateCS(anchorCS, 'Shift',0, shift*18)
+
### Buoy coordinate system
- buoy = self.vs.coords.buoyOnCircle2(self.buoyinto, anchorCS,
+ buoy = self.vs.coords.buoyOnCircle2(self.buoyinto, shiftedAnchorCS,
direction, 10)
self.vs.matcher.add(self.buoyinto, buoy, linkId)
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/02
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/16
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Tuomas J. Lukka, 2003/05/16
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/19
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/21
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/21
- [Gzz-commits] libvob/vob/buoy buoymanager.py,
Matti Katila <=
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/23
- [Gzz-commits] libvob/vob/buoy buoymanager.py, Matti Katila, 2003/05/26