修复VideWall初始化显示宫格预览错误的问题和180°旋转时显示错误的问题。
This commit is contained in:
parent
9b137cc68a
commit
84c541dd76
|
@ -229,7 +229,7 @@ export default defineComponent({
|
||||||
];
|
];
|
||||||
|
|
||||||
const screen_mode = ref(0);
|
const screen_mode = ref(0);
|
||||||
const splice_mode = ref("2x2");
|
const splice_mode = ref("");
|
||||||
|
|
||||||
const preview_grid: Ref<HTMLElement | null> = ref(null);
|
const preview_grid: Ref<HTMLElement | null> = ref(null);
|
||||||
const preview_rows = ref(3);
|
const preview_rows = ref(3);
|
||||||
|
@ -288,6 +288,16 @@ export default defineComponent({
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => screen_mode.value,
|
||||||
|
(newV, oldV) => {
|
||||||
|
if (oldV == 0 && newV == 1) {
|
||||||
|
const result = parseSpliceMode(splice_mode.value);
|
||||||
|
splice_mode.value = result.rows + "x" + result.cols;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
() => preview_grid.value,
|
() => preview_grid.value,
|
||||||
(newV: any) => {
|
(newV: any) => {
|
||||||
|
@ -327,7 +337,7 @@ export default defineComponent({
|
||||||
if (isNaN(temp)) {
|
if (isNaN(temp)) {
|
||||||
screen_mode.value = 0;
|
screen_mode.value = 0;
|
||||||
} else {
|
} else {
|
||||||
screen_mode.value = temp == 90 ? 1 : 0;
|
screen_mode.value = temp == 90 || temp == 1 ? 1 : 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -336,10 +346,17 @@ export default defineComponent({
|
||||||
.getCurrentClient()
|
.getCurrentClient()
|
||||||
?.customConnection.getVideoWallConfig();
|
?.customConnection.getVideoWallConfig();
|
||||||
if (video_wall_config) {
|
if (video_wall_config) {
|
||||||
splice_mode.value =
|
if (screen_mode.value == 0) {
|
||||||
video_wall_config.wall_rows.toString() +
|
splice_mode.value =
|
||||||
"x" +
|
video_wall_config.wall_rows.toString() +
|
||||||
video_wall_config.wall_cols.toString();
|
"x" +
|
||||||
|
video_wall_config.wall_cols.toString();
|
||||||
|
} else {
|
||||||
|
splice_mode.value =
|
||||||
|
video_wall_config.wall_cols.toString() +
|
||||||
|
"x" +
|
||||||
|
video_wall_config.wall_rows.toString();
|
||||||
|
}
|
||||||
|
|
||||||
if (
|
if (
|
||||||
Array.isArray(video_wall_config.outputs) &&
|
Array.isArray(video_wall_config.outputs) &&
|
||||||
|
@ -355,7 +372,8 @@ export default defineComponent({
|
||||||
}
|
}
|
||||||
|
|
||||||
if (
|
if (
|
||||||
video_wall_config.outputs[pos].rotation == 1 ||
|
(screen_mode.value == 0 &&
|
||||||
|
video_wall_config.outputs[pos].rotation == 1) ||
|
||||||
video_wall_config.outputs[pos].rotation == 180
|
video_wall_config.outputs[pos].rotation == 180
|
||||||
) {
|
) {
|
||||||
splice_mode.value += " (180°)";
|
splice_mode.value += " (180°)";
|
||||||
|
@ -394,8 +412,8 @@ export default defineComponent({
|
||||||
.getCurrentClient()
|
.getCurrentClient()
|
||||||
?.customConnection.setVideoWallConfig(
|
?.customConnection.setVideoWallConfig(
|
||||||
rotation_180_outputs,
|
rotation_180_outputs,
|
||||||
result.rows,
|
screen_mode.value == 0 ? result.rows : result.cols,
|
||||||
result.cols,
|
screen_mode.value == 0 ? result.cols : result.rows,
|
||||||
screen_mode.value == 0 ? 0 : 90
|
screen_mode.value == 0 ? 0 : 90
|
||||||
);
|
);
|
||||||
if (response) {
|
if (response) {
|
||||||
|
|
Loading…
Reference in New Issue