mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-07 15:07:28 -06:00
More work on CuraEngineBackend (and backend in general)
This commit is contained in:
parent
f8dd19460b
commit
11ac8e85e8
4 changed files with 29 additions and 6 deletions
9
Commands/TransferMeshCommand.py
Normal file
9
Commands/TransferMeshCommand.py
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
from Cura.Backend.Command import Command
|
||||||
|
from Cura.plugins.CuraBackendEngine.Commands.TransferVertCommand import TransferVertCommand
|
||||||
|
|
||||||
|
class TransferMeshCommand(Command):
|
||||||
|
def __init__(self):
|
||||||
|
super(TransferMeshCommand,self).__init__()
|
||||||
|
|
||||||
|
def send(self, mesh_data):
|
||||||
|
vertices = mesh_data.getVerticesList()
|
12
Commands/TransferMeshesCommand.py
Normal file
12
Commands/TransferMeshesCommand.py
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
from Cura.Backend.Command import Command
|
||||||
|
from Cura.plugins.CuraBackendEngine.Commands.TransferMeshCommand import TransferMeshCommand
|
||||||
|
|
||||||
|
class TransferMeshesCommand(Command):
|
||||||
|
def __init__(self):
|
||||||
|
super(TransferMeshesCommand,self).__init__()
|
||||||
|
|
||||||
|
def send(self, meshes):
|
||||||
|
command = TransferMeshCommand(self._socket)
|
||||||
|
for mesh in meshes:
|
||||||
|
command.send(mesh)
|
||||||
|
|
8
Commands/TransferVertCommand.py
Normal file
8
Commands/TransferVertCommand.py
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
from Cura.Backend.Command import Command
|
||||||
|
|
||||||
|
class TransferVertCommand(Command):
|
||||||
|
def __init__(self):
|
||||||
|
super(TransferVertCommand,self).__init__()
|
||||||
|
|
||||||
|
def send(self):
|
||||||
|
self._socket.sendData(self._id, self._data)
|
|
@ -1,6 +0,0 @@
|
||||||
from Cura.Backend.Command import Command
|
|
||||||
|
|
||||||
class TransferMeshCommand(Command):
|
|
||||||
def __init__(self):
|
|
||||||
super(TransferMeshCommand,self).__init__()
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue