Beispiel #1
0
def loadMeshes(filename):
	ext = filename[filename.rfind('.'):].lower()
	if ext == '.stl':
		return stl.loadScene(filename)
	if ext == '.obj':
		return obj.loadScene(filename)
	if ext == '.dae':
		return dae.loadScene(filename)
	if ext == '.amf':
		return amf.loadScene(filename)
	print 'Error: Unknown model extension: %s' % (ext)
	return []
Beispiel #2
0
def loadMeshes(filename):
    ext = os.path.splitext(filename)[1].lower()
    if ext == '.stl':
        return stl.loadScene(filename)
    if ext == '.obj':
        return obj.loadScene(filename)
    if ext == '.dae':
        return dae.loadScene(filename)
    if ext == '.amf':
        return amf.loadScene(filename)
    print 'Error: Unknown model extension: %s' % (ext)
    return []
Beispiel #3
0
def loadMeshes(filename):
	ext = os.path.splitext(filename)[1].lower()
	if ext == '.stl':
		return stl.loadScene(filename)
	if ext == '.obj':
		return obj.loadScene(filename)
	if ext == '.dae':
		return dae.loadScene(filename)
	if ext == '.amf':
		return amf.loadScene(filename)
	print 'Error: Unknown model extension: %s' % (ext)
	return []
Beispiel #4
0
def loadMeshes(filename):
    ext = filename[filename.rfind('.'):].lower()
    if ext == '.stl':
        return stl.loadScene(filename)
    if ext == '.obj':
        return obj.loadScene(filename)
    if ext == '.dae':
        return dae.loadScene(filename)
    if ext == '.amf':
        return amf.loadScene(filename)
    print 'Error: Unknown model extension: %s' % (ext)
    return []
Beispiel #5
0
def loadMeshes(filename):
    """
	loadMeshes loads 1 or more printableObjects from a file.
	STL files are a single printableObject with a single mesh, these are most common.
	OBJ files usually contain a single mesh, but they can contain multiple meshes
	AMF can contain whole scenes of objects with each object having multiple meshes.
	DAE files are a mess, but they can contain scenes of objects as well as grouped meshes
	"""
    ext = os.path.splitext(filename)[1].lower()
    if ext == '.stl':
        return stl.loadScene(filename)
    if ext == '.obj':
        return obj.loadScene(filename)
    if ext == '.dae':
        return dae.loadScene(filename)
    if ext == '.amf':
        return amf.loadScene(filename)
    print 'Error: Unknown model extension: %s' % (ext)
    return []
Beispiel #6
0
def loadMeshes(filename):
	"""
	loadMeshes loads 1 or more printableObjects from a file.
	STL files are a single printableObject with a single mesh, these are most common.
	OBJ files usually contain a single mesh, but they can contain multiple meshes
	AMF can contain whole scenes of objects with each object having multiple meshes.
	DAE files are a mess, but they can contain scenes of objects as well as grouped meshes
	"""
	ext = os.path.splitext(filename)[1].lower()
	if ext == '.stl':
		return stl.loadScene(filename)
	if ext == '.obj':
		return obj.loadScene(filename)
	if ext == '.dae':
		return dae.loadScene(filename)
	if ext == '.amf':
		return amf.loadScene(filename)
	print 'Error: Unknown model extension: %s' % (ext)
	return []