From: enk Date: Tue, 7 Feb 2006 12:13:08 +0000 (+0000) Subject: Fix for Bug IPAL11536: X-Git-Tag: mergeto_trunk_07Feb06~1 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=f8a53edb437a3cc32f4d5407c8d027928e88dcda;p=modules%2Fvisu.git Fix for Bug IPAL11536: About creation Scalar Map on Deformed shape --- diff --git a/src/VISU_I/VISU_Gen_i.cc b/src/VISU_I/VISU_Gen_i.cc index bf51d9b3..ff03f9f2 100644 --- a/src/VISU_I/VISU_Gen_i.cc +++ b/src/VISU_I/VISU_Gen_i.cc @@ -42,6 +42,7 @@ #include "VISU_Plot3D_i.hh" #include "VISU_Table_i.hh" #include "VISU_TimeAnimation.h" +#include "VISU_ScalarMapOnDeformedShape_i.hh" #include "VISU_Actor.h" @@ -200,6 +201,7 @@ namespace VISU Storable::Registry(Table_i::myComment.c_str(),&(Table_i::Restore)); Storable::Registry(Curve_i::myComment.c_str(),&(Curve_i::Restore)); Storable::Registry(Container_i::myComment.c_str(),&(Container_i::Restore)); + Storable::Registry(ScalarMapOnDeformedShape_i::myComment.c_str(),&(Restore)); } @@ -668,6 +670,15 @@ namespace VISU return Prs3dOnField(theResult,theMeshName,theEntity,theFieldName,theIteration)._retn(); } + ScalarMapOnDeformedShape_ptr VISU_Gen_i::ScalarMapOnDeformedShapeOnField(Result_ptr theResult, + const char* theMeshName, + VISU::Entity theEntity, + const char* theFieldName, + CORBA::Double theIteration) + { + return Prs3dOnField(theResult,theMeshName,theEntity,theFieldName,theIteration)._retn(); + } + Vectors_ptr VISU_Gen_i::VectorsOnField(Result_ptr theResult, const char* theMeshName, VISU::Entity theEntity, diff --git a/src/VISU_I/VISU_Gen_i.hh b/src/VISU_I/VISU_Gen_i.hh index d1ab5424..1f4f9212 100644 --- a/src/VISU_I/VISU_Gen_i.hh +++ b/src/VISU_I/VISU_Gen_i.hh @@ -178,6 +178,13 @@ namespace VISU CORBA::Double theIteration); virtual + ScalarMapOnDeformedShape_ptr + ScalarMapOnDeformedShapeOnField(Result_ptr theResult, + const char* theMeshName, + VISU::Entity theEntity, + const char* theFieldName, + CORBA::Double theIteration); + virtual Vectors_ptr VectorsOnField(Result_ptr theResult, const char* theMeshName, diff --git a/src/VISU_I/VISU_ScalarMapOnDeformedShape_i.cc b/src/VISU_I/VISU_ScalarMapOnDeformedShape_i.cc index 3246f8f2..9b8868e3 100644 --- a/src/VISU_I/VISU_ScalarMapOnDeformedShape_i.cc +++ b/src/VISU_I/VISU_ScalarMapOnDeformedShape_i.cc @@ -53,6 +53,9 @@ int VISU::ScalarMapOnDeformedShape_i::IsPossible(Result_i* theResult, const char try{ aResult = VISU::ScalarMap_i::IsPossible(theResult,theMeshName,theEntity,theFieldName,theIteration,false); if(isMemoryCheck && aResult){ + const VISU::PField aField = theResult->GetInput()->GetField(theMeshName,(VISU::TEntity)theEntity,theFieldName); + if(aField->myNbComp <= 1) + return false; float aSize = INCMEMORY* theResult->GetInput()->GetTimeStampSize(theMeshName,(VISU::TEntity)theEntity,theFieldName,theIteration); aResult = VISU_PipeLine::CheckAvailableMemory(aSize);