architwin 1.0.87 → 1.0.89
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -1
- package/lib/architwin.d.ts +3 -2
- package/lib/architwin.js +1 -1
- package/lib/atwinui/components/toolbar/i18n.js +8 -2
- package/lib/atwinui/components/toolbar/index.d.ts +2 -1
- package/lib/atwinui/components/toolbar/index.js +8 -2
- package/lib/atwinui/components/toolbar/modal.d.ts +4 -0
- package/lib/atwinui/components/toolbar/modal.js +68 -0
- package/lib/atwinui/components/toolbar/modelControlsPane.d.ts +7 -1
- package/lib/atwinui/components/toolbar/modelControlsPane.js +140 -6
- package/lib/atwinui/components/toolbar/tagListPane.js +20 -14
- package/lib/atwinui/components/toolbar/tagMessagingPane.js +1 -1
- package/lib/atwinui/events.js +31 -1
- package/lib/loaders/planeGeometry2.js +21 -4
- package/lib/types.d.ts +7 -0
- package/lib/utils.d.ts +1 -0
- package/lib/utils.js +3 -0
- package/package.json +1 -1
- package/static/atwinui.css +130 -10
- package/static/utility.css +36 -0
package/README.md
CHANGED
|
@@ -311,6 +311,8 @@ Or programmatically using methods defined in this library.
|
|
|
311
311
|
|
|
312
312
|
## Executing methods on specific App Phases
|
|
313
313
|
|
|
314
|
+
**WARNING:** This feature is deprecated, subscribe using [Space Events](#subscribing-to-space-events) instead
|
|
315
|
+
|
|
314
316
|
Your application may need to execute certain methods during the initialization of your 3D space. For example, you may want to use`addObjectToSpace()` method to render a model to your 3D space the moment the 3D space becomes interactive. While you can always just invoke the function after the `connectSpace()` method there may be times where this will cause an error as the `connectSpace()` method which is an async method, may have not finished initializing the necessary internal variables that allow other methods to work properly. When you invoke the `connectSpace()` method, the library does some internal validation and then goes to several phases to render your 3D space and make it interactive. These phases are the following:
|
|
315
317
|
|
|
316
318
|
**ARCHTWIN APP PHASES**
|
|
@@ -323,7 +325,7 @@ You can also view the technical diagram of how this work below:
|
|
|
323
325
|
|
|
324
326
|
<img src="https://drive.google.com/uc?id=1I_NuuI_PWkRzB0DueCmBCBH-1V_upiOB" width="400" height="300" />
|
|
325
327
|
|
|
326
|
-
To invoke a function from your application during one of the phases.
|
|
328
|
+
To invoke a function from your application during one of the phases. Simply pass the function name as a parameter in the `connectSpace()` method. Make sure to not add a parenthesis to your function name when you pass it as a parameter to avoid invoking the function prematurely.
|
|
327
329
|
|
|
328
330
|
*Example:*
|
|
329
331
|
|
|
@@ -1875,6 +1877,20 @@ atwin.setVideoPlayback('play', randomMediaScreen.component.planeElement)
|
|
|
1875
1877
|
|
|
1876
1878
|
You can use the [transform controls](#transforming-objects) to change the position, scale, and rotation of the media screen using the mouse cursor.
|
|
1877
1879
|
|
|
1880
|
+
#### Hiding expand/dock buttons of Media Screens
|
|
1881
|
+
|
|
1882
|
+
Media screens by default will display a dock button on each corner of the displayed media that allows you to dock the media screen in the 4 corners of your FOV inside a space. To hide these buttons, you may add the following in your config object.
|
|
1883
|
+
|
|
1884
|
+
```typescript
|
|
1885
|
+
const config = {
|
|
1886
|
+
//other configs
|
|
1887
|
+
mediaScreenConfig: {
|
|
1888
|
+
showExpandButton: false
|
|
1889
|
+
}
|
|
1890
|
+
}
|
|
1891
|
+
|
|
1892
|
+
```
|
|
1893
|
+
|
|
1878
1894
|
### Setting Video Playback in the Space
|
|
1879
1895
|
|
|
1880
1896
|
Setting video playback refers to the act of adjusting various controls associated with the playback of a video in the space. It involves manipulating controls such as pause, play, mute, and unmute to modify the playback behavior according to user's preferences.
|
package/lib/architwin.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AxiosInstance } from "axios";
|
|
2
2
|
import { MpSdk, Scene, Vector3, Vector2, Renderer } from "../bundle/sdk";
|
|
3
3
|
import { initToolbarUI } from "./atwinui";
|
|
4
|
-
import { type ITag, type IUser, type ISpace, type IShowcaseObject, type I3DObject, type IMPConfig, type ISweep, type ITagPublic, type NearbyPayload, type NearbyObjects, type IObjectData, TRANSFORM_TYPE, Object3DPosition, State, FileUpload, ObjectConfig, IAtwinFloor, IAtwinLabel, SPACE_EVENTS, SpaceAvatar, IMapConfig, MEETING_SIDEBAR, IO_ROLE, IO_SPACE_EVENTS, IO_MEETING_EVENTS, SCREEN_POSITIONS, ITagCategory, TagMessage } from "./types";
|
|
4
|
+
import { type ITag, type IUser, type ISpace, type IShowcaseObject, type I3DObject, type IMPConfig, type ISweep, type ITagPublic, type NearbyPayload, type NearbyObjects, type IObjectData, TRANSFORM_TYPE, Object3DPosition, ObjectCoordinates, EulerCoordinates, State, FileUpload, ObjectConfig, IAtwinFloor, IAtwinLabel, SPACE_EVENTS, SpaceAvatar, IMapConfig, MEETING_SIDEBAR, IO_ROLE, IO_SPACE_EVENTS, IO_MEETING_EVENTS, SCREEN_POSITIONS, ITagCategory, TagMessage } from "./types";
|
|
5
5
|
import '../static/sidebar.css';
|
|
6
6
|
import '../static/map.css';
|
|
7
7
|
import '../static/media_screen.css';
|
|
@@ -138,6 +138,7 @@ declare function revertTransform(action?: string): boolean;
|
|
|
138
138
|
* @returns {void}
|
|
139
139
|
*/
|
|
140
140
|
declare function clearActionHistory(): void;
|
|
141
|
+
declare function convertToEuler(coords: EulerCoordinates): ObjectCoordinates;
|
|
141
142
|
/**
|
|
142
143
|
*
|
|
143
144
|
* @param node The node of the object
|
|
@@ -472,4 +473,4 @@ declare function getMediaScreenHUDs(): {
|
|
|
472
473
|
declare function getParticipants(): Promise<import("./types").IO_Participant[]>;
|
|
473
474
|
declare function followParticipant(followParticipant: any): void;
|
|
474
475
|
declare function unFollowParticipant(unFollowParticipant: any): void;
|
|
475
|
-
export { _atwin, _config, _mpConfig, tags, sweeps, selectedObject, previousObjTransform, currentObjTransform, actionHistory, state, _tags, _tagCategories, _tagMessageRecepients, _space, _spaceId, _api, _pointerCoord, _3DXObjects, _meetingParticipants, _generatedObjectIds, tagColors, domMousePosition, isFitScreenOccupied, initAtwinApi, getAtwinSdk, connectSpace, disconnectSpace, captureSpaceScreenshot, clearActionHistory, getSweeps, getCurrentSweep, getCurrentSweepPosition, moveToSweep, getNearbySweeps, getAllSweeps, getCurrentCameraPose, getCameraPosition, moveInDirection, cameraLookAt, cameraPan, cameraRotate, getViewMode, setViewMode, getNearbyObjects, setTransformMode, setSelectedObject, clearSelectedObject, revertTransform, setTransformControls, removeTransformControls, setRenderDistance, addObject, getObject, addObjectToSpace, addMediaScreen, attachMediaScreenContent, updateObject, updateShowcaseObject, deleteObject, deleteShowcaseObject, deleteObjectFromSpace, deleteMediaScreen, getShowcaseObject, setBasePointPosition, showObjectDimensions, hideObjectDimensions, copyObject, replaceObject, getTargetPosition, setObjectTransformation, setPointerCoordinates, addTextMarkupScreen, setTextMarkupScreenContent, goTo3dx, goToModel, hasTimeElapsed, getSelectedObject, renderAvatar, setSpaceAvatar, get3DXObjects, setLibrary, getLibrary, disposeModel, renderInSpaceMediaScreen, goToPosition, goToParticipant, getNearestSweepFromObject, pauseVideo, playVideo, setVideoPlayback, setAnimationState, showMinimap, hideMinimap, getMapConfig, addTag, getTags, gotoTag, renderTag, disposeTag, disposeTags, getMpTags, getMpTag, showTags, attachTagMedia, detachTagMedia, moveTag, editTagLabel, editTagDescription, editTagStem, editTagIcon, editTagColor, saveTag, rotateCameraToObject, setModelVisibility, tagStateSubscriber, setTagIcon, setTagCategories, setUserAssignedCategories, getUserAssignedCategories, setTagMessageRecepients, getTagMessageRecepients, setTagMessages, getTagMessages, setSelectedTagUuid, getSelectedTagUuid, getFloors, getLabels, renderMeetingSidebar, createMeetingTemplate, joinMeetingTemplate, dispatchSpaceEvent, subscribeSpaceEvent, unsubscribeSpaceEvent, registerCustomSpaceEvent, isMeetingInitialized, getMeetingParticipants, createMeeting, startMeeting, stopMeeting, generateMeetingURL, updateMeetingTitle, updateMeetingStart, updateMeetingStatus, updateMeetingSpace, getMeeting, getSpaceMeetings, isMeetingExists, isMeetingActive, initSocketIo, socketEmit, getParticipants, followParticipant, unFollowParticipant, enableHUD, disableHUD, getMediaScreenHUDs, canSetHud, saveMediaScreenHud, removeMediaScreenHud, enableFitScreen, disableFitScreen, initToolbarUI, };
|
|
476
|
+
export { _atwin, _config, _mpConfig, tags, sweeps, selectedObject, previousObjTransform, currentObjTransform, actionHistory, state, _tags, _tagCategories, _tagMessageRecepients, _space, _spaceId, _api, _pointerCoord, _3DXObjects, _meetingParticipants, _generatedObjectIds, tagColors, domMousePosition, isFitScreenOccupied, initAtwinApi, getAtwinSdk, connectSpace, disconnectSpace, captureSpaceScreenshot, clearActionHistory, getSweeps, getCurrentSweep, getCurrentSweepPosition, moveToSweep, getNearbySweeps, getAllSweeps, getCurrentCameraPose, getCameraPosition, moveInDirection, cameraLookAt, cameraPan, cameraRotate, getViewMode, setViewMode, getNearbyObjects, setTransformMode, setSelectedObject, clearSelectedObject, revertTransform, setTransformControls, removeTransformControls, setRenderDistance, addObject, getObject, addObjectToSpace, addMediaScreen, attachMediaScreenContent, updateObject, updateShowcaseObject, deleteObject, deleteShowcaseObject, deleteObjectFromSpace, deleteMediaScreen, getShowcaseObject, setBasePointPosition, showObjectDimensions, hideObjectDimensions, copyObject, replaceObject, getTargetPosition, setObjectTransformation, setPointerCoordinates, addTextMarkupScreen, setTextMarkupScreenContent, goTo3dx, goToModel, hasTimeElapsed, getSelectedObject, renderAvatar, setSpaceAvatar, get3DXObjects, setLibrary, getLibrary, disposeModel, renderInSpaceMediaScreen, goToPosition, goToParticipant, getNearestSweepFromObject, pauseVideo, playVideo, setVideoPlayback, setAnimationState, showMinimap, hideMinimap, getMapConfig, addTag, getTags, gotoTag, renderTag, disposeTag, disposeTags, getMpTags, getMpTag, showTags, attachTagMedia, detachTagMedia, moveTag, editTagLabel, editTagDescription, editTagStem, editTagIcon, editTagColor, saveTag, rotateCameraToObject, setModelVisibility, tagStateSubscriber, setTagIcon, setTagCategories, setUserAssignedCategories, getUserAssignedCategories, setTagMessageRecepients, getTagMessageRecepients, setTagMessages, getTagMessages, setSelectedTagUuid, getSelectedTagUuid, getFloors, getLabels, renderMeetingSidebar, createMeetingTemplate, joinMeetingTemplate, dispatchSpaceEvent, subscribeSpaceEvent, unsubscribeSpaceEvent, registerCustomSpaceEvent, isMeetingInitialized, getMeetingParticipants, createMeeting, startMeeting, stopMeeting, generateMeetingURL, updateMeetingTitle, updateMeetingStart, updateMeetingStatus, updateMeetingSpace, getMeeting, getSpaceMeetings, isMeetingExists, isMeetingActive, initSocketIo, socketEmit, getParticipants, followParticipant, unFollowParticipant, enableHUD, disableHUD, getMediaScreenHUDs, canSetHud, saveMediaScreenHud, removeMediaScreenHud, enableFitScreen, disableFitScreen, initToolbarUI, convertToEuler };
|