mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-05 19:19:39 -06:00
Merge branch 'feature/osirisrex' of github.com:OpenSpace/OpenSpace into feature/osirisrex
This commit is contained in:
@@ -369,13 +369,7 @@ void SyncWidget::syncButtonPressed() {
|
||||
LERROR("Could not find 'Modules'");
|
||||
return;
|
||||
}
|
||||
|
||||
struct ModuleInformation {
|
||||
QString moduleName;
|
||||
QString moduleDatafile;
|
||||
QString modulePath;
|
||||
};
|
||||
|
||||
|
||||
QDir sceneDir(scene);
|
||||
sceneDir.cdUp();
|
||||
QList<ModuleInformation> modulesList;
|
||||
@@ -527,7 +521,7 @@ void SyncWidget::syncButtonPressed() {
|
||||
//// Make the lists unique
|
||||
{
|
||||
auto equal = [](const DirectFile& lhs, const DirectFile& rhs) -> bool {
|
||||
return lhs.module == rhs.module && lhs.url == rhs.url && lhs.destination == rhs.destination;
|
||||
return lhs.module == rhs.module && lhs.url == rhs.url && lhs.destination == rhs.destination && lhs.baseDir == rhs.baseDir;
|
||||
};
|
||||
|
||||
QList<DirectFile> files;
|
||||
@@ -552,6 +546,7 @@ void SyncWidget::syncButtonPressed() {
|
||||
lhs.module == rhs.module &&
|
||||
lhs.identifier == rhs.identifier &&
|
||||
lhs.destination == rhs.destination &&
|
||||
lhs.baseDir == rhs.baseDir &&
|
||||
lhs.version == rhs.version;
|
||||
};
|
||||
|
||||
@@ -576,7 +571,8 @@ void SyncWidget::syncButtonPressed() {
|
||||
return
|
||||
lhs.module == rhs.module &&
|
||||
lhs.file == rhs.file &&
|
||||
lhs.destination == rhs.destination;
|
||||
lhs.destination == rhs.destination &&
|
||||
lhs.baseDir == rhs.baseDir;
|
||||
};
|
||||
|
||||
QList<TorrentFile> files;
|
||||
|
||||
@@ -83,6 +83,13 @@ private:
|
||||
QString baseDir;
|
||||
};
|
||||
|
||||
|
||||
struct ModuleInformation {
|
||||
QString moduleName;
|
||||
QString moduleDatafile;
|
||||
QString modulePath;
|
||||
};
|
||||
|
||||
void clear();
|
||||
QStringList selectedScenes() const;
|
||||
|
||||
|
||||
@@ -11,10 +11,6 @@ return {
|
||||
Instrument = "NH_LORRI",
|
||||
Moving = false,
|
||||
Texture = "textures/test.jpg",
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 1}
|
||||
},
|
||||
},
|
||||
-- LORRI FoV square
|
||||
@@ -30,10 +26,6 @@ return {
|
||||
Moving = true,
|
||||
Texture = "textures/squarefov.png",
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 1}
|
||||
},
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -36,6 +36,7 @@ return {
|
||||
"JUPITER", "IO", "EUROPA", "GANYMEDE", "CALLISTO"
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "CALLISTO",
|
||||
@@ -50,6 +51,23 @@ return {
|
||||
Frame = "IAU_CALLISTO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "CALLISTO",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "JUPITER BARYCENTER",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp"
|
||||
}
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_CALLISTO",
|
||||
DestinationFrame = "ECLIPJ2000",
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Jupiter"
|
||||
},
|
||||
{
|
||||
@@ -62,10 +80,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Callisto-Text.png"
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -1, 0, 7}
|
||||
}
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -10000000, 0}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- CallistoTrail module
|
||||
{
|
||||
|
||||
@@ -36,6 +36,7 @@ return {
|
||||
"JUPITER", "IO", "EUROPA", "GANYMEDE", "CALLISTO"
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "EUROPA",
|
||||
@@ -50,6 +51,23 @@ return {
|
||||
Frame = "IAU_EUROPA",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "EUROPA",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "JUPITER BARYCENTER",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp"
|
||||
}
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_EUROPA",
|
||||
DestinationFrame = "ECLIPJ2000",
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Jupiter"
|
||||
},
|
||||
{
|
||||
@@ -62,10 +80,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Europa-Text.png"
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -1, 0, 7}
|
||||
}
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -10000000, 0}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- EuropaTrail module
|
||||
{
|
||||
|
||||
@@ -36,6 +36,23 @@ return {
|
||||
"JUPITER", "IO", "EUROPA", "GANYMEDE", "CALLISTO"
|
||||
}
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "GANYMEDE",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "JUPITER BARYCENTER",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp"
|
||||
}
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_GANYMEDE",
|
||||
DestinationFrame = "ECLIPJ2000",
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "GANYMEDE",
|
||||
@@ -50,6 +67,7 @@ return {
|
||||
Frame = "IAU_GANYMEDE",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
GuiName = "/Solar/Planets/Jupiter"
|
||||
},
|
||||
{
|
||||
@@ -66,6 +84,12 @@ return {
|
||||
Type = "Static",
|
||||
Position = {0, -1, 0, 7}
|
||||
}
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -10000000, 0}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- GanymedeTrail module
|
||||
{
|
||||
|
||||
@@ -36,6 +36,23 @@ return {
|
||||
"JUPITER", "IO", "EUROPA", "GANYMEDE", "CALLISTO"
|
||||
}
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "IO",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "JUPITER BARYCENTER",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp"
|
||||
}
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_IO",
|
||||
DestinationFrame = "ECLIPJ2000",
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "IO",
|
||||
@@ -50,6 +67,7 @@ return {
|
||||
Frame = "IAU_IO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
GuiName = "/Solar/Planets/Jupiter"
|
||||
},
|
||||
{
|
||||
@@ -62,10 +80,12 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Io-Text.png"
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -1, 0, 7}
|
||||
}
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -10000000, 0}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- IoTrail module
|
||||
{
|
||||
|
||||
@@ -2,15 +2,17 @@ return {
|
||||
-- Jupiter barycenter module
|
||||
{
|
||||
Name = "JupiterBarycenter",
|
||||
Parent = "SolarSystemBarycenter",
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "JUPITER BARYCENTER",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "SUN",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp",
|
||||
}
|
||||
Parent = "SolarSystemBarycenter",
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "JUPITER BARYCENTER",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "SUN",
|
||||
Kernels = {
|
||||
"${OPENSPACE_DATA}/spice/de430_1850-2150.bsp"
|
||||
}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- JupiterProjection module
|
||||
@@ -87,14 +89,12 @@ return {
|
||||
"JUPITER", "IO", "EUROPA", "GANYMEDE", "CALLISTO"
|
||||
}
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static"
|
||||
},
|
||||
|
||||
Rotation = {
|
||||
Type = "Spice",
|
||||
Frame = "IAU_JUPITER",
|
||||
Reference = "GALACTIC"
|
||||
Transform = {
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_JUPITER",
|
||||
DestinationFrame = "GALACTIC",
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Jupiter"
|
||||
},
|
||||
@@ -108,10 +108,12 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Jupiter-text.png"
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -1, 0, 8}
|
||||
}
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -100000000, 0}
|
||||
},
|
||||
},
|
||||
},
|
||||
-- JupiterTrail module
|
||||
{
|
||||
|
||||
@@ -96,16 +96,13 @@ return {
|
||||
Type = "simple",
|
||||
Color = "textures/NHTexture.jpg",
|
||||
},
|
||||
Rotation = {
|
||||
Source = "NH_SPACECRAFT",
|
||||
Destination = "GALACTIC"
|
||||
},
|
||||
Shading = {
|
||||
PerformShading = true,
|
||||
Fadeable = false,
|
||||
Ghosting = false,
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "NEW HORIZONS",
|
||||
@@ -116,6 +113,21 @@ return {
|
||||
-- Observer = "JUPITER BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "NEW HORIZONS",
|
||||
Reference = "GALACTIC",
|
||||
Observer = "SUN",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "NH_SPACECRAFT",
|
||||
DestinationFrame = "GALACTIC",
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/NewHorizons"
|
||||
},
|
||||
--NewHorizonsTrail module
|
||||
@@ -169,9 +181,6 @@ return {
|
||||
Ghosting = false,
|
||||
},
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
},
|
||||
GuiName = "/Solar/NewHorizons"
|
||||
},
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -33,7 +33,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -61,7 +61,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -88,7 +88,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -116,7 +116,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -144,7 +144,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -171,7 +171,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -198,7 +198,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -225,7 +225,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -252,7 +252,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
@@ -279,7 +279,7 @@ return {
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "NEW HORIZONS",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "NH_SPACECRAFT",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
return {
|
||||
FileRequest = {
|
||||
{ Identifier = "charon_textures", Destination = "textures", Version = 1 }
|
||||
{ Identifier = "charon_textures", Destination = "textures", Version = 2 }
|
||||
},
|
||||
}
|
||||
@@ -55,6 +55,7 @@ return {
|
||||
"CHARON"
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "CHARON",
|
||||
@@ -67,6 +68,21 @@ return {
|
||||
Frame = "IAU_CHARON",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "CHARON",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_CHARON",
|
||||
DestinationFrame = "ECLIPJ2000"
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Charon"
|
||||
},
|
||||
{
|
||||
@@ -79,10 +95,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Charon-Text.png"
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -1000000, 0}
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -10, 0, 5}
|
||||
}
|
||||
]]
|
||||
},
|
||||
{
|
||||
Name = "CharonShadow",
|
||||
@@ -97,10 +121,6 @@ return {
|
||||
MainFrame = "GALACTIC",
|
||||
Aberration = "NONE",
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 5}
|
||||
}
|
||||
},
|
||||
-- CharonTrail module
|
||||
{
|
||||
|
||||
@@ -27,6 +27,7 @@ return {
|
||||
Color = "textures/gray.jpg",
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "Hydra",
|
||||
@@ -39,6 +40,21 @@ return {
|
||||
Frame = "IAU_PLUTO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "HYDRA",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_PLUTO",
|
||||
DestinationFrame = "ECLIPJ2000"
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Hydra"
|
||||
},
|
||||
{
|
||||
@@ -51,10 +67,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Hydra-Text.png"
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {1000000, 0, 1000000},
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {1, 0, 1, 6}
|
||||
}
|
||||
]]
|
||||
},
|
||||
-- HydraTrail module
|
||||
{
|
||||
|
||||
@@ -27,6 +27,7 @@ return {
|
||||
Color = "textures/gray.jpg",
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "KERBEROS",
|
||||
@@ -39,6 +40,21 @@ return {
|
||||
Frame = "IAU_PLUTO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "KERBEROS",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_PLUTO",
|
||||
DestinationFrame = "ECLIPJ2000"
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Kerberos"
|
||||
},
|
||||
{
|
||||
@@ -51,10 +67,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Kerberos-Text.png"
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {1, 0, 1, 6}
|
||||
}
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {1000000, 0, 1000000},
|
||||
},
|
||||
},
|
||||
},
|
||||
-- StyxTrail module
|
||||
{
|
||||
|
||||
@@ -27,6 +27,21 @@ return {
|
||||
Color = "textures/gray.jpg",
|
||||
}
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "NIX",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_PLUTO",
|
||||
DestinationFrame = "ECLIPJ2000"
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "NIX",
|
||||
@@ -39,6 +54,7 @@ return {
|
||||
Frame = "IAU_PLUTO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
GuiName = "/Solar/Planets/Nix"
|
||||
},
|
||||
{
|
||||
@@ -51,10 +67,12 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Nix-Text.png"
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 0}
|
||||
}
|
||||
]]
|
||||
},
|
||||
-- StyxTrail module
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
return {
|
||||
FileRequest = {
|
||||
{ Identifier = "newhorizons_plutoencounter_pluto_assets", Destination = "assets", Version = 1 },
|
||||
{ Identifier = "newhorizons_plutoencounter_pluto_textures", Destination = "textures", Version = 3 },
|
||||
{ Identifier = "pluto_textures", Destination = "textures", Version = 2 },
|
||||
{ Identifier = "newhorizons_plutoencounter_pluto_textures", Destination = "textures", Version = 4 },
|
||||
{ Identifier = "pluto_textures", Destination = "textures", Version = 4 },
|
||||
{ Identifier = "newhorizons_plutoencounter_pluto_images", Destination = "images", Version = 1 }
|
||||
},
|
||||
}
|
||||
@@ -21,6 +21,7 @@ return {
|
||||
{
|
||||
Name = "PlutoBarycenter",
|
||||
Parent = "SolarSystemBarycenter",
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "PLUTO BARYCENTER",
|
||||
@@ -28,6 +29,16 @@ return {
|
||||
Observer = "SUN",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "PLUTO BARYCENTER",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "SUN",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
},
|
||||
},
|
||||
-- PlutoProjection module
|
||||
{
|
||||
@@ -153,6 +164,7 @@ return {
|
||||
"P4",
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "PLUTO",
|
||||
@@ -165,6 +177,21 @@ return {
|
||||
Frame = "IAU_PLUTO",
|
||||
Reference = "GALACTIC"
|
||||
},
|
||||
]]
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "PLUTO",
|
||||
Reference = "GALACTIC",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_PLUTO",
|
||||
DestinationFrame = "GALACTIC",
|
||||
}
|
||||
},
|
||||
GuiName = "/Solar/Planets/Pluto"
|
||||
},
|
||||
{
|
||||
@@ -181,10 +208,12 @@ return {
|
||||
MieColor = {1.0, 1.0, 1.0}
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 1}
|
||||
},
|
||||
]]
|
||||
},
|
||||
{
|
||||
Name = "PlutoText",
|
||||
@@ -196,10 +225,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Pluto-Text.png"
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -2000000, 0}
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, -20, 0, 5}
|
||||
}
|
||||
]]
|
||||
},
|
||||
{
|
||||
Name = "PlutoTexture",
|
||||
@@ -212,10 +249,18 @@ return {
|
||||
ProjectionListener = false,
|
||||
Texture = "textures/Pluto-Text.png"
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {0, -4000000, 0}
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 40, 5}
|
||||
}
|
||||
]]
|
||||
},
|
||||
{
|
||||
Name = "PlutoShadow",
|
||||
@@ -230,10 +275,6 @@ return {
|
||||
MainFrame = "GALACTIC",
|
||||
Aberration = "NONE",
|
||||
},
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {0, 0, 0, 5}
|
||||
}
|
||||
},
|
||||
-- PlutoBarycentricTrail module
|
||||
{
|
||||
|
||||
@@ -27,6 +27,7 @@ return {
|
||||
Color = "textures/gray.jpg",
|
||||
}
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Spice",
|
||||
Body = "STYX",
|
||||
@@ -39,6 +40,22 @@ return {
|
||||
Frame = "IAU_PLUTO",
|
||||
Reference = "ECLIPJ2000"
|
||||
},
|
||||
]]
|
||||
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "SpiceEphemeris",
|
||||
Body = "STYX",
|
||||
Reference = "ECLIPJ2000",
|
||||
Observer = "PLUTO BARYCENTER",
|
||||
Kernels = NewHorizonsKernels
|
||||
},
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "IAU_PLUTO",
|
||||
DestinationFrame = "ECLIPJ2000"
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Planets/Styx"
|
||||
},
|
||||
{
|
||||
@@ -51,10 +68,18 @@ return {
|
||||
Billboard = true,
|
||||
Texture = "textures/Styx-Text.png"
|
||||
},
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
Position = {1000000, 0, 1000000}
|
||||
},
|
||||
},
|
||||
--[[
|
||||
Ephemeris = {
|
||||
Type = "Static",
|
||||
Position = {1, 0, 1, 6}
|
||||
}
|
||||
]]
|
||||
},
|
||||
-- StyxTrail module
|
||||
{
|
||||
|
||||
@@ -37,14 +37,9 @@ return {
|
||||
SourceFrame = "ORX_SPACECRAFT",
|
||||
DestinationFrame = "GALACTIC",
|
||||
},
|
||||
Scale = {
|
||||
Type = "StaticScale",
|
||||
Scale = 1,
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/OsirisRex"
|
||||
},
|
||||
|
||||
{
|
||||
Name = "ORX_OCAMS_POLYCAM",
|
||||
Parent = "OsirisRex",
|
||||
@@ -66,7 +61,6 @@ return {
|
||||
Ghosting = false,
|
||||
},
|
||||
},
|
||||
|
||||
Transform = {
|
||||
Translation = {
|
||||
Type = "StaticEphemeris",
|
||||
@@ -77,10 +71,6 @@ return {
|
||||
SourceFrame = "ORX_OCAMS_POLYCAM",
|
||||
DestinationFrame = "ORX_SPACECRAFT",
|
||||
},
|
||||
Scale = {
|
||||
Type = "StaticScale",
|
||||
Scale = 1,
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/ORX_OCAMS_POLYCAM"
|
||||
},
|
||||
@@ -115,12 +105,7 @@ return {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "ORX_REXIS",
|
||||
DestinationFrame = "ORX_SPACECRAFT",
|
||||
},
|
||||
Scale = {
|
||||
Type = "StaticScale",
|
||||
Scale = 1,
|
||||
},
|
||||
},
|
||||
}, },
|
||||
|
||||
GuiName = "/Solar/ORX_REXIS"
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
return {
|
||||
FileRequest = {
|
||||
{ Identifier = "charon_textures", Destination = "textures", Version = 1 },
|
||||
{ Identifier = "pluto_textures", Destination = "textures", Version = 2 }
|
||||
{ Identifier = "pluto_textures", Destination = "textures", Version = 4 }
|
||||
}
|
||||
}
|
||||
@@ -31,6 +31,8 @@ function postInitialization()
|
||||
openspace.setPropertyValue("MilkyWay.renderable.transparency", 0.55)
|
||||
openspace.setPropertyValue("MilkyWay.renderable.segments", 50)
|
||||
|
||||
openspace.setPropertyValue('67P.renderable.performShading', false);
|
||||
|
||||
openspace.printInfo("Done setting default values")
|
||||
end
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@ return {
|
||||
Observer = "ROSETTA",
|
||||
Target = "CHURYUMOV-GERASIMENKO",
|
||||
Aberration = "NONE",
|
||||
TextureMap = true
|
||||
},
|
||||
DataInputTranslation = {
|
||||
Instrument = {
|
||||
|
||||
BIN
data/scene/rosetta/rosetta/RosettaKernels_New.torrent
Normal file
BIN
data/scene/rosetta/rosetta/RosettaKernels_New.torrent
Normal file
Binary file not shown.
@@ -4,6 +4,7 @@ return {
|
||||
{ Identifier = "rosetta_textures", Destination = "textures", Version = 1 }
|
||||
},
|
||||
TorrentFiles = {
|
||||
{ File = "RosettaKernels.torrent", Destination = "${SPICE}" }
|
||||
{ File = "RosettaKernels.torrent", Destination = "${SPICE}" },
|
||||
{ File = "RosettaKernels_New.torrent", Destination = "${SPICE}" }
|
||||
}
|
||||
}
|
||||
@@ -133,13 +133,25 @@ return {
|
||||
},
|
||||
GuiName = "RosettaCometTrail"
|
||||
},
|
||||
{
|
||||
{
|
||||
Name = "NAVCAM",
|
||||
Parent = "Rosetta",
|
||||
Transform = {
|
||||
Rotation = {
|
||||
Type = "SpiceRotation",
|
||||
SourceFrame = "NAVCAM",
|
||||
DestinationFrame = "ROS_SPACECRAFT",
|
||||
},
|
||||
},
|
||||
GuiName = "/Solar/Rosetta_navcam"
|
||||
},
|
||||
{
|
||||
Name = "NAVCAM FOV",
|
||||
Parent = "NAVCAM",
|
||||
Renderable = {
|
||||
Type = "RenderableFov",
|
||||
Body = "ROSETTA",
|
||||
Frame = "GALACTIC",
|
||||
Frame = "ROS_NAVCAM-A",
|
||||
RGB = { 0.8, 0.7, 0.7 },
|
||||
Textures = {
|
||||
Type = "simple",
|
||||
|
||||
Submodule ext/ghoul updated: 6174b77164...e4fb129b95
@@ -65,6 +65,12 @@ RenderableDebugPlane::RenderableDebugPlane(const ghoul::Dictionary& dictionary)
|
||||
dictionary.getValue("Name", _nodeName);
|
||||
}
|
||||
|
||||
if (dictionary.hasKey("Texture")) {
|
||||
int t;
|
||||
dictionary.getValue("Texture", t);
|
||||
_texture = t;
|
||||
}
|
||||
|
||||
std::string origin;
|
||||
if (dictionary.getValue("Origin", origin)) {
|
||||
if (origin == "LowerLeft") {
|
||||
|
||||
@@ -559,10 +559,10 @@ void RenderableFov::render(const RenderData& data) {
|
||||
// setup the data to the shader
|
||||
// Model transform and view transform needs to be in double precision
|
||||
glm::dmat4 modelTransform =
|
||||
glm::translate(glm::dmat4(1.0), data.modelTransform.translation); /* * // Translation
|
||||
glm::translate(glm::dmat4(1.0), data.modelTransform.translation) * // Translation
|
||||
glm::dmat4(data.modelTransform.rotation) *
|
||||
glm::scale(glm::dmat4(1.0), glm::dvec3(data.modelTransform.scale));
|
||||
*/
|
||||
|
||||
glm::mat4 modelViewProjectionTransform =
|
||||
data.camera.projectionMatrix() *
|
||||
glm::mat4(data.camera.combinedViewMatrix() *
|
||||
|
||||
@@ -211,11 +211,15 @@ void RenderableModelProjection::render(const RenderData& data) {
|
||||
}
|
||||
|
||||
void RenderableModelProjection::update(const UpdateData& data) {
|
||||
if (_programObject->isDirty())
|
||||
if (_programObject->isDirty()) {
|
||||
_programObject->rebuildFromFile();
|
||||
}
|
||||
|
||||
if (_fboProgramObject->isDirty())
|
||||
if (_fboProgramObject->isDirty()) {
|
||||
_fboProgramObject->rebuildFromFile();
|
||||
}
|
||||
|
||||
_projectionComponent.update();
|
||||
|
||||
_time = data.time;
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ public:
|
||||
bool isReady() const override;
|
||||
|
||||
void render(const RenderData& data) override;
|
||||
void update(const UpdateData& data) override;
|
||||
virtual void update(const UpdateData& data) final override;
|
||||
|
||||
ghoul::opengl::Texture& baseTexture() const;
|
||||
|
||||
|
||||
@@ -362,8 +362,11 @@ void RenderablePlanetProjection::update(const UpdateData& data) {
|
||||
_fboProgramObject->rebuildFromFile();
|
||||
}
|
||||
|
||||
if (_programObject->isDirty())
|
||||
if (_programObject->isDirty()) {
|
||||
_programObject->rebuildFromFile();
|
||||
}
|
||||
|
||||
_projectionComponent.update();
|
||||
|
||||
_time = Time::ref().currentTime();
|
||||
_capture = false;
|
||||
|
||||
@@ -0,0 +1,146 @@
|
||||
'use strict';
|
||||
|
||||
let https = require('https');
|
||||
var $ = require('cheerio');
|
||||
let fs = require('fs');
|
||||
|
||||
let archiveUrl = 'https://planetgate.mps.mpg.de/Image_of_the_Day/public/IofD_archive.html';
|
||||
let rootUrl = 'https://planetgate.mps.mpg.de/Image_of_the_Day/public/';
|
||||
|
||||
let missionName = '"ROSETTA"';
|
||||
let targetName = '"67P"';
|
||||
let instrumentHostName = '"ROSETTA-ORBITER"';
|
||||
let instrumentId = '"NAVCAM"';
|
||||
let detectorType = '"CAMERA"';
|
||||
let downloadFolder = "rosettaimages";
|
||||
|
||||
function getHttps(url, cb) {
|
||||
https.get(url, (res) => {
|
||||
let body = '';
|
||||
res.on('data', (d) => {
|
||||
body += d;
|
||||
});
|
||||
res.on('end', () => {
|
||||
cb(body);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function padZeros(str, nZeros) {
|
||||
str = '' + str;
|
||||
while (str.length < nZeros) str = '0' + str;
|
||||
return str;
|
||||
}
|
||||
|
||||
function formatDate(date) {
|
||||
return date.getFullYear() + '-' +
|
||||
padZeros(date.getMonth(), 2) + '-' +
|
||||
padZeros(date.getDate(), 2) + 'T' +
|
||||
padZeros(date.getHours(), 2) + ':' +
|
||||
padZeros(date.getMinutes(), 2) + ':' +
|
||||
padZeros(date.getSeconds(), 2) + '.' +
|
||||
padZeros(date.getMilliseconds(), 3);
|
||||
}
|
||||
|
||||
function parseDate(str) {
|
||||
let year = str.substr(0, 4);
|
||||
let month = str.substr(5, 2);
|
||||
let day = str.substr(8, 2);
|
||||
let hours = str.substr(11, 2);
|
||||
let minutes = str.substr(14, 2);
|
||||
let seconds = str.substr(17, 2);
|
||||
let milliseconds = str.substr(20, 3);
|
||||
|
||||
return new Date(year, month, day, hours, minutes, seconds, milliseconds);
|
||||
}
|
||||
|
||||
function formatLbl(data) {
|
||||
let maxKeyLength = 0;
|
||||
Object.keys(data).forEach((key) => {
|
||||
maxKeyLength = Math.max(maxKeyLength, key.length);
|
||||
});
|
||||
let outString = '';
|
||||
Object.keys(data).forEach((key) => {
|
||||
let value = data[key];
|
||||
outString += key;
|
||||
outString += (new Array(maxKeyLength - key.length + 1)).join(' ');
|
||||
outString += ' = ';
|
||||
outString += value;
|
||||
outString += '\n';
|
||||
});
|
||||
outString += 'END';
|
||||
return outString;
|
||||
}
|
||||
|
||||
getHttps(archiveUrl, (body) => {
|
||||
let $root = $.load(body);
|
||||
|
||||
$root('tr td').map((i, td) => {
|
||||
let thumbnailName = $(td).find('img').attr('src');
|
||||
let imageUrl = '';
|
||||
if (thumbnailName) {
|
||||
let originalName = thumbnailName.replace('_tn', '');
|
||||
imageUrl = rootUrl + originalName;
|
||||
}
|
||||
|
||||
|
||||
let detailsName = $(td).find('a').attr('href');
|
||||
if (detailsName) {
|
||||
let detailsUrl = rootUrl + detailsName;
|
||||
|
||||
getHttps(detailsUrl, (detailsBody) => {
|
||||
let $detailsRoot = $.load(detailsBody);
|
||||
|
||||
let startTime = '';
|
||||
let id = '';
|
||||
let cam = '';
|
||||
let exposureTime = '';
|
||||
|
||||
$detailsRoot('tr').map((i, detailsTr) => {
|
||||
let header = $(detailsTr).children('th').html();
|
||||
let cell = $(detailsTr).children('td').html();
|
||||
|
||||
switch (header) {
|
||||
case 'ID': id = cell; break;
|
||||
case 'Date taken': startTime = cell; break;
|
||||
case 'Camera': cam = cell; break;
|
||||
case 'Exposure time': exposureTime = cell; break;
|
||||
}
|
||||
});
|
||||
|
||||
let exposureSeconds = 0;
|
||||
if (exposureTime.substr(-2) === ' s') {
|
||||
exposureSeconds = +exposureTime.substr(0, exposureTime.length - 2);
|
||||
} else {
|
||||
throw "exposure time expressed in unexpeded format, " + exposureTime;
|
||||
}
|
||||
|
||||
let startDate = parseDate(startTime);
|
||||
let stopDate = new Date(startDate.getTime() + exposureSeconds * 1000);
|
||||
|
||||
let lblContents = formatLbl({
|
||||
MISSION_NAME: missionName,
|
||||
TARGET_NAME: targetName,
|
||||
INSTRUMENT_HOST_NAME: instrumentHostName,
|
||||
INSTRUMENT_ID: instrumentId,
|
||||
DETECTOR_TYPE: detectorType,
|
||||
START_TIME: formatDate(startDate),
|
||||
STOP_TIME: formatDate(stopDate)
|
||||
});
|
||||
|
||||
let filenameWithoutSuffix = downloadFolder + '/' + id;
|
||||
fs.writeFile(filenameWithoutSuffix + '.lbl', lblContents, (err) => {
|
||||
if (err) {
|
||||
throw err;
|
||||
}
|
||||
});
|
||||
|
||||
let suffix = imageUrl.substr(imageUrl.lastIndexOf('.'));
|
||||
let file = fs.createWriteStream(filenameWithoutSuffix + suffix);
|
||||
let request = https.get(imageUrl, (res) => {
|
||||
res.pipe(file);
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"name": "67p-crawler",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "crawler.js",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"author": "",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"cheerio": "^0.20.0"
|
||||
}
|
||||
}
|
||||
94
modules/newhorizons/shaders/dilation_fs.glsl
Normal file
94
modules/newhorizons/shaders/dilation_fs.glsl
Normal file
@@ -0,0 +1,94 @@
|
||||
/*****************************************************************************************
|
||||
* *
|
||||
* OpenSpace *
|
||||
* *
|
||||
* Copyright (c) 2014-2016 *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy of this *
|
||||
* software and associated documentation files (the "Software"), to deal in the Software *
|
||||
* without restriction, including without limitation the rights to use, copy, modify, *
|
||||
* merge, publish, distribute, sublicense, and/or sell copies of the Software, and to *
|
||||
* permit persons to whom the Software is furnished to do so, subject to the following *
|
||||
* conditions: *
|
||||
* *
|
||||
* The above copyright notice and this permission notice shall be included in all copies *
|
||||
* or substantial portions of the Software. *
|
||||
* *
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, *
|
||||
* INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A *
|
||||
* PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT *
|
||||
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF *
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE *
|
||||
* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
|
||||
****************************************************************************************/
|
||||
|
||||
#version __CONTEXT__
|
||||
|
||||
in vec2 vs_uv;
|
||||
out vec4 color;
|
||||
|
||||
uniform sampler2D tex;
|
||||
uniform sampler2D stencil;
|
||||
|
||||
// We conside the 8-neighborhood of a texel, so going a stepsize of '1' in both
|
||||
// directions
|
||||
vec2 offsets[8] = {
|
||||
vec2(-1.0, -1.0),
|
||||
vec2(-1.0, 0.0),
|
||||
vec2(-1.0, 1.0),
|
||||
vec2(0.0, -1.0),
|
||||
vec2(0.0, 1.0),
|
||||
vec2(1.0, -1.0),
|
||||
vec2(1.0, 0.0),
|
||||
vec2(1.0, 1.0)
|
||||
};
|
||||
|
||||
// Collect the contributing colors from the neighboring texels and return the
|
||||
// averaged value of all texels that passed the masking test based on 'stencil'
|
||||
vec3 gatherNeighboringColors() {
|
||||
vec2 texSize = textureSize(tex, 0);
|
||||
|
||||
// The total number of contributing texels
|
||||
int nContributions = 0;
|
||||
|
||||
// The summed color of all contributing texels
|
||||
vec3 totalColor = vec3(0.0);
|
||||
|
||||
for (int i = 0; i < 8; i++) {
|
||||
// gl_FragCoord is in pixel coordinates; the ProjectionComponent sets
|
||||
// the viewport such that pixels=texels, so we can use gl_FragCoord as an
|
||||
// integer texel coordinate
|
||||
// First offsetting them, then dividing by the texture size to get to [0,1]
|
||||
vec2 samplePosition = (gl_FragCoord.xy + offsets[i]) / texSize;
|
||||
|
||||
// The stencelling determines the areas that we have to enlarge, such that we
|
||||
// do not enlarge a previously enlarged area
|
||||
if (texture(stencil, samplePosition).r != 0.0) {
|
||||
totalColor += texture(tex, samplePosition).rgb;
|
||||
nContributions++;
|
||||
}
|
||||
}
|
||||
|
||||
// GLSL normally doesn't have a problem taking vec3(0.0)/0.0 but we don't want to
|
||||
// tempt the compiler gods
|
||||
if (nContributions > 0) {
|
||||
return totalColor / nContributions;
|
||||
}
|
||||
else {
|
||||
return vec3(0.0);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void main() {
|
||||
if (texture(stencil, vs_uv).r == 0.0) {
|
||||
// This means that the current fragment/texel we are looking at has not been
|
||||
// projected on and we only want to do the dilation into these texels
|
||||
color = vec4(gatherNeighboringColors(), 1.0);
|
||||
}
|
||||
else {
|
||||
// We are in a region where an image has been projected, so we can reuse the
|
||||
// already sampled version
|
||||
color = texture(tex, vs_uv);
|
||||
}
|
||||
}
|
||||
34
modules/newhorizons/shaders/dilation_vs.glsl
Normal file
34
modules/newhorizons/shaders/dilation_vs.glsl
Normal file
@@ -0,0 +1,34 @@
|
||||
/*****************************************************************************************
|
||||
* *
|
||||
* OpenSpace *
|
||||
* *
|
||||
* Copyright (c) 2014-2016 *
|
||||
* *
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy of this *
|
||||
* software and associated documentation files (the "Software"), to deal in the Software *
|
||||
* without restriction, including without limitation the rights to use, copy, modify, *
|
||||
* merge, publish, distribute, sublicense, and/or sell copies of the Software, and to *
|
||||
* permit persons to whom the Software is furnished to do so, subject to the following *
|
||||
* conditions: *
|
||||
* *
|
||||
* The above copyright notice and this permission notice shall be included in all copies *
|
||||
* or substantial portions of the Software. *
|
||||
* *
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, *
|
||||
* INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A *
|
||||
* PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT *
|
||||
* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF *
|
||||
* CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE *
|
||||
* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
|
||||
****************************************************************************************/
|
||||
|
||||
#version __CONTEXT__
|
||||
|
||||
layout(location = 0) in vec2 in_position;
|
||||
|
||||
out vec2 vs_uv;
|
||||
|
||||
void main() {
|
||||
vs_uv = (in_position + vec2(1.0)) / vec2(2.0);
|
||||
gl_Position = vec4(in_position, 0.0, 1.0);
|
||||
}
|
||||
@@ -24,14 +24,15 @@
|
||||
|
||||
#version __CONTEXT__
|
||||
|
||||
#include "PowerScaling/powerScaling_vs.hglsl"
|
||||
|
||||
in vec4 vs_position;
|
||||
in vec4 vs_normal;
|
||||
in vec2 vs_uv;
|
||||
in vec4 ProjTexCoord;
|
||||
|
||||
out vec4 color;
|
||||
layout (location = 0) out vec4 color;
|
||||
// Even though the stencel texture is only a single channel, we still need to
|
||||
// output a vec4, or the result will disappear
|
||||
layout (location = 1) out vec4 stencil;
|
||||
|
||||
uniform sampler2D projectionTexture;
|
||||
|
||||
@@ -44,22 +45,24 @@ bool inRange(float x, float a, float b) {
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 uv = vec2(0.5,0.5)*vs_uv+vec2(0.5,0.5);
|
||||
vec2 uv = vec2(0.5,0.5)*vs_uv+vec2(0.5,0.5);
|
||||
|
||||
vec3 n = normalize(vs_normal.xyz);
|
||||
vec4 projected = ProjTexCoord;
|
||||
vec3 n = normalize(vs_normal.xyz);
|
||||
vec4 projected = ProjTexCoord;
|
||||
|
||||
//normalize
|
||||
projected.x /= projected.w;
|
||||
projected.y /= projected.w;
|
||||
//invert gl coordinates
|
||||
projected.x = 1 - projected.x;
|
||||
|
||||
if ((inRange(projected.x, 0, 1) && inRange(projected.y, 0, 1)) && (dot(n, boresight) < 0)) {
|
||||
// normalize
|
||||
projected.x /= projected.w;
|
||||
projected.y /= projected.w;
|
||||
// invert gl coordinates
|
||||
projected.x = 1 - projected.x;
|
||||
|
||||
if ((inRange(projected.x, 0, 1) && inRange(projected.y, 0, 1)) && (dot(n, boresight) < 0)) {
|
||||
color = texture(projectionTexture, projected.xy);
|
||||
color.a = 1.0;
|
||||
}
|
||||
else {
|
||||
color = vec4(vec3(0.0), 1.0);
|
||||
}
|
||||
stencil = vec4(1.0);
|
||||
}
|
||||
else {
|
||||
color = vec4(vec3(0.0), 1.0);
|
||||
stencil = vec4(0.0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ Fragment getFragment() {
|
||||
textureColor.rgb = mix(
|
||||
textureColor.rgb,
|
||||
projectionColor.rgb,
|
||||
min(_projectionFading, projectionColor.a)
|
||||
_projectionFading
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,9 @@
|
||||
#include "PowerScaling/powerScaling_vs.hglsl"
|
||||
|
||||
in vec4 vs_position;
|
||||
out vec4 color;
|
||||
|
||||
layout (location = 0) out vec4 color;
|
||||
layout (location = 1) out vec4 stencil;
|
||||
|
||||
uniform sampler2D projectionTexture;
|
||||
|
||||
@@ -82,8 +84,10 @@ void main() {
|
||||
// The 1-x is in this texture call because of flipped textures
|
||||
// to be fixed soon ---abock
|
||||
color = texture(projectionTexture, vec2(projected.x, 1-projected.y));
|
||||
stencil = vec4(1.0);
|
||||
}
|
||||
else {
|
||||
color = vec4(0.0);
|
||||
stencil = vec4(0.0);
|
||||
}
|
||||
}
|
||||
@@ -24,8 +24,6 @@
|
||||
|
||||
#version __CONTEXT__
|
||||
|
||||
#include "PowerScaling/powerScaling_vs.hglsl"
|
||||
|
||||
layout(location = 0) in vec4 in_position;
|
||||
|
||||
out vec4 vs_position;
|
||||
|
||||
@@ -53,6 +53,8 @@ namespace {
|
||||
const std::string keySequenceType = "Projection.SequenceType";
|
||||
const std::string keyTranslation = "DataInputTranslation";
|
||||
|
||||
const std::string keyNeedsTextureMapDilation = "Projection.TextureMap";
|
||||
|
||||
const std::string sequenceTypeImage = "image-sequence";
|
||||
const std::string sequenceTypePlaybook = "playbook";
|
||||
const std::string sequenceTypeHybrid = "hybrid";
|
||||
@@ -74,6 +76,7 @@ ProjectionComponent::ProjectionComponent()
|
||||
, _clearAllProjections("clearAllProjections", "Clear Projections", false)
|
||||
, _projectionFading("projectionFading", "Projection Fading", 1.f, 0.f, 1.f)
|
||||
, _projectionTexture(nullptr)
|
||||
, _needsTextureMapDilation(false)
|
||||
{
|
||||
setName("ProjectionComponent");
|
||||
|
||||
@@ -100,6 +103,42 @@ bool ProjectionComponent::initialize() {
|
||||
}
|
||||
_placeholderTexture = std::move(texture);
|
||||
|
||||
|
||||
if (_needsTextureMapDilation) {
|
||||
_dilation.program = ghoul::opengl::ProgramObject::Build(
|
||||
"Dilation",
|
||||
"${MODULE_NEWHORIZONS}/shaders/dilation_vs.glsl",
|
||||
"${MODULE_NEWHORIZONS}/shaders/dilation_fs.glsl"
|
||||
);
|
||||
|
||||
const GLfloat plane[] = {
|
||||
-1, -1,
|
||||
1, 1,
|
||||
-1, 1,
|
||||
-1, -1,
|
||||
1, -1,
|
||||
1, 1,
|
||||
};
|
||||
|
||||
glGenVertexArrays(1, &_dilation.vao);
|
||||
glGenBuffers(1, &_dilation.vbo);
|
||||
|
||||
glBindVertexArray(_dilation.vao);
|
||||
glBindBuffer(GL_ARRAY_BUFFER, _dilation.vbo);
|
||||
glBufferData(GL_ARRAY_BUFFER, sizeof(plane), plane, GL_STATIC_DRAW);
|
||||
glEnableVertexAttribArray(0);
|
||||
glVertexAttribPointer(
|
||||
0,
|
||||
2,
|
||||
GL_FLOAT,
|
||||
GL_FALSE,
|
||||
sizeof(GLfloat) * 2,
|
||||
reinterpret_cast<void*>(0)
|
||||
);
|
||||
|
||||
glBindVertexArray(0);
|
||||
}
|
||||
|
||||
return a && b;
|
||||
}
|
||||
|
||||
@@ -108,6 +147,15 @@ bool ProjectionComponent::deinitialize() {
|
||||
|
||||
glDeleteFramebuffers(1, &_fboID);
|
||||
|
||||
if (_needsTextureMapDilation) {
|
||||
glDeleteFramebuffers(1, &_dilation.fbo);
|
||||
glDeleteVertexArrays(1, &_dilation.vao);
|
||||
glDeleteBuffers(1, &_dilation.vbo);
|
||||
|
||||
_dilation.program = nullptr;
|
||||
_dilation.texture = nullptr;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -145,6 +193,11 @@ bool ProjectionComponent::initializeProjectionSettings(const Dictionary& diction
|
||||
_potentialTargets[i] = target;
|
||||
}
|
||||
}
|
||||
|
||||
if (dictionary.hasKeyAndValue<bool>(keyNeedsTextureMapDilation)) {
|
||||
_needsTextureMapDilation = dictionary.value<bool>(keyNeedsTextureMapDilation);
|
||||
}
|
||||
|
||||
return completeSuccess;
|
||||
}
|
||||
|
||||
@@ -238,13 +291,50 @@ void ProjectionComponent::imageProjectBegin() {
|
||||
static_cast<GLsizei>(_projectionTexture->width()),
|
||||
static_cast<GLsizei>(_projectionTexture->height())
|
||||
);
|
||||
|
||||
if (_needsTextureMapDilation) {
|
||||
GLenum buffers[] = { GL_COLOR_ATTACHMENT0, GL_COLOR_ATTACHMENT1 };
|
||||
glDrawBuffers(2, buffers);
|
||||
}
|
||||
}
|
||||
|
||||
void ProjectionComponent::imageProjectEnd() {
|
||||
if (_needsTextureMapDilation) {
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _dilation.fbo);
|
||||
|
||||
glDisable(GL_BLEND);
|
||||
|
||||
ghoul::opengl::TextureUnit unit[2];
|
||||
unit[0].activate();
|
||||
_projectionTexture->bind();
|
||||
|
||||
unit[1].activate();
|
||||
_dilation.stencilTexture->bind();
|
||||
|
||||
_dilation.program->activate();
|
||||
_dilation.program->setUniform("tex", unit[0]);
|
||||
_dilation.program->setUniform("stencil", unit[1]);
|
||||
|
||||
glBindVertexArray(_dilation.vao);
|
||||
glDrawArrays(GL_TRIANGLES, 0, 6);
|
||||
|
||||
_dilation.program->deactivate();
|
||||
|
||||
glEnable(GL_BLEND);
|
||||
}
|
||||
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _defaultFBO);
|
||||
glViewport(_viewport[0], _viewport[1], _viewport[2], _viewport[3]);
|
||||
}
|
||||
|
||||
void ProjectionComponent::update() {
|
||||
if (_needsTextureMapDilation) {
|
||||
if (_dilation.program->isDirty()) {
|
||||
_dilation.program->rebuildFromFile();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
bool ProjectionComponent::auxiliaryRendertarget() {
|
||||
bool completeSuccess = true;
|
||||
|
||||
@@ -263,8 +353,47 @@ bool ProjectionComponent::auxiliaryRendertarget() {
|
||||
);
|
||||
// check FBO status
|
||||
GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
|
||||
if (status != GL_FRAMEBUFFER_COMPLETE)
|
||||
if (status != GL_FRAMEBUFFER_COMPLETE) {
|
||||
LERROR("Main Framebuffer incomplete");
|
||||
completeSuccess &= false;
|
||||
}
|
||||
|
||||
|
||||
if (_needsTextureMapDilation) {
|
||||
// We only need the stencil texture if we need to dilate
|
||||
glFramebufferTexture2D(
|
||||
GL_FRAMEBUFFER,
|
||||
GL_COLOR_ATTACHMENT1,
|
||||
GL_TEXTURE_2D,
|
||||
*_dilation.stencilTexture,
|
||||
0
|
||||
);
|
||||
|
||||
// check FBO status
|
||||
status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
|
||||
if (status != GL_FRAMEBUFFER_COMPLETE) {
|
||||
LERROR("Main Framebuffer incomplete");
|
||||
completeSuccess &= false;
|
||||
}
|
||||
|
||||
glGenFramebuffers(1, &_dilation.fbo);
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _dilation.fbo);
|
||||
glFramebufferTexture2D(
|
||||
GL_FRAMEBUFFER,
|
||||
GL_COLOR_ATTACHMENT0,
|
||||
GL_TEXTURE_2D,
|
||||
*_dilation.texture,
|
||||
0
|
||||
);
|
||||
|
||||
// check FBO status
|
||||
status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
|
||||
if (status != GL_FRAMEBUFFER_COMPLETE) {
|
||||
LERROR("Dilation Framebuffer incomplete");
|
||||
completeSuccess &= false;
|
||||
}
|
||||
}
|
||||
|
||||
// switch back to window-system-provided framebuffer
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, defaultFBO);
|
||||
|
||||
@@ -287,18 +416,24 @@ glm::mat4 ProjectionComponent::computeProjectorMatrix(const glm::vec3 loc, glm::
|
||||
glm::vec3 e3 = glm::normalize(boreSight);
|
||||
glm::vec3 e1 = glm::normalize(glm::cross(uptmp, e3));
|
||||
glm::vec3 e2 = glm::normalize(glm::cross(e3, e1));
|
||||
glm::mat4 projViewMatrix = glm::mat4(e1.x, e2.x, e3.x, 0.f,
|
||||
e1.y, e2.y, e3.y, 0.f,
|
||||
e1.z, e2.z, e3.z, 0.f,
|
||||
-glm::dot(e1, loc), -glm::dot(e2, loc), -glm::dot(e3, loc), 1.f);
|
||||
glm::mat4 projViewMatrix = glm::mat4(
|
||||
e1.x, e2.x, e3.x, 0.f,
|
||||
e1.y, e2.y, e3.y, 0.f,
|
||||
e1.z, e2.z, e3.z, 0.f,
|
||||
-glm::dot(e1, loc), -glm::dot(e2, loc), -glm::dot(e3, loc), 1.f
|
||||
);
|
||||
// create perspective projection matrix
|
||||
glm::mat4 projProjectionMatrix = glm::perspective(glm::radians(fieldOfViewY), aspectRatio, nearPlane, farPlane);
|
||||
glm::mat4 projProjectionMatrix = glm::perspective(
|
||||
glm::radians(fieldOfViewY), aspectRatio, nearPlane, farPlane
|
||||
);
|
||||
// bias matrix
|
||||
glm::mat4 projNormalizationMatrix = glm::mat4(0.5f, 0, 0, 0,
|
||||
0, 0.5f, 0, 0,
|
||||
0, 0, 0.5f, 0,
|
||||
0.5f, 0.5f, 0.5f, 1);
|
||||
return projNormalizationMatrix*projProjectionMatrix*projViewMatrix;
|
||||
glm::mat4 projNormalizationMatrix = glm::mat4(
|
||||
0.5f, 0.f, 0.f, 0.f,
|
||||
0.f, 0.5f, 0.f, 0.f,
|
||||
0.f, 0.f, 0.5f, 0.f,
|
||||
0.5f, 0.5f, 0.5f, 1.f
|
||||
);
|
||||
return projNormalizationMatrix * projProjectionMatrix * projViewMatrix;
|
||||
}
|
||||
|
||||
bool ProjectionComponent::doesPerformProjection() const {
|
||||
@@ -314,7 +449,12 @@ float ProjectionComponent::projectionFading() const {
|
||||
}
|
||||
|
||||
ghoul::opengl::Texture& ProjectionComponent::projectionTexture() const {
|
||||
return *_projectionTexture;
|
||||
if (_needsTextureMapDilation) {
|
||||
return *_dilation.texture;
|
||||
}
|
||||
else {
|
||||
return *_projectionTexture;
|
||||
}
|
||||
}
|
||||
|
||||
std::string ProjectionComponent::projectorId() const {
|
||||
@@ -357,14 +497,18 @@ void ProjectionComponent::clearAllProjections() {
|
||||
GLint m_viewport[4];
|
||||
glGetIntegerv(GL_VIEWPORT, m_viewport);
|
||||
//counter = 0;
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _fboID);
|
||||
|
||||
glViewport(0, 0, static_cast<GLsizei>(_projectionTexture->width()), static_cast<GLsizei>(_projectionTexture->height()));
|
||||
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _fboID);
|
||||
|
||||
glClearColor(0.f, 0.f, 0.f, 0.f);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
|
||||
//bind back to default
|
||||
if (_needsTextureMapDilation) {
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, _dilation.fbo);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
}
|
||||
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, defaultFBO);
|
||||
glViewport(m_viewport[0], m_viewport[1],
|
||||
m_viewport[2], m_viewport[3]);
|
||||
@@ -381,8 +525,9 @@ std::shared_ptr<ghoul::opengl::Texture> ProjectionComponent::loadProjectionTextu
|
||||
using ghoul::io::TextureReader;
|
||||
|
||||
|
||||
if (isPlaceholder)
|
||||
if (isPlaceholder) {
|
||||
return _placeholderTexture;
|
||||
}
|
||||
|
||||
|
||||
unique_ptr<Texture> texture = TextureReader::ref().loadTexture(absPath(texturePath));
|
||||
@@ -408,9 +553,35 @@ bool ProjectionComponent::generateProjectionLayerTexture() {
|
||||
glm::uvec3(maxSize, maxSize / 2, 1),
|
||||
ghoul::opengl::Texture::Format::RGBA
|
||||
);
|
||||
if (_projectionTexture)
|
||||
if (_projectionTexture) {
|
||||
_projectionTexture->uploadTexture();
|
||||
//_projectionTexture->setFilter(ghoul::opengl::Texture::FilterMode::AnisotropicMipMap);
|
||||
}
|
||||
|
||||
if (_needsTextureMapDilation) {
|
||||
_dilation.texture = std::make_unique<ghoul::opengl::Texture>(
|
||||
glm::uvec3(maxSize, maxSize / 2, 1),
|
||||
ghoul::opengl::Texture::Format::RGBA
|
||||
);
|
||||
|
||||
if (_dilation.texture) {
|
||||
_dilation.texture->uploadTexture();
|
||||
//_dilation.texture->setFilter(ghoul::opengl::Texture::FilterMode::AnisotropicMipMap);
|
||||
}
|
||||
|
||||
_dilation.stencilTexture = std::make_unique<ghoul::opengl::Texture>(
|
||||
glm::uvec3(maxSize, maxSize / 2, 1),
|
||||
ghoul::opengl::Texture::Format::Red,
|
||||
ghoul::opengl::Texture::Format::Red
|
||||
);
|
||||
|
||||
if (_dilation.stencilTexture) {
|
||||
_dilation.stencilTexture->uploadTexture();
|
||||
//_dilation.texture->setFilter(ghoul::opengl::Texture::FilterMode::AnisotropicMipMap);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return _projectionTexture != nullptr;
|
||||
|
||||
}
|
||||
|
||||
@@ -32,6 +32,14 @@
|
||||
#include <ghoul/misc/dictionary.h>
|
||||
#include <ghoul/opengl/texture.h>
|
||||
|
||||
namespace ghoul {
|
||||
namespace opengl {
|
||||
|
||||
class ProgramObject;
|
||||
|
||||
} // namespace opengl
|
||||
} // namespace ghoul
|
||||
|
||||
namespace openspace {
|
||||
|
||||
class ProjectionComponent : public properties::PropertyOwner {
|
||||
@@ -49,6 +57,8 @@ public:
|
||||
void imageProjectBegin();
|
||||
void imageProjectEnd();
|
||||
|
||||
void update();
|
||||
|
||||
bool generateProjectionLayerTexture();
|
||||
bool auxiliaryRendertarget();
|
||||
|
||||
@@ -108,6 +118,16 @@ protected:
|
||||
|
||||
GLint _defaultFBO;
|
||||
GLint _viewport[4];
|
||||
|
||||
bool _needsTextureMapDilation;
|
||||
struct {
|
||||
GLuint fbo;
|
||||
GLuint vao;
|
||||
GLuint vbo;
|
||||
std::unique_ptr<ghoul::opengl::ProgramObject> program;
|
||||
std::unique_ptr<ghoul::opengl::Texture> texture;
|
||||
std::unique_ptr<ghoul::opengl::Texture> stencilTexture;
|
||||
} _dilation;
|
||||
};
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
@@ -234,8 +234,10 @@ bool OpenSpaceEngine::create(int argc, char** argv,
|
||||
return false;
|
||||
|
||||
// Parse commandline arguments
|
||||
std::vector<std::string> args(argv, argv + argc);
|
||||
std::shared_ptr<const std::vector<std::string>> arguments =
|
||||
_engine->_commandlineParser->setCommandLine(argc, argv);
|
||||
_engine->_commandlineParser->setCommandLine(args);
|
||||
|
||||
bool showHelp = _engine->_commandlineParser->execute();
|
||||
if (showHelp) {
|
||||
_engine->_commandlineParser->displayHelp();
|
||||
|
||||
@@ -69,10 +69,10 @@ function (set_compile_settings project)
|
||||
|
||||
if (MSVC)
|
||||
target_compile_options(${project} PUBLIC
|
||||
"/MP" # Multi-threading support
|
||||
"/ZI" # Edit and continue support
|
||||
"/wd4201" # Disable nameless struct warning
|
||||
"/wd4127" # Disable conditional expression is constant warning
|
||||
"/MP" # Multi-threading support
|
||||
"/ZI" # Edit and continue support
|
||||
"/wd4201" # Disable "nameless struct" warning
|
||||
"/wd4127" # Disable "conditional expression is constant" warning
|
||||
)
|
||||
if (OPENSPACE_WARNINGS_AS_ERRORS)
|
||||
target_compile_options(${project} PUBLIC "/WX")
|
||||
|
||||
Reference in New Issue
Block a user