Welcome to mirror list, hosted at ThFree Co, Russian Federation.

ToolTimelapseControl.axaml « Tools « Controls « UVtools.WPF - github.com/sn4k3/UVtools.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: edabb6f5454e44e0b4dd972dad79fa1da5cba109 (plain)
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
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
<UserControl xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
             x:Class="UVtools.WPF.Controls.Tools.ToolTimelapseControl">
    <StackPanel Spacing="10" Orientation="Vertical">
        <Grid RowDefinitions="Auto,10,Auto,10,Auto,10,Auto,10,Auto"
              ColumnDefinitions="Auto,10,Auto">

            <TextBlock Grid.Row="0" Grid.Column="0"
                       VerticalAlignment="Center"
                       Text="Raise method:"/>

            <ComboBox Grid.Row="0" Grid.Column="2"
                      Width="500"
                      HorizontalContentAlignment="Stretch"
                      Items="{Binding Operation.RaiseMode, Converter={StaticResource EnumToCollectionConverter}, Mode=OneTime}"
                      SelectedItem="{Binding Operation.RaiseMode, Converter={StaticResource FromValueDescriptionToEnumConverter}}"/>

            <TextBlock Grid.Row="2" Grid.Column="0"
                       VerticalAlignment="Center"
                       ToolTip.Tip="The Z position to raise the build plate to.
    &#x0a;If the set position is lower than the model total height, the time-lapse function won't have effect further the set height."
                       Text="Raise plate to:"/>

            <StackPanel Grid.Row="2" Grid.Column="2"
                        Orientation="Horizontal" Spacing="5">
			    <NumericUpDown Classes="ValueLabel ValueLabel_mm"
                               Minimum="10"
                               Maximum="10000"
                               Increment="1"
                               Width="100"
                               Value="{Binding Operation.RaisePositionZ}"/>

                <Button Content="Auto" Command="{Binding Operation.OptimizeRaisePositionZ}"/>
                <Button Content="Max" Command="{Binding Operation.MaxRaisePositionZ}"/>

                <TextBlock VerticalAlignment="Center"
                           FontWeight="Bold"
                           Text="{Binding SlicerFile.PrintHeight, StringFormat=Print height: {0}mm}"/>
            </StackPanel>

            <TextBlock Grid.Row="4" Grid.Column="0"
                       VerticalAlignment="Center"
                       ToolTip.Tip="The alternating height in millimeters to raise when, it will raise only at each defined millimeters and skip the same next millimeters.
    &#x0a;Use 0mm to raise at each layer."
                       Text="Raise each:"/>

			<NumericUpDown Grid.Row="4" Grid.Column="2"
                           Classes="ValueLabel ValueLabel_mm"
                           HorizontalAlignment="Left"
                           Minimum="0"
                           Maximum="10000"
                           Increment="0.5"
                           Width="100"
                           Value="{Binding Operation.RaiseEachNthHeight}"/>


		    <!-- LiftHeight: Wait time after lift -->
            <TextBlock Grid.Row="6" Grid.Column="0"
                       VerticalAlignment="Center"
                       ToolTip.Tip="The time to wait on the set position.
    &#x0a;Use the lowest as possible but enough to take the photo while standing still."
                       IsVisible="{Binding Operation.IsLiftHeightMode}"
                       Text="Wait time:"/>

            <NumericUpDown Grid.Row="6" Grid.Column="2"
                           Classes="ValueLabel ValueLabel_s"
                           HorizontalAlignment="Left"
                           Minimum="0"
                           Maximum="100"
                           Increment="0.5"
                           Width="100"
                           Value="{Binding Operation.WaitTimeAfterLift}">
			    <NumericUpDown.IsVisible>
				    <MultiBinding Converter="{x:Static BoolConverters.And}">
					    <Binding Path="Operation.IsLiftHeightMode"/>
					    <Binding Path="SlicerFile.CanUseLayerWaitTimeAfterLift"/>
				    </MultiBinding>
			    </NumericUpDown.IsVisible>
		    </NumericUpDown>

            <TextBlock Grid.Row="6" Grid.Column="2"
                       VerticalAlignment="Center"
                       ToolTip.Tip="You won't be able to choose a time to wait while standing still.
    &#x0a;Advice: Take the photo when printer is de-accelerating near the target height."
                       Text="(Not supported by your printer / file format)">
                <TextBlock.IsVisible>
                    <MultiBinding Converter="{x:Static BoolConverters.And}">
                        <Binding Path="Operation.IsLiftHeightMode"/>
                        <Binding Path="!SlicerFile.CanUseLayerWaitTimeAfterLift"/>
                    </MultiBinding>
                </TextBlock.IsVisible>
            </TextBlock>

            <!-- VirtualLayer: Exposure time -->
            <TextBlock Grid.Row="6" Grid.Column="0"
                       VerticalAlignment="Center"
                       ToolTip.Tip="The exposure time of the virtual layer.
    &#x0a;This can be used to trigger an external light sensor.
    &#x0a;Use the lowest as possible but enough to sensor to trigger.
    &#x0a;If you want to disable this set to 0.05s as most file formats are not compatible with 0s."
                       IsVisible="{Binding Operation.IsVirtualLayerMode}"
                       Text="Exposure time:"/>

            <StackPanel Grid.Row="6" Grid.Column="2"
                        Orientation="Horizontal" Spacing="10">

				<NumericUpDown 
                           Classes="ValueLabel ValueLabel_s"
                           HorizontalAlignment="Left"
                           Minimum="0"
                           Maximum="100"
                           Increment="0.5"
                           Width="100"
                           Value="{Binding Operation.ExposureTime}">
                    <NumericUpDown.IsVisible>
                        <MultiBinding Converter="{x:Static BoolConverters.And}">
                            <Binding Path="Operation.IsVirtualLayerMode"/>
                            <Binding Path="SlicerFile.CanUseLayerExposureTime"/>
                        </MultiBinding>
                    </NumericUpDown.IsVisible>
                </NumericUpDown>

            
                <CheckBox VerticalAlignment="Center"
                          ToolTip.Tip="If enabled, output a dummy pixel inside the layer bound to prevent a empty image and to ensure the correct handle by the firmware. This will also prevent layer being removed by auto-fix issues (Empty Layers)."
                          Content="Output a dummy pixel"
                          IsVisible="{Binding Operation.IsVirtualLayerMode}"
                          IsChecked="{Binding Operation.OutputDummyPixel}"/>
            </StackPanel>

            <TextBlock Grid.Row="6" Grid.Column="2"
                       VerticalAlignment="Center"
                       ToolTip.Tip="You won't be able to choose a exposure time for the virtual layer.
    &#x0a;Global exposure time will be used instead.
    &#x0a;Advice: Take the photo when printer is de-accelerating near the target height."
                       Text="(Not supported by your printer / file format)">
                <TextBlock.IsVisible>
                    <MultiBinding Converter="{x:Static BoolConverters.And}">
					    <Binding Path="Operation.IsVirtualLayerMode"/>
                        <Binding Path="!SlicerFile.CanUseLayerExposureTime"/>
                    </MultiBinding>
                </TextBlock.IsVisible>
            </TextBlock>

            <CheckBox Grid.Row="8" Grid.Column="2"
                      VerticalAlignment="Center"
                      Content="Set custom lift parameters"
                      IsChecked="{Binding Operation.UseCustomLift}">
			    <CheckBox.IsVisible>
				    <MultiBinding Converter="{x:Static BoolConverters.And}">
					    <Binding Path="Operation.IsLiftHeightMode"/>
					    <Binding Path="SlicerFile.CanUseLayerLiftHeight"/>
				    </MultiBinding>
			    </CheckBox.IsVisible>
            </CheckBox>
	    </Grid>

        <Grid RowDefinitions="Auto,10,Auto,10,Auto,10,Auto,10,Auto"
              ColumnDefinitions="Auto,10,210,5,Auto,5,210">
			<Grid.IsVisible>
				<MultiBinding Converter="{x:Static BoolConverters.And}">
					<Binding Path="Operation.IsLiftHeightMode"/>
					<Binding Path="Operation.UseCustomLift"/>
					<Binding Path="SlicerFile.CanUseLayerLiftHeight"/>
				</MultiBinding>
			</Grid.IsVisible>

                <TextBlock Grid.Row="0" Grid.Column="0"
                           VerticalAlignment="Center"
                           ToolTip.Tip="The slow first lift sequence (TSMC).
