Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
GeoVistoogsi
AR
Commits
33017cb4
Commit
33017cb4
authored
2 months ago
by
Cantuerk
Browse files
Options
Download
Email Patches
Plain Diff
Update public/index.html, public/style.css
parent
98e90082
master
21caog1bif-master-patch-96693
1 merge request
!180
Update public/index.html, public/style.css
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
public/index.html
+21
-13
public/index.html
public/style.css
+3
-3
public/style.css
with
24 additions
and
16 deletions
+24
-16
public/index.html
+
21
-
13
View file @
33017cb4
...
...
@@ -308,6 +308,7 @@
function
highlightSelectedModel
()
{
if
(
selectedPlacedModel
)
{
removeHighlightFromAllModels
();
selectedPlacedModel
.
traverse
((
child
)
=>
{
if
(
child
.
isMesh
)
{
child
.
material
.
emissive
.
setHex
(
0xff0000
);
// Rote Hervorhebung
...
...
@@ -324,6 +325,14 @@
}
}
function
removeHighlightFromAllModels
()
{
scene
.
traverse
((
child
)
=>
{
if
(
child
.
isMesh
&&
child
.
material
&&
child
.
material
.
emissive
)
{
child
.
material
.
emissive
.
setHex
(
0x000000
);
// Markierung entfernen
}
});
}
function
deleteModel
()
{
if
(
!
selectedPlacedModel
)
{
console
.
log
(
"
Kein Modell ausgewählt. Bitte wählen Sie ein Modell aus, bevor Sie es löschen.
"
);
...
...
@@ -427,6 +436,7 @@
let
moveDelta
=
0.1
;
// Standardwert für die Verschiebungsgröße, kann mit dem Slider geändert werden
function
openMoveMenu
()
{
if
(
!
selectedPlacedModel
)
{
console
.
log
(
"
Kein Modell ausgewählt. Bitte wählen Sie ein Modell aus, bevor Sie es bewegen.
"
);
...
...
@@ -441,19 +451,16 @@
<div id="position-info">
<p>Aktuelle Position: X=
${
selectedPlacedModel
.
position
.
x
.
toFixed
(
2
)}
, Z=
${
selectedPlacedModel
.
position
.
z
.
toFixed
(
2
)}
</p>
</div>
<div>
<p>Verschiebungsgröße: <span id="move-delta-display">
${
moveDelta
.
toFixed
(
2
)}
</span></p>
<input type="range" min="0.01" max="1.0" step="0.01" value="
${
moveDelta
}
"
onchange="updateMoveDelta(this.value)">
</div>
<div style="display: flex; flex-direction: column; align-items: center; gap: 10px;">
<label>Verschiebungsgröße: <span id="move-delta-display">
${
moveDelta
.
toFixed
(
2
)}
</span></label>
<input type="range" min="0.01" max="1.0" step="0.01" value="
${
moveDelta
}
" onchange="updateMoveDelta(this.value)">
<div style="display: flex; flex-direction: column; align-items: center;">
<div>
<button onclick="moveModel
('x', -moveDelta
)">← X</button>
<button onclick="moveModel
('x', moveDelta
)">→ X</button>
<button onclick="moveModel
Dynamic('x', -1
)">← X</button>
<button onclick="moveModel
Dynamic('x', 1
)">→ X</button>
</div>
<div>
<button onclick="moveModel
('z', -moveDelta
)">- Z</button>
<button onclick="moveModel
('z', moveDelta
)">+ Z</button>
<button onclick="moveModel
Dynamic('z', -1
)">- Z</button>
<button onclick="moveModel
Dynamic('z', 1
)">+ Z</button>
</div>
</div>
<button onclick="closeDynamicMenu()">Zurück</button>
...
...
@@ -468,11 +475,12 @@
}
}
function
moveModel
(
axis
,
d
elta
)
{
function
moveModel
Dynamic
(
axis
,
d
irection
)
{
if
(
selectedPlacedModel
)
{
selectedPlacedModel
.
position
[
axis
]
+=
delta
;
// Bewegung durchführen
const
delta
=
direction
*
moveDelta
;
// Dynamischer Wert basierend auf Slider
selectedPlacedModel
.
position
[
axis
]
+=
delta
;
// Position
sanzeige im Dynamic-
Menü aktualisieren
// Position
im
Menü aktualisieren
const
positionInfo
=
document
.
getElementById
(
"
position-info
"
);
if
(
positionInfo
)
{
positionInfo
.
innerHTML
=
`
...
...
This diff is collapsed.
Click to expand it.
public/style.css
+
3
-
3
View file @
33017cb4
...
...
@@ -170,17 +170,17 @@ body {
#dynamic-menu
{
position
:
absolute
;
bottom
:
8
0px
;
bottom
:
9
0px
;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
justify-content
:
center
;
gap
:
2
0px
;
gap
:
1
0px
;
background
:
#1e1e1e
;
box-shadow
:
0
-2px
6px
rgba
(
0
,
0
,
0
,
0.8
);
color
:
white
;
width
:
100vw
;
height
:
2
0
0px
;
height
:
2
5
0px
;
z-index
:
20
;
overflow-y
:
auto
;
border-radius
:
8px
;
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets