improve annotations
This commit is contained in:
parent
d8725bf815
commit
4fe8451677
2
.vscode/settings.json
vendored
2
.vscode/settings.json
vendored
@ -5,7 +5,7 @@
|
||||
"*.fs": "cpp"
|
||||
},
|
||||
"files.trimTrailingWhitespace": false,
|
||||
"editor.fontSize": 18,
|
||||
"editor.fontSize": 16,
|
||||
"editor.autoIndent": false,
|
||||
"editor.detectIndentation": false,
|
||||
"editor.renderWhitespace": "all",
|
||||
|
||||
@ -13,6 +13,7 @@ Potree.Annotation = class extends THREE.EventDispatcher {
|
||||
this.scene = null;
|
||||
this._title = args.title || 'No Title';
|
||||
this._description = args.description || '';
|
||||
this.offset = new THREE.Vector3();
|
||||
|
||||
if (!args.position) {
|
||||
this.position = null;
|
||||
|
||||
@ -201,7 +201,7 @@ a:hover, a:visited, a:link, a:active{
|
||||
margin: auto;
|
||||
display: table;
|
||||
padding: 1px 8px;
|
||||
cursor: pointer;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.annotation-expand{
|
||||
|
||||
@ -1013,7 +1013,8 @@ Potree.Viewer = class PotreeViewer extends THREE.EventDispatcher{
|
||||
|
||||
let element = annotation.domElement;
|
||||
|
||||
let position = annotation.position;
|
||||
let position = annotation.position.clone();
|
||||
position.add(annotation.offset);
|
||||
if (!position) {
|
||||
position = annotation.boundingBox.getCenter();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user