P4: Lab: a background mission's $Environment Map is never used
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- Mezza giornata
- Idoneità per principianti
- 66/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- cpp
- Ambito
- computer-graphics, game-dev
Direzione di ricerca
Inizia in LabRenderer::useBackground, dove il $Environment Map della missione viene letto in envmap_name ma al suo posto viene caricato The_mission.envmap_name. Confronta con environment_map_gen in starfield.cpp, poi controlla il test ENVMAP > 1 che segue. Fatto quando una nave nel laboratorio assume i colori dell'environment map della missione di sfondo, corrispondenti alla missione. Per testare servono una missione cubemap e una build di debug OpenGL.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
This is minor: it only affects the F3 lab's preview, not missions.
Problem
When you pick a mission as the lab's background, the lab loads that mission's stars, suns and bitmaps but ignores its $Environment Map. Ships in the lab don't reflect the environment map the mission names, so the lab preview doesn't match what the ship looks like in that mission.
Steps to reproduce
- Current master (8afa31842), debug build, Linux, OpenGL, MediaVPs 5.0.2.
- Use a mission whose
$Environment Mapis a cubemap with obvious colors. I used a test mission with a 64x64 cubemap that has one bright color per face. - Open the lab (F3), show a GTC Fenris, then pick that mission under Mission Background.
- Compare with the same Fenris in that mission.
Expected vs. actual behavior
Expected: the Fenris in the lab picks up the environment map's colors, like it does in the mission.
Actual: the background loads (the stars appear), but the hull stays plain grey. In the mission, the same map tints the whole hull.
From reading the code: LabRenderer::useBackground reads the mission's $Environment Map into a local envmap_name, but then loads The_mission.envmap_name instead, which in the lab is empty or left over from the last mission played. So the background's map is never loaded. I haven't tested the case where the leftover name points at a flat (non-cubemap) texture; by reading, it could hit the same OpenGL crash as #2245.
Proposed fixes
- Load
envmap_name(the name just read) instead ofThe_mission.envmap_name, and change theENVMAP > 1check right after it to>= 0. - Same as 1, plus the cubemap check from #7930, so a flat texture falls back to the generated map in the lab too.
- Share one helper between the lab and
environment_map_genin starfield.cpp, so both load and check the mission's environment map the same way.
- Lingua principale
- C++
- Stelle
- 488
- Fork
- 184
- Merge medio
- 2g 2h
- PR unite (30g)
- 35
Preparare l'ambiente
Non abbiamo ancora controllato i file di configurazione di questo progetto. Parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di scp-fs2open/fs2open.github.com
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
scp-fs2open/fs2open.github.com#7953 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
scp-fs2open/fs2open.github.com#7946 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
scp-fs2open/fs2open.github.com#7924 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
scp-fs2open/fs2open.github.com#7918 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
scp-fs2open/fs2open.github.com#7917 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di scp-fs2open/fs2open.github.com
Issue simili
-
bug priority: low
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
chipsalliance/verible#2644 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
grafana/pyroscope-dotnet#470 ·
I maintainer di solito rispondono entro 1 giorno
-
documentation P5 XS
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
open-astro/AlpacaBridge#1848 ·
I maintainer di solito rispondono entro 1 giorno
-
DiskANN AnnIterator returns unconverted IP distances after the graph walk runs out of candidatesAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
zilliztech/knowhere#1933 ·
I maintainer di solito rispondono entro 1 giorno