Skip to content
This repository has been archived by the owner on Jun 10, 2024. It is now read-only.

fix camera tiles #410

Merged
merged 7 commits into from
Mar 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion dist/3dstreet-editor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/3dstreet-editor.js.map

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,16 @@
<script src="https://aframe.io/releases/1.5.0/aframe.min.js"></script>

<!-- 3dstreet -->
<script src="https://cdn.jsdelivr.net/npm/[email protected].11/dist/aframe-street-component.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected].12/dist/aframe-street-component.min.js"></script>

<!-- user controls - vr teleport -->

<!-- mapbox -->
<script src="https://github.3dstreet.org/src/lib/aframe-mapbox-component.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/3dstreet@0.4.12/src/lib/aframe-mapbox-component.min.js"></script>

<!-- 3d tiles -->
<script src="./src/lib/aframe-loader-3dtiles-component.min.js"></script>

<title>3DStreet</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="icon" type="image/x-icon" href="./assets/favicon.ico" />
Expand Down
6 changes: 6 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,12 @@ Inspector.prototype = {
this.sceneEl.resize();
Shortcuts.disable();
document.activeElement.blur();

// quick solution to change 3d tiles camera
const tilesElem = document.querySelector('a-entity[loader-3dtiles]');
if (tilesElem) {
tilesElem.emit('cameraChange', AFRAME.scenes[0].camera);
}
}
};

Expand Down
Loading