Skip to content
Snippets Groups Projects
Commit 912f6860 authored by Amira Abdel-Rahman's avatar Amira Abdel-Rahman
Browse files

fixed chiral stress viz

parent 53544442
No related branches found
No related tags found
No related merge requests found
Pipeline #5865 passed
...@@ -6,4 +6,6 @@ node_modules ...@@ -6,4 +6,6 @@ node_modules
*.stl *.stl
*.obj *.obj
*.mtl *.mtl
CAD CAD
\ No newline at end of file tutorial
live
\ No newline at end of file
...@@ -156,6 +156,8 @@ ...@@ -156,6 +156,8 @@
gData.nodes[j].dzs[i]=setups.nodes[j].displacement.z*scale; gData.nodes[j].dzs[i]=setups.nodes[j].displacement.z*scale;
} }
for(let j=0;j<setups.edges.length;j++){ for(let j=0;j<setups.edges.length;j++){
setups.viz.colorMaps=[YlGnBu,coolwarm, winter ,jet];
setups.viz.colorMap=0;
gData.links[j].stresses[i]=getColor(setups.viz,setups.edges[j].stress); gData.links[j].stresses[i]=getColor(setups.viz,setups.edges[j].stress);
} }
}); });
...@@ -175,18 +177,20 @@ ...@@ -175,18 +177,20 @@
node.fy=node.py+node.dys[count]*exaggeration; node.fy=node.py+node.dys[count]*exaggeration;
node.fz=node.pz+node.dzs[count]*exaggeration; node.fz=node.pz+node.dzs[count]*exaggeration;
}); });
gData.links.forEach(edge => { // gData.links.forEach(edge => {
edge.color=edge.stresses[count] // edge.color=edge.stresses[count]
}); // });
}); });
Graph.linkColor(({ stresses }) => stresses[count]);
// count++; // count++;
// if(count>maxNumFiles){ // if(count>maxNumFiles){
// count=0; // count=0;
// } // }
if(count>=maxNumFiles){ if(count>=maxNumFiles-1){
increment=false; increment=false;
}else if (count<=0){ }else if (count<=1){
increment=true; increment=true;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment