completely new imagesequencer class - WIP

This commit is contained in:
Michal Marcinkowski
2015-04-16 11:57:23 -04:00
parent d124209281
commit de6fcf1583
24 changed files with 834 additions and 584 deletions
@@ -33,7 +33,8 @@
#include <openspace/util/sequenceparser.h>
#include <openspace/util/hongkangparser.h>
#include <openspace/util/payload.h>
#include <openspace/util/labelparser.h>
#include <openspace/util/decoder.h>
#include <openspace/properties/stringproperty.h>
@@ -77,7 +78,7 @@ protected:
private:
void imageProjectGPU();
std::map<std::string, Payload*> _fileTranslation;
std::map<std::string, Decoder*> _fileTranslation;
properties::StringProperty _colorTexturePath;
properties::StringProperty _projectionTexturePath;
@@ -134,6 +135,8 @@ private:
GLuint _fboID;
GLuint _quad;
GLuint _vertexPositionBuffer;
bool _once; //fml
};
} // namespace openspace
@@ -124,59 +124,3 @@ public:
};
}
#endif
// Scrap stuff i need to keep for now (michal)
/* // idk how we will compute the aberrated state.
double RenderableFov::computeTargetLocalTime(PowerScaledScalar d){
double c = 299792456.075; // m/s
double dt = ( (d[0]*pow(10, d[1])) / c );
double t_local = _time - dt*86400;
std::string localTime;
std::string currentTime;
openspace::SpiceManager::ref().getDateFromET(t_local, localTime);
openspace::SpiceManager::ref().getDateFromET(_time , currentTime);
std::cout << "time at jupiter : " << localTime << "\time at NH" << currentTime << std::endl;
return t_local;
}*/
/*
psc RenderableFov::sphericalInterpolate(glm::dvec3 p0, glm::dvec3 p1, float t){
double targetEt, lt;
glm::dvec3 ip, iv;
psc targetPos;
SpiceManager::ref().getTargetPosition("JUPITER", _spacecraft, _frame, _aberrationCorrection, _time, targetPos, lt);
openspace::SpiceManager::ref().getSurfaceIntercept(_fovTarget, _spacecraft, _instrumentID,
_frame, _method, _aberrationCorrection, _time, targetEt, p0, ip, iv);
psc psc0 = PowerScaledCoordinate::CreatePowerScaledCoordinate(iv[0], iv[1], iv[2]);
openspace::SpiceManager::ref().getSurfaceIntercept(_fovTarget, _spacecraft, _instrumentID,
_frame, _method, _aberrationCorrection, _time, targetEt, p1, ip, iv);
psc psc1 = PowerScaledCoordinate::CreatePowerScaledCoordinate(iv[0], iv[1], iv[2]);
psc0[3] += 3;
psc1[3] += 3;
psc0 -= targetPos;
psc1 -= targetPos;
double angle = psc0.angle(psc1);
std::cout << angle << std::endl;
double sin_a = sin(angle); // opt
double l[2] = { sin((1.f - t)*angle) / sin_a, sin((t)*angle) / sin_a };
std::cout << l[0] << " " << l[1] << std::endl;
float s = ((t-1)*psc0[3] + (t)*psc1[3]);
float x = (l[0]*psc0[0] + l[1]*psc1[0]);
float y = (l[0]*psc0[1] + l[1]*psc1[1]);
float z = (l[0]*psc0[2] + l[1]*psc1[2]);
psc interpolated = PowerScaledCoordinate::PowerScaledCoordinate(x, y, z, 10);
return interpolated;
}
*/