Update app.py
Browse files
app.py
CHANGED
|
@@ -232,8 +232,28 @@ with demo:
|
|
| 232 |
last_update = gr.Textbox(label="Last Update", value="N/A", interactive=False)
|
| 233 |
|
| 234 |
with gr.Row():
|
| 235 |
-
|
| 236 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 237 |
|
| 238 |
with gr.Row():
|
| 239 |
with gr.Column():
|
|
|
|
| 232 |
last_update = gr.Textbox(label="Last Update", value="N/A", interactive=False)
|
| 233 |
|
| 234 |
with gr.Row():
|
| 235 |
+
# Left column for image and capture button
|
| 236 |
+
with gr.Column(scale=2):
|
| 237 |
+
captured_image = gr.Image(label="Current Print Image", type="pil")
|
| 238 |
+
capture_btn = gr.Button("Capture Image")
|
| 239 |
+
|
| 240 |
+
# Right column for queue status and livestream
|
| 241 |
+
with gr.Column(scale=1):
|
| 242 |
+
gr.Markdown("### YouTube Livestream")
|
| 243 |
+
iframe_html = '''
|
| 244 |
+
<div style="position: relative; width: 100%; padding-top: 56.25%;">
|
| 245 |
+
<iframe
|
| 246 |
+
style="position: absolute; top: 0; left: 0; width: 100%; height: 100%;"
|
| 247 |
+
src="https://www.youtube.com/embed/uXQYRIOTTHo"
|
| 248 |
+
title="Bambu A1mini Livestream"
|
| 249 |
+
frameborder="0"
|
| 250 |
+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
| 251 |
+
referrerpolicy="strict-origin-when-cross-origin"
|
| 252 |
+
allowfullscreen>
|
| 253 |
+
</iframe>
|
| 254 |
+
</div>
|
| 255 |
+
'''
|
| 256 |
+
gr.HTML(iframe_html)
|
| 257 |
|
| 258 |
with gr.Row():
|
| 259 |
with gr.Column():
|