1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
|
//------------------------------------------------
//--- 010 Editor v8.0.1 Binary Template
//
// File: Creality
// Authors: Julien Delnatte
//------------------------------------------------
// CHANGELOG:
// Add version 3
// Add uint16 unknown after header (Set to 2)
// Add uint32 modelSize and ubyte model[modelSize] after unknown
// Add ubyte offset[64] after resolutionY (Zeros)
BigEndian();
typedef struct {
BitfieldDisablePadding();
ushort startY:13;
ushort endY:13;
ushort x:14;
ubyte grey <fgcolor=cBlack, bgcolor=cWhite>;
} layerPointsData;
typedef struct {
uint32 layerArea <fgcolor=cBlack, bgcolor=cWhite>;
} layerDef;
typedef struct() {
uint32 layerArea <fgcolor=cBlack, bgcolor=cWhite>;
uint32 layerPointNum <fgcolor=cBlack, bgcolor=cWhite>;
layerPointsData pD()[layerPointNum];
ubyte CR_LF2[2] <fgcolor=cBlack, bgcolor=cRed>;
} layerData;
typedef struct(int size) {
ubyte layerDataBlock[size] <fgcolor=cBlack, bgcolor=0x00FF00>;
} RgbPreviewImageRawData;
struct HEADER {
uint32 HeaderSize <fgcolor=cBlack, bgcolor=cWhite>;
char Header[HeaderSize] <fgcolor=cBlack, bgcolor=cRed>;
uint16 Version <fgcolor=cBlack, bgcolor=cWhite>;
uint32 PrinterModelSize <fgcolor=cBlack, bgcolor=cWhite>;
char PrinterModel[PrinterModelSize] <fgcolor=cBlack, bgcolor=cRed>;
uint16 TotalLayers <fgcolor=cBlack, bgcolor=cWhite>;
uint16 ResolutionX <fgcolor=cBlack, bgcolor=cWhite>;
uint16 ResolutionY <fgcolor=cBlack, bgcolor=cWhite>;
ubyte Offset[64];
} header;
struct PREVIEWS {
RgbPreviewImageRawData preview(116*116*2);
ubyte rn0[2] <fgcolor=cBlack, bgcolor=cRed>;
RgbPreviewImageRawData preview2(290*290*2);
ubyte rn1[2] <fgcolor=cBlack, bgcolor=cRed>;
RgbPreviewImageRawData preview2(290*290*2);
ubyte rn2[2] <fgcolor=cBlack, bgcolor=cRed>;
} previews;
struct SLICER_INFO {
uint32 PlateformXLength <fgcolor=cBlack, bgcolor=cWhite>;
wchar_t plateformX[PlateformXLength/2];
uint32 PlateformYLength <fgcolor=cBlack, bgcolor=cWhite>;
wchar_t PlateformY[PlateformYLength/2];
uint32 LayerThicknessLength <fgcolor=cBlack, bgcolor=cWhite>;
wchar_t LayerThickness[LayerThicknessLength/2];
uint16 ExposureTime <fgcolor=cBlack, bgcolor=cWhite>;
uint16 WaitTimeBeforeCure <fgcolor=cBlack, bgcolor=cWhite>; // Cant be 0!
uint16 BottomExposureTime <fgcolor=cBlack, bgcolor=cWhite>;
uint16 BottomLayersCount <fgcolor=cBlack, bgcolor=cWhite>;
uint16 BottomLiftHeight <fgcolor=cBlack, bgcolor=cWhite>;
uint16 BottomLiftSpeed <fgcolor=cBlack, bgcolor=cWhite>;
uint16 LiftHeight <fgcolor=cBlack, bgcolor=cWhite>;
uint16 LiftSpeed <fgcolor=cBlack, bgcolor=cWhite>;
uint16 RetractSpeed <fgcolor=cBlack, bgcolor=cWhite>;
uint16 BottomLightPWM <fgcolor=cBlack, bgcolor=cWhite>;
uint16 LightPWM <fgcolor=cBlack, bgcolor=cWhite>;
} slicerInfo;
struct LAYER_DEF {
local int i;
for( i = 0; i < header.TotalLayers; i++ ){
layerDef ID;
}
ubyte rn3[2] <fgcolor=cBlack, bgcolor=cRed>;
} layerDefs;
if(header.Version >= 3){
struct SLICER_INFO_V3 {
uint32 SoftwareNameSize;
char SoftwareName[SoftwareNameSize];
uint32 MaterialNameSize;
char MaterialName[MaterialNameSize];
ubyte DistortionCompensationEnabled;
uint DistortionCompensationThickness;
uint DistortionCompensationFocalLength;
ubyte XYAxisProfileCompensationEnabled;
ushort XYAxisProfileCompensation;
ubyte ZPenetrationCompensationEnabled;
ushort ZPenetrationCompensationLevel;
ubyte AntiAliasEnabled;
ubyte AntiAliasGreyMinValue;
ubyte AntiAliasGreyMaxValue;
ubyte ImageBlurEnabled;
ubyte ImageBlurLevel;
ubyte rn0[2] <fgcolor=cBlack, bgcolor=cRed>;
} slicerInfoV3;
}
struct LAYERS {
local int i;
for( i = 0; i < header.TotalLayers; i++ ){
layerData lD();
}
} layers;
struct FOOTER {
uint32 FooterSize <fgcolor=cBlack, bgcolor=cWhite>;
char Marker[FooterSize] <fgcolor=cBlack, bgcolor=cRed>;
} footer;
//ubyte CheckSum <fgcolor=cBlack, bgcolor=cWhite>;
//ubyte CheckSum <fgcolor=cBlack, bgcolor=cWhite>;
//ubyte CheckSum <fgcolor=cBlack, bgcolor=cWhite>;
//ubyte CheckSum <fgcolor=cBlack, bgcolor=cWhite>;
uint CheckSum <fgcolor=cBlack, bgcolor=cWhite>;
/*
local ubyte calculatedChecksum = 0;
local ulong i = 0;
for(i = 0; i < FileSize()-4; i++ ){
calculatedChecksum ^= ReadByte(i);
}
ubyte CalculatedChecksum = calculatedChecksum;
*/
|