# * library https://github.com/pmav99/interpolation * # * Copyright (c) 2013 by Panagiotis Mavrogiorgos * # * * # *************************************************************************** import FreeCAD import FreeCADGui import Path import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtils as PathUtils from PySide import QtCore, QtGui # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') """Z Depth Correction Dressup. This dressup takes a probe file as input and does bilinear interpolation of the Zdepths to correct for a surface which is not parallel to the milling table/bed. The probe file should conform to the format specified by the linuxcnc G38 probe logging: 9-number coordinate consisting of XYZABCUVW http://linuxcnc.org/docs/html/gcode/g-code.html#gcode:g38 """ LOG_MODULE = PathLog.thisModule() if False: PathLog.setLevel(PathLog.Level.DEBUG, LOG_MODULE) PathLog.setLevel(PathLog.Level.DEBUG, LOG_MODULE) else: PathLog.setLevel(PathLog.Level.NOTICE, LOG_MODULE) # Qt translation handling def translate(context, text, disambig=None):
# * USA * # * * # *************************************************************************** from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import Part import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathPocketBase as PathPocketBase import PathScripts.PathUtils as PathUtils # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader PathGeom = LazyLoader("PathScripts.PathGeom", globals(), "PathScripts.PathGeom") __title__ = "Path 3D Pocket Operation" __author__ = "Yorik van Havre <*****@*****.**>" __url__ = "https://www.freecadweb.org" __doc__ = "Class and implementation of the 3D Pocket operation." __created__ = "2014" if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate
# * GNU Library General Public License for more details. * # * * # * You should have received a copy of the GNU Library General Public * # * License along with this program; if not, write to the Free Software * # * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** import FreeCAD import FreeCADGui import PathScripts.PathLog as PathLog # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Draft = LazyLoader('Draft', globals(), 'Draft') from PySide import QtCore, QtGui from pivy import coin __title__ = "Path GetPoint UI" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Helper class to use FreeCADGUi.Snapper to let the user enter arbitrary points while the task panel is active." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) #PathLog.track(PathLog.thisModule()) class TaskPanel: '''Use an instance of this class in another TaskPanel to invoke the snapper.
from PySide import QtCore from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import PathScripts.PathLog as PathLog import PathScripts.PathPreferences as PathPreferences import PathScripts.PathSetupSheet as PathSetupSheet import PathScripts.PathStock as PathStock import PathScripts.PathToolController as PathToolController import PathScripts.PathUtil as PathUtil import json import time # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Draft = LazyLoader("Draft", globals(), "Draft") if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate class JobTemplate: """Attribute and sub element strings for template export/import.""" Description = "Desc" GeometryTolerance = "Tolerance"
# * License along with this program; if not, write to the Free Software * # * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** from __future__ import print_function import FreeCAD import Path from PySide import QtCore import math import PathScripts.PathUtils as PathUtils # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader D = LazyLoader('DraftVecUtils', globals(), 'DraftVecUtils') __doc__ = """Dragknife Dressup object and FreeCAD command""" if FreeCAD.GuiUp: import FreeCADGui # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig) movecommands = ['G1', 'G01', 'G2', 'G02', 'G3', 'G03'] rapidcommands = ['G0', 'G00'] arccommands = ['G2', 'G3', 'G02', 'G03']
import FreeCAD import Path import PathScripts.PathDressup as PathDressup import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtil as PathUtil import PathSimulator import math import os from FreeCAD import Vector, Base # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Mesh = LazyLoader('Mesh', globals(), 'Mesh') Part = LazyLoader('Part', globals(), 'Part') if FreeCAD.GuiUp: import FreeCADGui from PySide import QtGui, QtCore _filePath = os.path.dirname(os.path.abspath(__file__)) class CAMSimTaskUi: def __init__(self, parent): # this will create a Qt widget from our ui file self.form = FreeCADGui.PySideUic.loadUi( ":/panels/TaskPathSimulator.ui") self.parent = parent
# * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** import FreeCAD import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathPocketBase as PathPocketBase from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') math = LazyLoader('math', globals(), 'math') PathUtils = LazyLoader('PathScripts.PathUtils', globals(), 'PathScripts.PathUtils') FeatureExtensions = LazyLoader('PathScripts.PathFeatureExtensions', globals(), 'PathScripts.PathFeatureExtensions') __title__ = "Path Pocket Shape Operation" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Class and implementation of shape based Pocket operation." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # PathLog.trackModule(PathLog.thisModule())
# * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathPocketBase as PathPocketBase # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader("Part", globals(), "Part") TechDraw = LazyLoader("TechDraw", globals(), "TechDraw") math = LazyLoader("math", globals(), "math") PathUtils = LazyLoader("PathScripts.PathUtils", globals(), "PathScripts.PathUtils") FeatureExtensions = LazyLoader("PathScripts.PathFeatureExtensions", globals(), "PathScripts.PathFeatureExtensions") __title__ = "Path Pocket Shape Operation" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Class and implementation of shape based Pocket operation." if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule())
import PathGui as PGui # ensure Path/Gui/Resources are loaded import PathScripts.PathDressup as PathDressup import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtil as PathUtil import PathScripts.PathJob as PathJob import PathSimulator import math import os from FreeCAD import Vector, Base # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Mesh = LazyLoader("Mesh", globals(), "Mesh") Part = LazyLoader("Part", globals(), "Part") if FreeCAD.GuiUp: import FreeCADGui from PySide import QtGui, QtCore _filePath = os.path.dirname(os.path.abspath(__file__)) class CAMSimTaskUi: def __init__(self, parent): # this will create a Qt widget from our ui file self.form = FreeCADGui.PySideUic.loadUi(":/panels/TaskPathSimulator.ui") self.parent = parent
# * License along with this program; if not, write to the Free Software * # * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** import Path import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathOpTools as PathOpTools import copy # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader DraftGeomUtils = LazyLoader('DraftGeomUtils', globals(), 'DraftGeomUtils') from PySide import QtCore __doc__ = "Base class for all ops in the engrave family." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) #PathLog.trackModule(PathLog.thisModule()) # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig)
# * * # *************************************************************************** from __future__ import print_function import FreeCAD import Path from PySide import QtCore import math import PathScripts.PathUtils as PathUtils import PathScripts.PathGui as PathGui from PySide.QtCore import QT_TRANSLATE_NOOP # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader D = LazyLoader("DraftVecUtils", globals(), "DraftVecUtils") __doc__ = """Dragknife Dressup object and FreeCAD command""" if FreeCAD.GuiUp: import FreeCADGui translate = FreeCAD.Qt.translate movecommands = ["G1", "G01", "G2", "G02", "G3", "G03"] rapidcommands = ["G0", "G00"] arccommands = ["G2", "G3", "G02", "G03"] currLocation = {}
import FreeCAD from FreeCAD import Vector from PathScripts import PathLog from PySide import QtCore from PySide import QtGui import Path import PathScripts.PathGeom as PathGeom import PathScripts.PathJob as PathJob import math from numpy import linspace # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader DraftGeomUtils = LazyLoader("DraftGeomUtils", globals(), "DraftGeomUtils") Part = LazyLoader("Part", globals(), "Part") TechDraw = LazyLoader("TechDraw", globals(), "TechDraw") translate = FreeCAD.Qt.translate if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) UserInput = None def waiting_effects(function):
diag.setWindowFlags(PyQt4.QtCore.Qt.WindowStaysOnTopHint) # PyQt4 # this function sets the window before except Exception: diag.setWindowFlags(PySide.QtCore.Qt.WindowStaysOnTopHint)# PySide # this function sets the window before # diag.setWindowModality(QtCore.Qt.ApplicationModal) # function has been disabled to promote "WindowStaysOnTopHint" diag.exec_() self.doubleSpinBox.setProperty("value", 10.0) # PyQt4 self.doubleSpinBox.setValue(10.0) # PySide self.doubleSpinBox.setToolTip(_translate("MainWindow", "Coordinate placement Axis Y", None)) # PyQt4 self.doubleSpinBox.setToolTip(_fromUtf8("Coordinate placement Axis Y")) # PySide self.doubleSpinBox.setToolTip(u"Coordinate placement Axis Y.")# PySide import pivy from pivy import coin App.newDocument() # Open a document and a view view = Gui.ActiveDocument.ActiveView FCSceneGraph = view.getSceneGraph() # returns a pivy Python object that holds a SoSeparator, the main "container" of the Coin scenegraph FCSceneGraph.addChild(coin.SoCube()) # add a box to scene from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') P = LazyLoader('Part', globals(), 'Part') utils = LazyLoader('PathScripts', globals(), 'PathScripts.PathUtils')
# * License along with this program; if not, write to the Free Software * # * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** import FreeCAD import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader ArchPanel = LazyLoader('ArchPanel', globals(), 'ArchPanel') Draft = LazyLoader('Draft', globals(), 'Draft') Part = LazyLoader('Part', globals(), 'Part') DraftGeomUtils = LazyLoader('DraftGeomUtils', globals(), 'DraftGeomUtils') __title__ = "Path Circular Holes Base Operation" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Base class an implementation for operations on circular holes." # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig)
import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils import Path import FreeCAD import FreeCADGui from FreeCAD import Console import time import json import math import area from pivy import coin # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') __doc__ = "Class and implementation of the Adaptive path operation." def convertTo2d(pathArray): output = [] for path in pathArray: pth2 = [] for edge in path: for pt in edge: pth2.append([pt[0], pt[1]]) output.append(pth2) return output
import FreeCAD import Path # import PathScripts import PathScripts.PathJob as PathJob import PathScripts.PathGeom as PathGeom import math import numpy from FreeCAD import Vector from PathScripts import PathLog from PySide import QtCore from PySide import QtGui # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader DraftGeomUtils = LazyLoader('DraftGeomUtils', globals(), 'DraftGeomUtils') Part = LazyLoader('Part', globals(), 'Part') TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # PathLog.trackModule(PathLog.thisModule()) def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig) UserInput = None def waiting_effects(function):
import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils import PathScripts.PathLog as PathLog import PathScripts.PathGeom as PathGeom import Path import FreeCAD import time import json import math import area from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') # TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') FeatureExtensions = LazyLoader('PathScripts.PathFeatureExtensions', globals(), 'PathScripts.PathFeatureExtensions') DraftGeomUtils = LazyLoader('DraftGeomUtils', globals(), 'DraftGeomUtils') if FreeCAD.GuiUp: from pivy import coin import FreeCADGui __doc__ = "Class and implementation of the Adaptive path operation." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # PathLog.trackModule(PathLog.thisModule())
# * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import Path import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Draft = LazyLoader("Draft", globals(), "Draft") Part = LazyLoader("Part", globals(), "Part") PathGeom = LazyLoader("PathScripts.PathGeom", globals(), "PathScripts.PathGeom") __title__ = "Base class for PathArea based operations." __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Base class and properties for Path.Area based operations." __contributors__ = "russ4262 (Russell Johnson)" if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule())
import time import json import math import area from PySide.QtCore import QT_TRANSLATE_NOOP if FreeCAD.GuiUp: from pivy import coin import FreeCADGui __doc__ = "Class and implementation of the Adaptive path operation." # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader("Part", globals(), "Part") # TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') FeatureExtensions = LazyLoader( "PathScripts.PathFeatureExtensions", globals(), "PathScripts.PathFeatureExtensions" ) DraftGeomUtils = LazyLoader("DraftGeomUtils", globals(), "DraftGeomUtils") if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate
import FreeCAD import PathScripts.PathIconViewProvider as PathIconViewProvider import PathScripts.PathLog as PathLog import PathScripts.PathPreferences as PathPreferences import PathScripts.PathSetupSheet as PathSetupSheet import PathScripts.PathStock as PathStock import PathScripts.PathToolController as PathToolController import PathScripts.PathUtil as PathUtil import json import time from PathScripts.PathPostProcessor import PostProcessor from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader ArchPanel = LazyLoader('ArchPanel', globals(), 'ArchPanel') Draft = LazyLoader('Draft', globals(), 'Draft') PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig) class JobTemplate: # pylint: disable=no-init '''Attribute and sub element strings for template export/import.''' Description = 'Desc'
# * USA * # * * # *************************************************************************** import FreeCAD import Path import PathScripts.PathEngraveBase as PathEngraveBase import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader ArchPanel = LazyLoader('ArchPanel', globals(), 'ArchPanel') Part = LazyLoader('Part', globals(), 'Part') __doc__ = "Class and implementation of Path Engrave operation" PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) #PathLog.trackModule(PathLog.thisModule()) # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig) class ObjectEngrave(PathEngraveBase.ObjectOp):
# * * # *************************************************************************** from PathScripts.PathDressupTagPreferences import HoldingTagPreferences from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import PathScripts.PathDressup as PathDressup import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtils as PathUtils import math # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader DraftGeomUtils = LazyLoader("DraftGeomUtils", globals(), "DraftGeomUtils") Part = LazyLoader("Part", globals(), "Part") if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate MaxInt = 99999999999999 class TagSolid: def __init__(self, proxy, z, R):
# * You should have received a copy of the GNU Library General Public * # * License along with this program; if not, write to the Free Software * # * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** import FreeCAD import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import Part import math # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader PathUtils = LazyLoader('PathScripts.PathUtils', globals(), 'PathScripts.PathUtils') from PySide import QtCore __title__ = "Path Features Extensions" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Class and implementation of face extensions features." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # PathLog.trackModule(PathLog.thisModule()) # Qt translation handling def translate(context, text, disambig=None):
from __future__ import print_function import FreeCAD import math import Path import PathScripts.PathDressup as PathDressup import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtil as PathUtil import PathScripts.PathUtils as PathUtils from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader DraftGeomUtils = LazyLoader('DraftGeomUtils', globals(), 'DraftGeomUtils') Part = LazyLoader('Part', globals(), 'Part') LOG_MODULE = PathLog.thisModule() PathLog.setLevel(PathLog.Level.NOTICE, LOG_MODULE) #PathLog.trackModule(LOG_MODULE) # Qt translation handling def translate(context, text, disambig=None): return QtCore.QCoreApplication.translate(context, text, disambig) movecommands = ['G0', 'G00', 'G1', 'G01', 'G2', 'G02', 'G3', 'G03']
# * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import Part import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import math # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader PathUtils = LazyLoader("PathScripts.PathUtils", globals(), "PathScripts.PathUtils") __title__ = "Path Features Extensions" __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Class and implementation of face extensions features." if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate
# * * # *************************************************************************** import FreeCAD import Path import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils import PathScripts.PathGeom as PathGeom import math from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Draft = LazyLoader('Draft', globals(), 'Draft') Part = LazyLoader('Part', globals(), 'Part') if FreeCAD.GuiUp: import FreeCADGui __title__ = "Base class for PathArea based operations." __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Base class and properties for Path.Area based operations." LOGLEVEL = PathLog.Level.INFO PathLog.setLevel(LOGLEVEL, PathLog.thisModule()) if LOGLEVEL is PathLog.Level.DEBUG: PathLog.trackModule()
# * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * # * USA * # * * # *************************************************************************** from PySide.QtCore import QT_TRANSLATE_NOOP import FreeCAD import Path import PathScripts.PathLog as PathLog import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Draft = LazyLoader("Draft", globals(), "Draft") Part = LazyLoader("Part", globals(), "Part") __title__ = "Base class for PathArea based operations." __author__ = "sliptonic (Brad Collette)" __url__ = "https://www.freecadweb.org" __doc__ = "Base class and properties for Path.Area based operations." __contributors__ = "russ4262 (Russell Johnson)" if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate
# *************************************************************************** import FreeCAD import FreeCADGui import Path import PathScripts.PathGeom as PathGeom import PathScripts.PathLog as PathLog import PathScripts.PathUtils as PathUtils from PySide import QtGui from PySide.QtCore import QT_TRANSLATE_NOOP from PathScripts.PathGeom import CmdMoveArc, CmdMoveStraight # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader("Part", globals(), "Part") """Z Depth Correction Dressup. This dressup takes a probe file as input and does bilinear interpolation of the Zdepths to correct for a surface which is not parallel to the milling table/bed. The probe file should conform to the format specified by the linuxcnc G38 probe logging: 9-number coordinate consisting of XYZABCUVW http://linuxcnc.org/docs/html/gcode/g-code.html#gcode:g38 """ LOGLEVEL = False LOG_MODULE = PathLog.thisModule() if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) else: PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) translate = FreeCAD.Qt.translate
import PathScripts.PathOp as PathOp import PathScripts.PathUtils as PathUtils import PathScripts.PathLog as PathLog import PathScripts.PathGeom as PathGeom import Path import FreeCAD import time import json import math import area from PySide import QtCore # lazily loaded modules from lazy_loader.lazy_loader import LazyLoader Part = LazyLoader('Part', globals(), 'Part') # TechDraw = LazyLoader('TechDraw', globals(), 'TechDraw') FeatureExtensions = LazyLoader('PathScripts.PathFeatureExtensions', globals(), 'PathScripts.PathFeatureExtensions') if FreeCAD.GuiUp: from pivy import coin import FreeCADGui __doc__ = "Class and implementation of the Adaptive path operation." PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # PathLog.trackModule(PathLog.thisModule())