Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ec7ae6c

Browse files
committed
example(ept): Allow navigation on the pointcloud
1 parent 36a0059 commit ec7ae6c

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

examples/entwine_simple_loader.html

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,15 @@
3131
<script src="js/GUI/LoadingScreen.js"></script>
3232
<script src="../dist/debug.js"></script>
3333
<script type="text/javascript">
34+
itowns.proj4.defs('EPSG:3946', '+proj=lcc +lat_0=46 +lon_0=3 +lat_1=45.25 +lat_2=46.75 +x_0=1700000 +y_0=5200000 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs +type=crs');
35+
3436
var debugGui = new dat.GUI();
3537
var viewerDiv = document.getElementById('viewerDiv');
3638
viewerDiv.style.display = 'block';
3739
var view = new itowns.View('EPSG:3946', viewerDiv);
3840
view.mainLoop.gfxEngine.renderer.setClearColor(0xcccccc);
3941

40-
var controls = new itowns.FirstPersonControls(view, { focusOnClick: true });
41-
debugGui.add(controls.options, 'moveSpeed', 1, 10000).name('Movement speed');
42+
const controls = new itowns.PlanarControls(view);
4243

4344
var eptLayer, eptSource;
4445

@@ -55,10 +56,7 @@
5556
view.camera3D.position.copy(position);
5657
view.camera3D.lookAt(lookAt);
5758

58-
controls.options.moveSpeed = size.length();
59-
6059
view.notifyChange(view.camera3D);
61-
controls.reset();
6260
}
6361

6462
function readEPTURL() {

0 commit comments

Comments
 (0)