1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-22 19:54:03 +02:00
This commit is contained in:
syuilo
2026-04-27 16:58:01 +09:00
parent 76ce6c84c0
commit 9c25c44a8a
3 changed files with 20 additions and 0 deletions

View File

@@ -3562,3 +3562,5 @@ _room:
graphicsQuality: "グラフィックの品質" graphicsQuality: "グラフィックの品質"
frameRate: "フレームレート" frameRate: "フレームレート"
resolution: "解像度" resolution: "解像度"
yourDeviceNotSupported_title: "お使いのデバイスはMisskeyRoomをサポートしていません。"
yourDeviceNotSupported_description: "MisskeyRoomを動作させるには、WebGPUをサポートするデバイスが必要です。"

View File

@@ -163,6 +163,7 @@ SPDX-License-Identifier: AGPL-3.0-only
<script lang="ts" setup> <script lang="ts" setup>
import { computed, defineAsyncComponent, nextTick, onMounted, onUnmounted, ref, shallowRef, useTemplateRef, watch } from 'vue'; import { computed, defineAsyncComponent, nextTick, onMounted, onUnmounted, ref, shallowRef, useTemplateRef, watch } from 'vue';
import * as BABYLON from '@babylonjs/core';
import XObjectCustomizeForm from './room.object-customize-form.vue'; import XObjectCustomizeForm from './room.object-customize-form.vue';
import type { RoomControllerOptions } from '@/world/room/controller.js'; import type { RoomControllerOptions } from '@/world/room/controller.js';
import { definePage } from '@/page.js'; import { definePage } from '@/page.js';
@@ -275,6 +276,15 @@ const roomControllerOptions = computed<RoomControllerOptions>(() => ({
const controller = new RoomController(data, roomControllerOptions.value); const controller = new RoomController(data, roomControllerOptions.value);
onMounted(async () => { onMounted(async () => {
if (!await BABYLON.WebGPUEngine.IsSupportedAsync) {
os.alert({
type: 'warning',
title: i18n.ts._room.yourDeviceNotSupported_title,
text: i18n.ts._room.yourDeviceNotSupported_description,
});
return;
}
controller.init(canvas.value!); controller.init(canvas.value!);
canvas.value!.focus(); canvas.value!.focus();

View File

@@ -13291,5 +13291,13 @@ export interface Locale extends ILocale {
* 解像度 * 解像度
*/ */
"resolution": string; "resolution": string;
/**
* お使いのデバイスはMisskeyRoomをサポートしていません。
*/
"yourDeviceNotSupported_title": string;
/**
* MisskeyRoomを動作させるには、WebGPUをサポートするデバイスが必要です。
*/
"yourDeviceNotSupported_description": string;
}; };
} }