Skip to content

Commit

Permalink
All: minor
Browse files Browse the repository at this point in the history
  • Loading branch information
benoit128 committed Dec 3, 2024
1 parent 8d0258a commit ac620e4
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 4 deletions.
3 changes: 2 additions & 1 deletion Cassiopee/CPlot/CPlot/Plugins/screenDump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -336,13 +336,14 @@ char* Data::export2Image(E_Int exportWidth, E_Int exportHeight)
}

// software postprocessing on final buffer (just before screen dump)
/*
if (rank == 0)
{
char* bfl = new char [_view.w * _view.h];
for (E_Int i = 0; i < 3*_view.w*_view.h; i++) bfl[i] = buffer[i];
specPostProcess(bfl, _view.w, _view.h, depth, buffer);
delete [] bfl;
}
}*/
free(depth);
MPI_Barrier(MPI_COMM_WORLD); // seems needed

Expand Down
8 changes: 7 additions & 1 deletion Cassiopee/Converter/Converter/hook.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,9 @@ PyObject* K_CONVERTER::registerFaces(PyObject* self, PyObject* args)
E_Float* cy = centers->begin(2);
E_Float* cz = centers->begin(3);
E_Float inv0 = E_Float(0.25);
#ifdef QUADDOUBLE
quad_double qinv0 = quad_double(0.25);
#endif

#pragma omp parallel default(shared)
{
Expand Down Expand Up @@ -398,7 +400,9 @@ PyObject* K_CONVERTER::registerFaces(PyObject* self, PyObject* args)
{
FldArrayI& cm = *(cnl->getConnect(ic));
E_Float inv = E_Float(1./nof[ic]);
#ifdef QUADDOUBLE
quad_double qinv = quad_double(nof[ic]);
#endif

#pragma omp parallel default(shared)
{
Expand Down Expand Up @@ -768,8 +772,10 @@ PyObject* K_CONVERTER::registerElements(PyObject* self, PyObject* args)
E_Float* cy = centers->begin(2);
E_Float* cz = centers->begin(3);
E_Float inv = E_Float(0.125);
#ifdef QUADDOUBLE
quad_double qinv = quad_double(8.);

#endif

#pragma omp parallel
{
E_Int ip, jp, kp, indcell, indv;
Expand Down
3 changes: 2 additions & 1 deletion Cassiopee/Converter/Converter/identify.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -503,8 +503,9 @@ PyObject* K_CONVERTER::identifyElements(PyObject* self, PyObject* args)
nelts = cm.getSize(); // Number of elements of this connectivity
nvert = cm.getNfld(); // Nombre de points par elements de cette connectivite
E_Float inv = 1./E_Float(nvert);
#ifdef QUADDOUBLE
quad_double qinv = quad_double(nvert);
#endif
E_Float* xt = centers->begin(1);
E_Float* yt = centers->begin(2);
E_Float* zt = centers->begin(3);
Expand Down
2 changes: 2 additions & 0 deletions Cassiopee/Converter/Converter/nearest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,9 @@ PyObject* K_CONVERTER::nearestElements(PyObject* self, PyObject* args)
nelts = cm.getSize(); // Number of elements of this connectivity
nvert = cm.getNfld(); // Nombre de points par elements de cette connectivite
E_Float inv = 1./E_Float(nvert);
#ifdef QUADDOUBLE
quad_double qinv = quad_double(nvert);
#endif

#pragma omp parallel
{
Expand Down
2 changes: 1 addition & 1 deletion Cassiopee/Post/Post/computeDiv2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ PyObject* K_POST::computeDiv2Struct(PyObject* self, PyObject* args)
FldArrayF faceField(nbIntTot, dimPb*nfld); faceField.setAllValuesAtNull();
FldArrayI voisins(nbIntTot,2); voisins.setAllValuesAt(-1);
E_Int* cellG = voisins.begin(1); E_Int* cellD = voisins.begin(2);
PyObject* tpl;
PyObject* tpl = NULL;

if (dimPb == 2)
tpl = computeDiv2Struct2D(ni, nj, nic, njc, ixyz, varStringOut, cellNp,
Expand Down

0 comments on commit ac620e4

Please sign in to comment.