From ab61ee9a3e78c2e7d50ea0cfba4bc2baddf00229 Mon Sep 17 00:00:00 2001 From: DylanSpeiser Date: Tue, 2 Jul 2024 17:04:53 -0700 Subject: [PATCH] v1.1! Completely rewrote web-ui.js to use the tutorial's BMDevice.js AND it works with WebSockets! --- BMDevice.js | 4 + index.html | 123 ++++++++--------- style.css | 5 + web-ui.js | 384 ++++++++++++++++++++++++++++++++++++---------------- 4 files changed, 336 insertions(+), 180 deletions(-) diff --git a/BMDevice.js b/BMDevice.js index d8c73de..d4bf0b4 100644 --- a/BMDevice.js +++ b/BMDevice.js @@ -231,6 +231,10 @@ class BMCamera extends BMDevice { this.PUTdata("/video/whiteBalance",{whiteBalance: newWhiteBalance}); this.PUTdata("/video/whiteBalanceTint",{whiteBalanceTint: newWhiteBalanceTint}); } + + doAutoFocus() { + this.PUTdata("/lens/focus/doAutoFocus"); + } } /* Helper Functions */ diff --git a/index.html b/index.html index 7853cba..b7d79df 100644 --- a/index.html +++ b/index.html @@ -58,51 +58,51 @@ --> Lift
- +
- 0.00 - 0.00 - 0.00 - 0.00 + 0.00 + 0.00 + 0.00 + 0.00
- +
Gamma
- +
- 0.00 - 0.00 - 0.00 - 0.00 + 0.00 + 0.00 + 0.00 + 0.00
- +
Gain
- +
- 0.00 - 0.00 - 0.00 - 0.00 + 0.00 + 0.00 + 0.00 + 0.00
- +
Offset
- +
- 0.00 - 0.00 - 0.00 - 0.00 + 0.00 + 0.00 + 0.00 + 0.00
- +
@@ -110,38 +110,38 @@
FILTER
- - 0 - + + 0 +
GAIN
- - +0db - + + +0db +
SHUTTER
- - 1/50 - + + 1/50 +
BALANCE
- - 5600K - + + 5600K +
- - 0 - + + 0 +
@@ -149,17 +149,17 @@
FOCUS - - + +
IRIS - + X.X
ZOOM - + XXmm
@@ -176,10 +176,10 @@
- - - - + + + + @@ -227,12 +227,12 @@ Preset Select - - + @@ -243,12 +243,12 @@ - +
ISO
AE Mode - @@ -258,7 +258,7 @@
AE Type - @@ -268,7 +268,7 @@
- +
@@ -276,17 +276,17 @@ - + - + @@ -299,24 +299,24 @@
Pivot 0 - +
Adjust 0
- + - + - + @@ -331,7 +331,8 @@
- (v 1.1) + (v 1.1) +
Hue 0 - +
Saturation 0
Luma Contribution 0