@dt-api/cim-api
v1.2.0
Published
@dt-api/cim-api is a JavaScript plugin designed for DtApi, offering a comprehensive set of APIs that empower developers to seamlessly integrate @dt-api/cim-api into their applications.
Downloads
5
Readme
Introduction
@dt-api/cim-api is a JavaScript plugin designed for DtApi, offering a comprehensive set of APIs that empower developers to seamlessly integrate @dt-api/cim-api into their applications.
Install
$ npm i dtapi
$ npm i @dt-api/cim-api
Important
import DtApi from 'dtapi';
import CimApi from '@dt-api/cim-api';
Instantiation
const config = {
id: 'player', //Render scene container(DOM node id)
url: 'https://service.com/Renderers/Any/order', //Rendering service address
order: 'c6526f3f154663431cd29577e3532aa4', //Rendering order, obtained on the rendering client
resolution: [3840, 2160], //Set the rendering output resolution[width, height]
debugMode: 'normal', //none, normal, high
keyboard: { //[optional] keyboard event
normal: false, //Keyboard event, exclude F1~F12 [default disabled]
func: false, //Browser F1 ~ F12 function keys [default disabled]
},
};
const App = new DtApi(config);
const { result } = await App.Plugin.Install(CimApi);
console.log(result.id)
await App.Plugin.Uninstall(result.id);
License
Copyright (c) 2023-present