Fix: VLM-Suche standardmaessig weltweit statt Viewport-BBox

Wenn man nicht weiss wo ein Bild aufgenommen wurde, macht eine
Viewport-Einschraenkung keinen Sinn. BBox ist jetzt optional per
Checkbox "Nur im sichtbaren Bereich suchen".

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Dieser Commit ist enthalten in:
Claude Dev
2026-03-26 00:13:04 +01:00
Ursprung 7be5edd983
Commit 72bae57519

Datei anzeigen

@@ -54,7 +54,11 @@ const VlmUI = {
'<div id="vlm-scene" style="font-size:12px;color:var(--text);margin-bottom:10px;line-height:1.5"></div>' + '<div id="vlm-scene" style="font-size:12px;color:var(--text);margin-bottom:10px;line-height:1.5"></div>' +
'<div style="font-size:9px;letter-spacing:1.5px;color:var(--accent);margin-bottom:6px">ERKANNTE OBJEKTE</div>' + '<div style="font-size:9px;letter-spacing:1.5px;color:var(--accent);margin-bottom:6px">ERKANNTE OBJEKTE</div>' +
'<div id="vlm-objects"></div>' + '<div id="vlm-objects"></div>' +
'<button class="overpass-exec-btn" id="vlm-search-btn" onclick="VlmUI._confirmAndSearch()" style="margin-top:10px">AUF GLOBE SUCHEN</button>' + '<label style="display:flex;align-items:center;gap:6px;font-size:11px;color:var(--text-dim);margin-top:8px;cursor:pointer">' +
'<input type="checkbox" id="vlm-use-bbox" style="accent-color:var(--accent);width:14px;height:14px">' +
'Nur im sichtbaren Bereich suchen' +
'</label>' +
'<button class="overpass-exec-btn" id="vlm-search-btn" onclick="VlmUI._confirmAndSearch()" style="margin-top:8px">AUF GLOBE SUCHEN</button>' +
'<div id="vlm-search-result" style="margin-top:8px;font-size:11px;color:var(--text-dim);display:none"></div>' + '<div id="vlm-search-result" style="margin-top:8px;font-size:11px;color:var(--text-dim);display:none"></div>' +
'</div>' + '</div>' +
// Reset // Reset
@@ -243,9 +247,10 @@ const VlmUI = {
return; return;
} }
// BBox vom Viewport // BBox: Standard weltweit (null), optional auf Viewport einschraenken
var bbox = null; var bbox = null;
if (Globe.viewer) { var bboxCb = document.getElementById('vlm-use-bbox');
if (bboxCb && bboxCb.checked && Globe.viewer) {
var rect = Globe.viewer.camera.computeViewRectangle(); var rect = Globe.viewer.camera.computeViewRectangle();
if (rect) { if (rect) {
bbox = [ bbox = [