&#x0a;Use a low value or 0 to disable."
                           Text="Slow lift height:"/>

                <NumericUpDown Grid.Row="0" Grid.Column="2"
                               Classes="ValueLabel ValueLabel_mm"
                               Minimum="0"
                               Maximum="20"
                               Increment="1"
                               IsVisible="{Binding SlicerFile.CanUseLayerLiftHeight2}"
                               Value="{Binding Operation.SlowLiftHeight}">
                </NumericUpDown>

                <TextBlock Grid.Row="0" Grid.Column="2"
                           VerticalAlignment="Center"
                           ToolTip.Tip="(Not supported by your printer / file format)"
                           IsVisible="{Binding !SlicerFile.CanUseLayerLiftHeight2}"
                           Text="(Not supported)"/>

                <TextBlock Grid.Row="2" Grid.Column="0"
                           VerticalAlignment="Center"
                           Text="Lift speed:"/>

                <NumericUpDown Grid.Row="2" Grid.Column="2"
                               Classes="ValueLabel ValueLabel_mmmin"
                               Minimum="0"
                               Maximum="10000"
                               Increment="10"
                               IsVisible="{Binding SlicerFile.CanUseLayerLiftSpeed}"
                               Value="{Binding Operation.LiftSpeed}">
                </NumericUpDown>

                <TextBlock Grid.Row="2" Grid.Column="2"
                           VerticalAlignment="Center"
                           ToolTip.Tip="(Not supported by your printer / file format)"
                           IsVisible="{Binding !SlicerFile.CanUseLayerLiftSpeed}"
                           Text="(Not supported)"/>

                <TextBlock Grid.Row="2" Grid.Column="4"
                           VerticalAlignment="Center"
                           IsVisible="{Binding SlicerFile.CanUseLayerLiftSpeed2}"
                           Text="-"/>

                <NumericUpDown Grid.Row="2" Grid.Column="6"
                               Classes="ValueLabel ValueLabel_mmmin"
                               Minimum="0"
                               Maximum="10000"
                               Increment="10"
                               IsVisible="{Binding SlicerFile.CanUseLayerLiftSpeed2}"
                               Value="{Binding Operation.LiftSpeed2}"/>

                <TextBlock Grid.Row="4" Grid.Column="0"
                           VerticalAlignment="Center"
                           ToolTip.Tip="The slow last retract sequence (TSMC).
&#x0a;Use a low value or 0 to disable."
                           Text="Slow retract height:"/>

                <NumericUpDown Grid.Row="4" Grid.Column="2"
                               Classes="ValueLabel ValueLabel_mm"
                               Minimum="0"
                               Maximum="20"
                               Increment="1"
                               IsVisible="{Binding SlicerFile.CanUseLayerRetractHeight2}"
                               Value="{Binding Operation.SlowRetractHeight}">
                </NumericUpDown>

                <TextBlock Grid.Row="4" Grid.Column="2"
                           VerticalAlignment="Center"
                           ToolTip.Tip="(Not supported by your printer / file format)"
                           IsVisible="{Binding !SlicerFile.CanUseLayerRetractHeight2}"
                           Text="(Not supported)"/>


                <TextBlock Grid.Row="6" Grid.Column="0"
                           VerticalAlignment="Center"
                           Text="Retract speed:"/>

                <NumericUpDown Grid.Row="6" Grid.Column="2"
                               Classes="ValueLabel ValueLabel_mmmin"
                               Minimum="0"
                               Maximum="10000"
                               Increment="10"
                               IsVisible="{Binding SlicerFile.CanUseLayerRetractSpeed}"
                               Value="{Binding Operation.RetractSpeed}">
                </NumericUpDown>

                <TextBlock Grid.Row="6" Grid.Column="2"
                           VerticalAlignment="Center"
                           ToolTip.Tip="(Not supported by your printer / file format)"
                           IsVisible="{Binding !SlicerFile.CanUseLayerRetractSpeed}"
                           Text="(Not supported)"/>

                <TextBlock Grid.Row="6" Grid.Column="4"
                           VerticalAlignment="Center"
                           IsVisible="{Binding SlicerFile.CanUseLayerRetractSpeed2}"
                           Text="-"/>

                <NumericUpDown Grid.Row="6" Grid.Column="6"
                               Classes="ValueLabel ValueLabel_mmmin"
                               Minimum="0"
                               Maximum="10000"
                               Increment="10"
                               IsVisible="{Binding SlicerFile.CanUseLayerRetractSpeed2}"
                               Value="{Binding Operation.RetractSpeed2}"/>
            
        </Grid>

    </StackPanel>
</UserControl>