Commit d5792980 authored by Sven Schneider's avatar Sven Schneider
Browse files

added missing files and new thunmnails

parent 3323ec43
No related merge requests found
Pipeline #3293 passed with stages
in 34 seconds
Showing with 15724 additions and 98 deletions
+15724 -98
...@@ -335,7 +335,8 @@ var pos=[]; ...@@ -335,7 +335,8 @@ var pos=[];
var cols = []; var cols = [];
var streamID = []; var streamID = [];
d3.dsv(",", "results/polylines_circularData.csv").then(function(text) { // d3.dsv(",", "results/polylines_circularData.csv").then(function(text) {
d3.dsv(",", "results/Kirchturm1.csv").then(function(text) {
// console.log(text); // Hello, world! // console.log(text); // Hello, world!
// var temp = text.split(','); // var temp = text.split(',');
......
public/imgs/thumbnails/Kirchturm.JPG

118 KB

public/imgs/thumbnails/Kirchturm1.JPG

95.5 KB

public/imgs/thumbnails/Kirchturm2.JPG

111 KB

...@@ -39,11 +39,11 @@ $(function () { ...@@ -39,11 +39,11 @@ $(function () {
animation: true, animation: true,
infoBox: true, infoBox: true,
baseLayerPicker: true, baseLayerPicker: true,
fullscreenButton: true, fullscreenButton: false,
timeline: true, timeline: false,
navigationHelpButton: true, navigationHelpButton: true,
navigationInstructionsInitiallyVisible: false, navigationInstructionsInitiallyVisible: false,
homeButton: true, homeButton: false,
selectionIndicator: true, selectionIndicator: true,
geocoder: true, geocoder: true,
// imageryProviderViewModels: imageryViewModels // imageryProviderViewModels: imageryViewModels
...@@ -138,7 +138,7 @@ $(function () { ...@@ -138,7 +138,7 @@ $(function () {
var Velocity = []; var Velocity = [];
var pt_to_pt_dist = []; var pt_to_pt_dist = [];
var avgVelocity = []; var avgVelocity = [];
var czmlArray = [];
function get_date_time_dt(deltaTime) { function get_date_time_dt(deltaTime) {
// deltaTime should be given in SECONDS and is then converted to milliseconds // deltaTime should be given in SECONDS and is then converted to milliseconds
...@@ -151,31 +151,23 @@ $(function () { ...@@ -151,31 +151,23 @@ $(function () {
} }
d3.dsv(",", "results/polylines_with_velocity.csv").then(function (text) { d3.dsv(",", "results/polylines_with_velocity.csv").then(function (text) {
const particleDuration = 120; // units in seconds the particle / point should take to move from start to finish const particleDuration = 90; // units in seconds the particle / point should take to move from start to finish
//define the czml structure //define the czml structure
var particle_czml = [ var particle_czml = [
{ {
id: "document", id: "document",
name: "CZML Point - Time Dynamic", name: "CZML Point - Time Dynamic",
version: "1.0", version: "1.0",
clock: {
interval: get_date_time_dt(0) + "/" + get_date_time_dt(particleDuration), // This is the time range of our simulation
currentTime: '', // This is the time associated with the start view
currentTime: get_date_time_dt(0),
multiplier: 5,
// range: 'LOOP_STOP',
}
}, },
{ {
id: "point", id: "point",
availability: get_date_time_dt(0) + "/" + get_date_time_dt(particleDuration), availability:
get_date_time_dt(0) + "/" + get_date_time_dt(particleDuration),
position: { position: {
epoch: get_date_time_dt(0), epoch: get_date_time_dt(0),
cartographicDegrees: [ cartographicDegrees: [
// use 4 coordinates / values : (t,x,y,z) or rather (t,lon,lat,alt) // use 4 coordinates / values : (t,x,y,z) or rather (t,lon,lat,alt)
], ],
//"interpolationAlgorithm": "LAGRANGE",
//"interpolationDegree": 1
}, },
point: { point: {
color: { color: {
...@@ -189,18 +181,6 @@ $(function () { ...@@ -189,18 +181,6 @@ $(function () {
}, },
}, },
]; ];
//////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////
let package_time_faktor = 6.0;
// create an array of deep copies of the original czml data structure, to be modified below.
let czmlArr = [];
for (c=0; c < package_time_faktor; c++){
czmlArr.push(JSON.parse(JSON.stringify(particle_czml)));
czmlArr[c][1].id = "point_arr_" + String(c);
}
var temp = text; var temp = text;
for (var i = 0; i < temp.length; i++) { for (var i = 0; i < temp.length; i++) {
...@@ -243,7 +223,6 @@ $(function () { ...@@ -243,7 +223,6 @@ $(function () {
// Create and draw a polyline with per vertex colors // Create and draw a polyline with per vertex colors
///////////////////////////////////////////////// /////////////////////////////////////////////////
const heightOffset = 120; const heightOffset = 120;
for (var line = 0; line < uniqueStreamID.length; line++) { for (var line = 0; line < uniqueStreamID.length; line++) {
let positions = []; let positions = [];
let positionsInDegrees = []; let positionsInDegrees = [];
...@@ -252,10 +231,7 @@ $(function () { ...@@ -252,10 +231,7 @@ $(function () {
let individual_particle_pt_distance = []; let individual_particle_pt_distance = [];
let individual_particle_avg_velo = []; let individual_particle_avg_velo = [];
curr_pos = sIDidx[line]; for (i = sIDidx[line - 1]; i < sIDidx[line] - 1; ++i) {
for (i = curr_pos; i < streamID.length; ++i) {
if (line === streamID[i]){
positions.push( positions.push(
Cesium.Cartesian3.fromDegrees( Cesium.Cartesian3.fromDegrees(
pos[i][0], pos[i][0],
...@@ -274,7 +250,6 @@ $(function () { ...@@ -274,7 +250,6 @@ $(function () {
individual_particle_avg_velo.push(avgVelocity[i]); individual_particle_avg_velo.push(avgVelocity[i]);
individual_particle_pt_distance.push(pt_to_pt_dist[i]); individual_particle_pt_distance.push(pt_to_pt_dist[i]);
individual_particle_velo.push(Velocity[i]); individual_particle_velo.push(Velocity[i]);
} // if end brace
} }
// For per segment coloring, supply the colors option with // For per segment coloring, supply the colors option with
// an array of colors for each vertex. Also set the // an array of colors for each vertex. Also set the
...@@ -303,11 +278,10 @@ $(function () { ...@@ -303,11 +278,10 @@ $(function () {
// console.log(streamDist); // console.log(streamDist);
let t = 0; let t = 0;
let dt = (individual_particle_pt_distance[1] / individual_particle_avg_velo[0]) / 20; let dt = (individual_particle_pt_distance[0] / individual_particle_avg_velo[0])/ 500;
// let dt = streamDist / individual_particle_avg_velo[0] / 500; // let dt = streamDist / individual_particle_avg_velo[0] / 500;
let temp_pos = [];
/////////////////////////////////////
var temp_pos = [];
for (i = 0; i < positionsInDegrees.length; i++) { for (i = 0; i < positionsInDegrees.length; i++) {
if (i === 0) { if (i === 0) {
temp_pos.push( temp_pos.push(
...@@ -323,54 +297,26 @@ $(function () { ...@@ -323,54 +297,26 @@ $(function () {
positionsInDegrees[i][1], positionsInDegrees[i][1],
positionsInDegrees[i][2] positionsInDegrees[i][2]
); );
dt = individual_particle_pt_distance[i] /individual_particle_avg_velo[0] / 20; // avg_velo is always the same per streamline dt = individual_particle_pt_distance[i] /individual_particle_avg_velo[i] / 500;
// console.log(individual_particle_pt_distance[i] + "/" + individual_particle_avg_velo[i] ); // console.log(individual_particle_pt_distance[i] + "/" + individual_particle_avg_velo[i] );
// console.log(dt); // console.log(dt);
} }
t += dt; t += dt;
} }
particle_czml[1].id = "point" + String(line); particle_czml[1].id = "point" + String(line);
particle_czml[1].position.cartographicDegrees = temp_pos; particle_czml[1].position.cartographicDegrees = temp_pos;
viewer.dataSources.add(Cesium.CzmlDataSource.load(particle_czml));
//////////////////////////////////////////////// // czmlArray.push(particle_czml);
dt = (individual_particle_pt_distance[1] / individual_particle_avg_velo[0]) / 20; viewer.dataSources.add(Cesium.CzmlDataSource.load(particle_czml));
for (c=0; c < czmlArr.length ; c++){
temp_pos = [];
for (i = 0; i < positionsInDegrees.length; i++) {
if (i === 0) {
temp_pos.push(
t,
positionsInDegrees[i][0],
positionsInDegrees[i][1],
positionsInDegrees[i][2]
);
} else {
temp_pos.push(
t,
positionsInDegrees[i][0],
positionsInDegrees[i][1],
positionsInDegrees[i][2]
);
dt = individual_particle_pt_distance[i] /individual_particle_avg_velo[0] / 20;
// console.log(individual_particle_pt_distance[i] + "/" + individual_particle_avg_velo[i] );
// console.log(dt);
}
t += dt;
}
czmlArr[c][1].position.cartographicDegrees = temp_pos;
czmlArr[c][1].id = "point_set_" + String(c) + "_" + String(line);
czmlArr[c][1].position.epoch = get_date_time_dt(0);
viewer.dataSources.add(Cesium.CzmlDataSource.load(czmlArr[c]));
} }
// for (p = 0; p < czmlArray.length; p++) {
// let temp = czmlArray[p];
// viewer.dataSources.add(Cesium.CzmlDataSource.load(temp));
// }
} // end bracket for: for (var line = 0; line < uniqueStreamID.length; line++) { });
}); // end bracket for: d3.dsv(...).then(...
......
This diff is collapsed.
This diff is collapsed.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment