1syntax = "proto3"; 2 3package cura.proto; 4 5message ObjectList 6{ 7 repeated Object objects = 1; 8 repeated Setting settings = 2; // meshgroup settings (for one-at-a-time printing) 9} 10 11message Slice 12{ 13 repeated ObjectList object_lists = 1; // The meshgroups to be printed one after another 14 SettingList global_settings = 2; // The global settings used for the whole print job 15 repeated Extruder extruders = 3; // The settings sent to each extruder object 16 repeated SettingExtruder limit_to_extruder = 4; // From which stack the setting would inherit if not defined per object 17} 18 19message Extruder 20{ 21 int32 id = 1; 22 SettingList settings = 2; 23} 24 25message Object 26{ 27 int64 id = 1; 28 bytes vertices = 2; //An array of 3 floats. 29 bytes normals = 3; //An array of 3 floats. 30 bytes indices = 4; //An array of ints. 31 repeated Setting settings = 5; // Setting override per object, overruling the global settings. 32 string name = 6; //Mesh name 33} 34 35message Progress 36{ 37 float amount = 1; 38} 39 40message Layer { 41 int32 id = 1; 42 float height = 2; // Z position 43 float thickness = 3; // height of a single layer 44 45 repeated Polygon polygons = 4; // layer data 46} 47 48message Polygon { 49 enum Type { 50 NoneType = 0; 51 Inset0Type = 1; 52 InsetXType = 2; 53 SkinType = 3; 54 SupportType = 4; 55 SkirtType = 5; 56 InfillType = 6; 57 SupportInfillType = 7; 58 MoveCombingType = 8; 59 MoveRetractionType = 9; 60 SupportInterfaceType = 10; 61 PrimeTowerType = 11; 62 } 63 Type type = 1; // Type of move 64 bytes points = 2; // The points of the polygon, or two points if only a line segment (Currently only line segments are used) 65 float line_width = 3; // The width of the line being laid down 66 float line_thickness = 4; // The thickness of the line being laid down 67 float line_feedrate = 5; // The feedrate of the line being laid down 68} 69 70message LayerOptimized { 71 int32 id = 1; 72 float height = 2; // Z position 73 float thickness = 3; // height of a single layer 74 75 repeated PathSegment path_segment = 4; // layer data 76} 77 78 79message PathSegment { 80 int32 extruder = 1; // The extruder used for this path segment 81 enum PointType { 82 Point2D = 0; 83 Point3D = 1; 84 } 85 PointType point_type = 2; 86 bytes points = 3; // The points defining the line segments, bytes of float[2/3] array of length N+1 87 bytes line_type = 4; // Type of line segment as an unsigned char array of length 1 or N, where N is the number of line segments in this path 88 bytes line_width = 5; // The widths of the line segments as bytes of a float array of length 1 or N 89 bytes line_thickness = 6; // The thickness of the line segments as bytes of a float array of length 1 or N 90 bytes line_feedrate = 7; // The feedrate of the line segments as bytes of a float array of length 1 or N 91} 92 93 94message GCodeLayer { 95 bytes data = 2; 96} 97 98 99message PrintTimeMaterialEstimates { // The print time for each feature and material estimates for the extruder 100 // Time estimate in each feature 101 float time_none = 1; 102 float time_inset_0 = 2; 103 float time_inset_x = 3; 104 float time_skin = 4; 105 float time_support = 5; 106 float time_skirt = 6; 107 float time_infill = 7; 108 float time_support_infill = 8; 109 float time_travel = 9; 110 float time_retract = 10; 111 float time_support_interface = 11; 112 float time_prime_tower = 12; 113 114 repeated MaterialEstimates materialEstimates = 13; // materialEstimates data 115} 116 117message MaterialEstimates { 118 int64 id = 1; 119 float material_amount = 2; // material used in the extruder 120} 121 122message SettingList { 123 repeated Setting settings = 1; 124} 125 126message Setting { 127 string name = 1; // Internal key to signify a setting 128 129 bytes value = 2; // The value of the setting 130} 131 132message SettingExtruder { 133 string name = 1; //The setting key. 134 135 int32 extruder = 2; //From which extruder stack the setting should inherit. 136} 137 138message GCodePrefix { 139 bytes data = 2; //Header string to be prepended before the rest of the g-code sent from the engine. 140} 141 142message SlicingFinished { 143} 144