mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-06 11:39:49 -06:00
Make it possible to fade in/out RenderableFieldLinesSequences (e.g. magnetosphere)
This commit is contained in:
@@ -354,6 +354,8 @@ RenderableFieldlinesSequence::RenderableFieldlinesSequence(
|
||||
{
|
||||
const Parameters p = codegen::bake<Parameters>(dictionary);
|
||||
|
||||
addProperty(Fadeable::_opacity);
|
||||
|
||||
// Extracts the general information (from the asset file) that
|
||||
// is mandatory for the class to function;
|
||||
std::string fileTypeString;
|
||||
@@ -1031,6 +1033,8 @@ void RenderableFieldlinesSequence::render(const RenderData& data, RendererTasks&
|
||||
global::windowDelegate->applicationTime() * (_flowReversed ? -1 : 1)
|
||||
);
|
||||
|
||||
_shaderProgram->setUniform("opacity", opacity());
|
||||
|
||||
bool additiveBlending = false;
|
||||
if (_colorABlendEnabled) {
|
||||
additiveBlending = true;
|
||||
|
||||
Reference in New Issue
Block a user