revisi 16/12/2024

This commit is contained in:
2024-12-16 15:02:46 +07:00
parent f6ee4817e6
commit eceb94d524
9 changed files with 224 additions and 200 deletions

1
.idea/misc.xml generated
View File

@@ -1,4 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="EntryPointsManager">
<list size="1">

View File

@@ -1,19 +1,19 @@
#Thu Oct 31 09:35:27 WIB 2024
#Mon Dec 16 15:02:10 WIB 2024
AudioPhase1=C\:\\Users\\rdkar\\OneDrive\\Documents\\IntelliJ Project\\ErhaCam\\audio\\phase1.mp3
AudioPhase2=C\:\\Users\\rdkar\\OneDrive\\Documents\\IntelliJ Project\\ErhaCam\\audio\\phase2.mp3
AudioPhase3=C\:\\Users\\rdkar\\OneDrive\\Documents\\IntelliJ Project\\ErhaCam\\audio\\phase3.mp3
AudioPhase4=C\:\\Users\\rdkar\\OneDrive\\Documents\\IntelliJ Project\\ErhaCam\\audio\\phase4.mp3
AudioPhase5=C\:\\Users\\rdkar\\OneDrive\\Documents\\IntelliJ Project\\ErhaCam\\audio\\phase5.mp3
CameraCenter=Arducam IMX477 HQ Camera
CameraCenter=OBSBOT Meet 2 StreamCamera
CameraConfigCenter={"Brightness"\:0.0,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraConfigLeft45={"Brightness"\:0.0,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraConfigLeft45={"Brightness"\:37.58730158730158,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraConfigLeft90={"Brightness"\:0.0,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraConfigRight45={"Brightness"\:0.0,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraConfigRight90={"Brightness"\:0.0,"Contrast"\:32.0,"Saturation"\:64.0,"Hue"\:0.0,"Gain"\:0.0,"Exposure"\:157.0,"Sharpness"\:3.0,"Gamma"\:100.0,"AutoExposure"\:true,"AutoFocus"\:true,"AutoWhiteBalance"\:true}
CameraLeft45=OBSBOT Meet 2 StreamCamera
CameraLeft90=ACER QHD User Facing
CameraRight45=
CameraRight90=
CameraLeft90=OBSBOT Meet 2 StreamCamera
CameraRight45=OBSBOT Meet 2 StreamCamera
CameraRight90=OBSBOT Meet 2 StreamCamera
FTPHost=192.168.10.2
FTPPass=password
FTPPath=/

Binary file not shown.

View File

@@ -11,9 +11,10 @@ import com.google.zxing.client.j2se.BufferedImageLuminanceSource;
import com.google.zxing.common.HybridBinarizer;
import javafx.application.Platform;
import javafx.beans.InvalidationListener;
import javafx.beans.Observable;
import javafx.concurrent.Task;
import javafx.fxml.FXML;
import javafx.scene.control.CheckBox;
import javafx.scene.control.Slider;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
@@ -23,7 +24,6 @@ import javafx.scene.image.WritableImage;
import javafx.scene.layout.AnchorPane;
import lombok.Getter;
import lombok.Setter;
import lombok.val;
import org.bytedeco.javacv.Frame;
import org.bytedeco.javacv.OpenCVFrameGrabber;
import org.bytedeco.opencv.global.opencv_imgproc;
@@ -86,12 +86,7 @@ public class Cameradetail {
private Slider gainSlider;
@FXML
private Slider exposureSlider;
@FXML
private CheckBox AutoExposure;
@FXML
private CheckBox AutoWhiteBalance;
@FXML
private CheckBox AutoFocus;
private final UMat BestMat = new UMat();
private final UMat LiveMat = new UMat();
@@ -99,17 +94,31 @@ public class Cameradetail {
private Size PhotoSize = new Size(1920, 1080);
private void setSliderValue(Slider sld, CameraProperty prop, double value){
if (sld!=null){
sld.setMin(prop.Min);
sld.setMax(prop.Max);
sld.setValue(value);
}
}
private void resize_streamanchor(){
if (streamanchor!=null){
if (streamanchor.getHeight()!=0){
if (streamanchor.getWidth()!=0){
camerastream.setFitHeight(streamanchor.getHeight()-10);
//camerastream.setFitWidth(streamanchor.getWidth());
camerastream.setPreserveRatio(true);
}
}
}
}
@FXML
public void initialize(){
camerastream.fitHeightProperty().bind(streamanchor.heightProperty());
//camerastream.fitWidthProperty().bind(streamanchor.widthProperty());
camerastream.setPreserveRatio(true);
streamanchor.heightProperty().addListener(obs -> resize_streamanchor());
streamanchor.widthProperty().addListener(obs -> resize_streamanchor());
Platform.runLater(()->{
setSliderValue(brightnessSlider, ArducamIMX477Preset.Brightness, config.getBrightness(cameraConfigEnum));
@@ -118,27 +127,10 @@ public class Cameradetail {
setSliderValue(hueSlider, ArducamIMX477Preset.Hue, config.getHue(cameraConfigEnum));
setSliderValue(gainSlider, ArducamIMX477Preset.Gain, config.getGain(cameraConfigEnum));
setSliderValue(exposureSlider, ArducamIMX477Preset.ExposureTime, config.getExposure(cameraConfigEnum));
AutoExposure.setSelected(config.getAutoExposure(cameraConfigEnum));
AutoWhiteBalance.setSelected(config.getAutoWhiteBalance(cameraConfigEnum));
AutoFocus.setSelected(config.getAutoFocus(cameraConfigEnum));
});
AutoExposure.selectedProperty().addListener((obs, oldVal, newVal) -> {
setAutoExposure(newVal);
config.setAutoExposure(cameraConfigEnum, newVal);
raise_log("AutoExposure for "+getCameraTitle()+" changed to " + newVal);
});
AutoWhiteBalance.selectedProperty().addListener((obs, oldVal, newVal) -> {
setAutoWB(newVal);
config.setAutoWhiteBalance(cameraConfigEnum, newVal);
raise_log("AutoWhiteBalance for "+getCameraTitle()+" changed to "+newVal);
});
AutoFocus.selectedProperty().addListener((obs, oldVal, newVal) -> {
setAutoFocus(newVal);
config.setAutoFocus(cameraConfigEnum, newVal);
raise_log("AutoFocus for "+getCameraTitle()+" changed to "+newVal);
});
brightnessSlider.valueProperty().addListener((obs, oldVal, newVal) -> {
setBrightness(newVal.doubleValue());
@@ -181,9 +173,7 @@ public class Cameradetail {
hueSlider.adjustValue(ArducamIMX477Preset.Hue.Default);
gainSlider.adjustValue(ArducamIMX477Preset.Gain.Default);
exposureSlider.adjustValue(ArducamIMX477Preset.ExposureTime.Default);
AutoExposure.setSelected(true);
AutoFocus.setSelected(true);
AutoWhiteBalance.setSelected(true);
}
@@ -541,22 +531,13 @@ public class Cameradetail {
}
//TODO Revisi nama file
private String makeFileName(String prefix){
//make filename with prefix_POSITION_YYYY-MM-DD_HH-MM-SS
LocalDateTime ldt = LocalDateTime.now();
String timetag = ldt.getYear() + "-" + ldt.getMonthValue() + "-" + ldt.getDayOfMonth() + "_" + ldt.getHour() + "-" + ldt.getMinute() + "-" + ldt.getSecond();
return prefix+"_"
+ switch(cameratitle.getText()){
case "Camera Left 90" -> "LEFT90";
case "Camera Left 45" -> "LEFT45";
case "Camera Center" -> "CENTER";
case "Camera Right 45" -> "RIGHT45";
case "Camera Right 90" -> "RIGHT90";
default -> "UNKNOWN";
}
+ "_" + timetag + ".jpg";
return prefix+" "+timetag+" "+cameratitle.getText() + ".jpg";
}
@@ -596,9 +577,7 @@ public class Cameradetail {
Platform.runLater(()->setCameraStatus(ss));
raise_log(ss);
AutoExposure.setSelected(true);
AutoFocus.setSelected(true);
AutoWhiteBalance.setSelected(true);
Task<Image> task = new Task<>() {
@SuppressWarnings("BusyWait")
@@ -625,8 +604,11 @@ public class Cameradetail {
IsGrabbingLiveView.set(true);
Frame frame = mGrabber.grab(); // grab frame
Mat mat = matconverter.convert(frame); // convert to Mat
if (mat.empty()) continue; // kalau gak ada data, continue
int counter = fps.incrementAndGet();
if (counter % 5 != 0) continue; // frame skip to 6 fps
mat.copyTo(BestMat); // copy to BestMat for using OpenCL
fps.addAndGet(1);
IsGrabbingLiveView.set(false);
if (frame != null) {

View File

@@ -10,14 +10,19 @@ import Database.Sqlite;
import FTP.FTPUpload;
import FTP.FTPUploadEvent;
import javafx.application.Platform;
import javafx.beans.InvalidationListener;
import javafx.beans.Observable;
import javafx.beans.value.ChangeListener;
import javafx.beans.value.ObservableValue;
import javafx.concurrent.Task;
import javafx.fxml.FXML;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.scene.control.Alert;
import javafx.scene.control.Button;
import javafx.scene.control.TextArea;
import javafx.scene.layout.AnchorPane;
import javafx.stage.DirectoryChooser;
import lombok.val;
import java.util.*;
import java.util.concurrent.Callable;
@@ -26,7 +31,6 @@ import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import javafx.scene.control.Alert.AlertType;
import org.bytedeco.javacv.OpenCVFrameConverter;
import org.bytedeco.javacv.OpenCVFrameGrabber;
import org.bytedeco.javacv.VideoInputFrameGrabber;
import org.bytedeco.opencv.opencv_core.Size;
@@ -36,6 +40,9 @@ import static Config.SomeCodes.*;
public class CaptureView {
@FXML
private AnchorPane CaptureViewAnchor;
@FXML
private AnchorPane cam1, cam2, cam3, cam4, cam5, controlpane;
@@ -44,6 +51,8 @@ public class CaptureView {
@FXML
private TextArea directorypath, prefixfile;
@FXML
private Button btnTakePhoto;
@FXML
private AnchorPane progressanchor;
@@ -56,6 +65,7 @@ public class CaptureView {
private List<String> cams;
@FXML
private void ChangeDirectory(){
DirectoryChooser dc = new DirectoryChooser();
@@ -224,6 +234,11 @@ public class CaptureView {
}
}
private void UpdateBtnTakePhoto(){
boolean valid = ValidDirectory(directorypath.getText()) && ValidString(prefixfile.getText());
btnTakePhoto.setDisable(!valid);
}
@FXML
public void initialize(){
audio_posisikan_muka = ExtractResource("/satu.wav");
@@ -234,6 +249,11 @@ public class CaptureView {
audioPlayer = new AudioPlayer(1,48000);
Logger.info("Audio Player : "+(audioPlayer.isInited()? "Inited" : "Not Inited"));
btnTakePhoto.setDisable(true);
directorypath.textProperty().addListener((obs, oldval, newval)-> UpdateBtnTakePhoto());
prefixfile.textProperty().addListener((obs, oldval, newval)-> UpdateBtnTakePhoto());
cams = null;
try{
String[] xxx = VideoInputFrameGrabber.getDeviceDescriptions();
@@ -244,6 +264,8 @@ public class CaptureView {
Logger.error("Error getting camera list: "+e.getMessage());
}
LoadCameraDetail(cam1, 1, CameraConfigEnum.CameraConfigLeft90);
LoadCameraDetail(cam2, 2, CameraConfigEnum.CameraConfigLeft45);
LoadCameraDetail(cam3, 3, CameraConfigEnum.CameraConfigCenter);
@@ -261,8 +283,9 @@ public class CaptureView {
if (ValidString(camleft90)){
int[] indexes = FindIndexes(cams, camleft90);
if (indexes.length>0){
indexleft90 = indexes[0];
if (indexleft90!=1){
indexleft90 = FindFirstIndex(cams, camleft90);
Logger.info("Left90 Index: "+indexleft90);
if (indexleft90!=-1){
final int finalindex = indexleft90;
new Thread(()-> SetupCameraWithController(image1, camleft90, finalindex)).start();
}
@@ -273,6 +296,7 @@ public class CaptureView {
int[] indexes = FindIndexes(cams, camleft45);
if (indexes.length>0){
indexleft45 = FindFirstIndex(cams, camleft45, indexleft90);
Logger.info("Left45 Index: "+indexleft45);
if (indexleft45!=-1) {
final int finalindex = indexleft45;
new Thread(()-> SetupCameraWithController(image2, camleft45, finalindex)).start();
@@ -284,6 +308,7 @@ public class CaptureView {
int[] indexes = FindIndexes(cams, camcenter);
if (indexes.length>0){
indexcenter = FindFirstIndex(cams, camcenter, indexleft90, indexleft45);
Logger.info("Center Index: "+indexcenter);
if (indexcenter!=-1) {
final int finalindex = indexcenter;
new Thread(()-> SetupCameraWithController(image3, camcenter, finalindex)).start();
@@ -295,6 +320,7 @@ public class CaptureView {
int[] indexes = FindIndexes(cams, camright45);
if (indexes.length>0){
indexright45 = FindFirstIndex(cams, camright45, indexleft90, indexleft45, indexcenter);
Logger.info("Right45 Index: "+indexright45);
if (indexright45!=-1) {
final int finalindex = indexright45;
new Thread(()-> SetupCameraWithController(image4, camright45, finalindex)).start();
@@ -307,6 +333,7 @@ public class CaptureView {
int[] indexes = FindIndexes(cams, camright90);
if (indexes.length>0){
indexright90 = FindFirstIndex(cams, camright90, indexleft90, indexleft45, indexcenter, indexright45);
Logger.info("Right90 Index: "+indexright90);
if (indexright90!=-1) {
final int finalindex = indexright90;
new Thread(()-> SetupCameraWithController(image5, camright90, finalindex)).start();
@@ -386,11 +413,11 @@ public class CaptureView {
private void SetupCameraWithController(Cameradetail image, String cameraname, int devicenumber){
if (image!=null){
String title = switch(image.getCameraConfigEnum()){
case CameraConfigCenter -> "Camera Center";
case CameraConfigLeft45 -> "Camera Left 45";
case CameraConfigLeft90 -> "Camera Left 90";
case CameraConfigRight45 -> "Camera Right 45";
case CameraConfigRight90 -> "Camera Right 90";
case CameraConfigCenter -> "03";
case CameraConfigLeft45 -> "02";
case CameraConfigLeft90 -> "01";
case CameraConfigRight45 -> "04";
case CameraConfigRight90 -> "05";
};
Platform.runLater(()-> image.setCameraTitle(title));
if (devicenumber!=-1){
@@ -468,17 +495,38 @@ public class CaptureView {
private void LoadCameraDetail(AnchorPane cam, int camid, CameraConfigEnum cc){
try{
FXMLLoader loader = new FXMLLoader(getClass().getResource("cameradetail.fxml"));
AnchorPane child = loader.load();
AnchorPane.setTopAnchor(child, 0.0);
AnchorPane.setBottomAnchor(child, 0.0);
AnchorPane.setLeftAnchor(child, 0.0);
AnchorPane.setRightAnchor(child, 0.0);
cam.getChildren().clear();
cam.getChildren().add(child);
cam.widthProperty().addListener(observable ->{
//System.out.println("Width property, cam "+camid+" width="+cam.getWidth()+" height="+cam.getHeight());
if (cam.getWidth()!=0) {
if (cam.getHeight()!=0){
AnchorPane.setTopAnchor(child, 0.0);
AnchorPane.setBottomAnchor(child, 0.0);
AnchorPane.setLeftAnchor(child, 0.0);
AnchorPane.setRightAnchor(child, 0.0);
}
}
});
cam.heightProperty().addListener(observable -> {
//System.out.println("Height property, cam "+camid+" width="+cam.getWidth()+" height="+cam.getHeight());
if (cam.getWidth()!=0) {
if (cam.getHeight()!=0){
AnchorPane.setTopAnchor(child, 0.0);
AnchorPane.setBottomAnchor(child, 0.0);
AnchorPane.setLeftAnchor(child, 0.0);
AnchorPane.setRightAnchor(child, 0.0);
}
}
});
switch(camid){
case 1:

View File

@@ -23,7 +23,7 @@ public class MainApplication extends Application {
Scene scene = new Scene(fxmlLoader.load(), screenbound.getWidth(), screenbound.getHeight());
stage.setTitle("MultiCam Capture App for ERHA");
stage.setScene(scene);
stage.setResizable(false);
stage.setResizable(true);
stage.setMaximized(true);
stage.setOnCloseRequest(e->{
config.Save();

View File

@@ -705,12 +705,12 @@ public class Cameradetail_Arducam {
if (use_face){
RectVector face = DetectFace(graymat);
if (face!=null && face.size()>0){
if (event!=null) event.onFaceDetector(true);
if (event!=null) event.onFaceDetector(true,photoWidth, photoHeight);
for(int i=0; i<face.size(); i++){
val rect = face.get(i);
rectangle(umat, rect, Scalar.GREEN);
}
} else if (event!=null) event.onFaceDetector(false);
} else if (event!=null) event.onFaceDetector(false, photoWidth, photoHeight);
}

View File

@@ -1,56 +1,60 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.CheckBox?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.Slider?>
<?import javafx.scene.image.Image?>
<?import javafx.scene.image.ImageView?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.BorderPane?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.VBox?>
<?import javafx.geometry.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.image.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx/22" xmlns:fx="http://javafx.com/fxml/1" fx:controller="id.co.gtc.erhacam.Cameradetail">
<AnchorPane prefHeight="280.0" xmlns="http://javafx.com/javafx/11.0.14-internal" xmlns:fx="http://javafx.com/fxml/1" fx:controller="id.co.gtc.erhacam.Cameradetail">
<children>
<BorderPane layoutX="200.0" layoutY="64.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<top>
<AnchorPane prefHeight="30.0">
<GridPane layoutX="5.0" layoutY="5.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints maxHeight="-Infinity" minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<Label fx:id="cameratitle" alignment="CENTER" layoutX="240.0" layoutY="14.0" text="Camera Title" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
<AnchorPane minHeight="30.0" GridPane.rowIndex="1">
<children>
<GridPane AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" percentWidth="20.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<AnchorPane>
<children>
<Label fx:id="cameratitle" alignment="CENTER" style="-fx-border-color: black;" text="Camera Title" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
</children>
</AnchorPane>
</top>
<bottom>
<AnchorPane prefHeight="30.0">
<AnchorPane GridPane.columnIndex="1">
<children>
<Label fx:id="camerastatus" alignment="CENTER" layoutX="252.0" layoutY="6.0" text="Camera Status" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
<Label fx:id="camerastatus" alignment="CENTER" style="-fx-border-color: black;" text="Camera Status" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
</children>
</AnchorPane>
</bottom>
<center>
<AnchorPane fx:id="streamanchor" minHeight="240.0">
<children>
<HBox alignment="CENTER" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<children>
<ImageView fx:id="camerastream" fitHeight="240.0" pickOnBounds="true" preserveRatio="true">
<image>
<Image url="@gtcbackground.png" />
</image>
</ImageView>
</children>
</HBox>
</GridPane>
</children>
<BorderPane.margin>
<Insets />
</BorderPane.margin>
</AnchorPane>
</center>
<right>
<AnchorPane prefWidth="150.0">
<AnchorPane prefHeight="200.0" prefWidth="200.0">
<children>
<VBox AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<GridPane layoutX="-28.0" layoutY="-29.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" percentWidth="70.0" prefWidth="100.0" />
<ColumnConstraints fillWidth="false" maxWidth="-Infinity" minWidth="-Infinity" percentWidth="10.0" prefWidth="100.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<AnchorPane GridPane.columnIndex="1">
<children>
<VBox maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="240.0" prefWidth="140.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<children>
<Label text="Brightness" />
<Slider fx:id="brightnessSlider" min="-100.0">
@@ -71,7 +75,7 @@
</VBox.margin>
</Slider>
<Label layoutX="10.0" layoutY="74.0" text="Hue" />
<Slider fx:id="hueSlider" layoutX="10.0" layoutY="92.0" min="-100.0">
<Slider fx:id="hueSlider" layoutX="10.0" layoutY="92.0" min="-100.0" prefHeight="14.0" prefWidth="63.0">
<VBox.margin>
<Insets />
</VBox.margin>
@@ -93,33 +97,28 @@
<Insets left="5.0" right="5.0" top="5.0" />
</VBox.margin>
</Button>
<HBox>
<children>
<CheckBox fx:id="AutoFocus" minWidth="40.0" mnemonicParsing="false" text="AF">
<HBox.margin>
<Insets right="5.0" />
</HBox.margin>
</CheckBox>
<CheckBox fx:id="AutoExposure" minWidth="40.0" mnemonicParsing="false" text="AE">
<HBox.margin>
<Insets right="5.0" />
</HBox.margin>
</CheckBox>
<CheckBox fx:id="AutoWhiteBalance" minWidth="40.0" mnemonicParsing="false" text="AWB">
<HBox.margin>
<Insets right="5.0" />
</HBox.margin>
</CheckBox>
</children>
<VBox.margin>
<Insets top="5.0" />
</VBox.margin>
</HBox>
</children>
</VBox>
</children>
</AnchorPane>
</right>
</BorderPane>
<AnchorPane fx:id="streamanchor">
<children>
<HBox alignment="CENTER" prefHeight="240.0" prefWidth="700.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0" />
<ImageView fx:id="camerastream" fitHeight="240.0" pickOnBounds="true" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<image>
<Image url="@gtcbackground.png" />
</image>
</ImageView>
</children>
</AnchorPane>
</children>
</GridPane>
</children>
</AnchorPane>
</children>
</GridPane>
</children>
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
</AnchorPane>

View File

@@ -1,17 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.ScrollPane?>
<?import javafx.scene.control.TextArea?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.ColumnConstraints?>
<?import javafx.scene.layout.GridPane?>
<?import javafx.scene.layout.RowConstraints?>
<?import javafx.scene.layout.VBox?>
<?import javafx.geometry.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308" minHeight="-Infinity" minWidth="-Infinity" prefHeight="768.0" prefWidth="1024.0" xmlns="http://javafx.com/javafx/22" xmlns:fx="http://javafx.com/fxml/1" fx:controller="id.co.gtc.erhacam.CaptureView">
<AnchorPane fx:id="CaptureViewAnchor" maxHeight="1.7976931348623157E308" maxWidth="1.7976931348623157E308" minHeight="-Infinity" minWidth="-Infinity" prefHeight="768.0" prefWidth="1024.0" xmlns="http://javafx.com/javafx/11.0.14-internal" xmlns:fx="http://javafx.com/fxml/1" fx:controller="id.co.gtc.erhacam.CaptureView">
<children>
<GridPane layoutX="99.0" layoutY="147.0" style="-fx-grid-lines-visible: true;" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<columnConstraints>
@@ -45,12 +38,12 @@
<children>
<AnchorPane prefHeight="200.0" prefWidth="200.0">
<children>
<Label layoutX="28.0" layoutY="8.0" prefHeight="30.0" prefWidth="154.0" text="Directory" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="5.0" />
<Label layoutX="28.0" layoutY="8.0" prefHeight="30.0" prefWidth="154.0" text="Save Directory" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="5.0" />
</children>
</AnchorPane>
<AnchorPane prefHeight="200.0" prefWidth="200.0" GridPane.rowIndex="1">
<children>
<Label layoutX="31.0" layoutY="6.0" prefHeight="30.0" prefWidth="154.0" text="Prefix" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="5.0" />
<Label layoutX="31.0" layoutY="6.0" prefHeight="30.0" prefWidth="154.0" text="Patient ID" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="5.0" />
</children>
</AnchorPane>
<AnchorPane prefHeight="200.0" prefWidth="200.0" GridPane.columnIndex="1">
@@ -90,7 +83,7 @@
</AnchorPane>
<AnchorPane prefHeight="200.0" prefWidth="200.0" GridPane.columnIndex="2">
<children>
<Button layoutX="59.0" layoutY="23.0" mnemonicParsing="false" onAction="#TakePhotos" prefHeight="70.0" prefWidth="170.0" text="Take Photos" wrapText="true" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="0.0" />
<Button fx:id="btnTakePhoto" layoutX="59.0" layoutY="23.0" mnemonicParsing="false" onAction="#TakePhotos" prefHeight="70.0" prefWidth="170.0" text="Take Photos" wrapText="true" AnchorPane.bottomAnchor="5.0" AnchorPane.leftAnchor="5.0" AnchorPane.rightAnchor="5.0" AnchorPane.topAnchor="0.0" />
</children>
</AnchorPane>
</children>
@@ -108,7 +101,10 @@
</ScrollPane>
</children>
</VBox>
</children></AnchorPane>
</children>
<padding>
<Insets top="5.0" />
</padding></AnchorPane>
</children>
</GridPane>
</children>