Changeset 24463
- Timestamp:
- 12/10/19 12:49:10 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/Elements/Element.cpp
r24434 r24463 3216 3216 void Element::ResultToVector(Vector<IssmDouble>* vector,int output_enum){/*{{{*/ 3217 3217 3218 int MAXVERTICES = 6; 3219 IssmDouble values[MAXVERTICES]; 3220 int connectivity[MAXVERTICES]; 3221 int sidlist[MAXVERTICES]; 3222 3218 3223 switch(this->inputs2->GetInputObjectEnum(output_enum)){ 3219 3224 case TriaInput2Enum: … … 3237 3242 const int NUM_VERTICES = this->GetNumberOfVertices(); 3238 3243 3239 IssmDouble *values = xNew<IssmDouble>(NUM_VERTICES); 3240 int *connectivity= xNew<int>(NUM_VERTICES); 3241 int *sidlist = xNew<int>(NUM_VERTICES); 3242 3243 this->GetVerticesSidList(sidlist); 3244 this->GetVerticesConnectivityList(connectivity); 3245 this->GetInputListOnVertices(values,output_enum); 3244 3245 3246 this->GetVerticesSidList(&sidlist[0]); 3247 this->GetVerticesConnectivityList(&connectivity[0]); 3248 this->GetInputListOnVertices(&values[0],output_enum); 3246 3249 for(int i=0;i<NUM_VERTICES;i++) values[i] = values[i]/reCast<IssmDouble>(connectivity[i]); 3247 3248 3250 vector->SetValues(NUM_VERTICES,sidlist,values,ADD_VAL); 3249 3250 xDelete<IssmDouble>(values);3251 xDelete<int>(connectivity);3252 xDelete<int>(sidlist);3253 3251 break; 3254 3252 }
Note:
See TracChangeset
for help on using the changeset viewer.