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