? VISU_SRC_3.2.2/aclocal.m4
? VISU_SRC_3.2.2/autom4te.cache
? VISU_SRC_3.2.2/configure
? VISU_SRC_3.2.2/configure.in
? VISU_SRC_3.2.2/configure.in_new
? VISU_SRC_3.2.2/configure.in_old
Index: VISU_SRC_3.2.2/idl/VISU_Gen.idl
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/idl/VISU_Gen.idl,v
retrieving revision 1.17.2.1
retrieving revision 1.17.2.3
diff -c -u -r1.17.2.1 -r1.17.2.3
--- VISU_SRC_3.2.2/idl/VISU_Gen.idl 22 Aug 2006 05:29:39 -0000 1.17.2.1
+++ VISU_SRC_3.2.2/idl/VISU_Gen.idl 23 Oct 2006 14:18:57 -0000 1.17.2.3
@@ -964,6 +964,25 @@
* Gets the number of cut lines.
*/
long GetNbLines();
+
+ /*! Invert all curves of corresponding table
+ * \param theInvert - Invert all curves, if value is TRUE, else not.
+ */
+ void SetAllCurvesInverted(in boolean theInvert);
+
+ /*! Checks the orientation of all curves
+ * \retval TRUE - if all curves are inverted, else FALSE
+ */
+ boolean IsAllCurvesInverted();
+
+ /*! Sets values which cutlines would be shown: aboslute or relative values
+ * \param theAbsLength - boolean value, TRUE or false.
+ */
+ void SetUseAbsoluteLength(in boolean theAbsLength);
+
+ /*! Checks values of cutlines: using aboslute or relative values
+ */
+ boolean IsUseAbsoluteLength();
};
/*! \brief Interface of the stream lines representation
@@ -1302,6 +1321,9 @@
*/
void setCycling(in boolean theCycle);
+ boolean isCleaningMemoryAtEachFrame();
+ void setCleaningMemoryAtEachFrame(in boolean theCycle);
+
SALOMEDS::SObject publishInStudy();
void saveAnimation();
Index: VISU_SRC_3.2.2/resources/SalomeApp.xml
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/resources/SalomeApp.xml,v
retrieving revision 1.2.4.1
retrieving revision 1.2.4.3
diff -c -u -r1.2.4.1 -r1.2.4.3
--- VISU_SRC_3.2.2/resources/SalomeApp.xml 27 Jun 2006 07:49:40 -0000 1.2.4.1
+++ VISU_SRC_3.2.2/resources/SalomeApp.xml 20 Oct 2006 11:53:41 -0000 1.2.4.3
@@ -4,8 +4,14 @@
-
-
+
+
+
+
+
+
+
+
Index: VISU_SRC_3.2.2/src/CONVERTOR/VISU_Convertor_impl.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/CONVERTOR/VISU_Convertor_impl.cxx,v
retrieving revision 1.13.2.2
retrieving revision 1.13.2.3
diff -c -u -r1.13.2.2 -r1.13.2.3
--- VISU_SRC_3.2.2/src/CONVERTOR/VISU_Convertor_impl.cxx 21 Aug 2006 14:40:06 -0000 1.13.2.2
+++ VISU_SRC_3.2.2/src/CONVERTOR/VISU_Convertor_impl.cxx 20 Oct 2006 06:52:31 -0000 1.13.2.3
@@ -1485,17 +1485,19 @@
//---------------------------------------------------------------
- void
+ bool
GetMeshOnProfile(const PMeshImpl& theMesh,
const PMeshOnEntityImpl& theMeshOnEntity,
const PProfileImpl& theProfile)
{
INITMSG(MYDEBUG,"GetMeshOnProfile - anEntity = "<myEntity<myMeshOnEntity && theProfile->myMeshOnEntity != theMeshOnEntity.get())
+ return false;
+
if(theProfile->myIsVTKDone)
- return;
-
- theProfile->myMeshOnEntity = theMeshOnEntity.get();
+ return true;
+
const TVTKAppendFilter& anAppendFilter = theProfile->GetFilter();
anAppendFilter->SetPoints(GetPoints(theMesh));
@@ -1533,9 +1535,11 @@
}
}
anAppendFilter->Update(); // Fix on VTK
+ theProfile->myMeshOnEntity = theMeshOnEntity.get();
theProfile->myNamedPointCoords = theMesh->myNamedPointCoords;
theProfile->myIsVTKDone = true;
+ return true;
}
@@ -2073,15 +2077,20 @@
const VISU::PProfileImpl& theProfile,
const VISU::TEntity& theEntity)
{
- LoadMeshOnEntity(theMesh,theMeshOnEntity);
- GetMeshOnEntity(theMeshOnEntity->myMeshName,theMeshOnEntity->myEntity);
- GetMeshOnProfile(theMesh,theMeshOnEntity,theProfile);
-
- theIDMapperFilter->myIDMapper = theProfile;
- TVTKOutput* anOutput = theIDMapperFilter->GetVTKOutput();
- const TVTKSource& aSource = theIDMapperFilter->mySource.GetSource();
- ::GetTimeStampOnProfile(aSource,theField,theValForTime,theEntity);
-
+ TVTKOutput* anOutput = NULL;
+ try{
+ LoadMeshOnEntity(theMesh,theMeshOnEntity);
+ GetMeshOnEntity(theMeshOnEntity->myMeshName,theMeshOnEntity->myEntity);
+ if(GetMeshOnProfile(theMesh,theMeshOnEntity,theProfile)){
+ theIDMapperFilter->myIDMapper = theProfile;
+ anOutput = theIDMapperFilter->GetVTKOutput();
+ const TVTKSource& aSource = theIDMapperFilter->mySource.GetSource();
+ ::GetTimeStampOnProfile(aSource,theField,theValForTime,theEntity);
+ }
+ }catch(std::exception& exc){
+ MSG(MYDEBUG,"Follow exception was occured :\n"<myIsVTKDone){
LoadValForTimeOnMesh(aMesh,aMeshOnEntity,aField,aValForTime);
- TVTKOutput* anOutput;
- try{
- anOutput = GetTimeStampOnProfile(aMesh,
- aVTKMeshOnEntity,
- aField,
- aValForTime,
- anIDMapperFilter,
- aValForTime->myProfile,
- aMeshOnEntity->myEntity);
- }catch(std::exception& exc){
- MSG(MYDEBUG,"Follow exception was occured :\n"<myProfile,
+ aMeshOnEntity->myEntity);
+ if(!anOutput)
anOutput = GetTimeStampOnProfile(aMesh,
aMeshOnEntity,
aField,
@@ -2139,7 +2145,6 @@
anIDMapperFilter,
aValForTime->myProfile,
aVTKMeshOnEntity->myEntity);
- }
anIDMapperFilter->myIsVTKDone = true;
Index: VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.cxx,v
retrieving revision 1.19.2.5
retrieving revision 1.19.2.7
diff -c -u -r1.19.2.5 -r1.19.2.7
--- VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.cxx 4 Sep 2006 11:35:19 -0000 1.19.2.5
+++ VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.cxx 13 Oct 2006 12:40:52 -0000 1.19.2.7
@@ -71,8 +71,8 @@
#define _LOAD_FAMILIES_
#define _EDF_NODE_IDS_
-namespace
-{
+//namespace
+//{
//---------------------------------------------------------------
vtkIdType
MEDGeom2NbNodes(MED::EGeometrieElement theMEDGeomType)
@@ -1132,7 +1132,7 @@
}
};
-}
+//}
//---------------------------------------------------------------
@@ -1141,16 +1141,17 @@
CreateConvertor(const string& theFileName)
{
if(MED::PWrapper aMed = MED::CrWrapper(theFileName,true))
- return new VISU_MedConvertor(theFileName);
+ return new VISU_MedConvertor(theFileName, aMed);
return NULL;
}
VISU_MedConvertor
-::VISU_MedConvertor(const string& theFileName):
+::VISU_MedConvertor(const string& theFileName, MED::PWrapper theMed):
myIsEntitiesDone(false),
myIsFieldsDone(false),
myIsGroupsDone(false),
- myIsMinMaxDone(false)
+ myIsMinMaxDone(false),
+ myMed(theMed)
{
myFileInfo.setFile(QString(theFileName.c_str()));
myName = myFileInfo.baseName().latin1();
@@ -1167,9 +1168,8 @@
TSetIsDone aSetIsDone(myIsEntitiesDone);
TTimerLog aTimerLog(MYDEBUG,"BuildEntities");
- MED::PWrapper aMed = MED::CrWrapper(myFileInfo.absFilePath().latin1());
- TInt aNbMeshes = aMed->GetNbMeshes();
+ TInt aNbMeshes = myMed->GetNbMeshes();
TMeshMap& aMeshMap = myMeshMap;
INITMSG(MYDEBUG,"BuildEntities aNbMeshes = "<GetPMeshInfo(iMesh);
+ MED::PMeshInfo aMeshInfo = myMed->GetPMeshInfo(iMesh);
std::string aMeshName = aMeshInfo->GetName();
TInt aDim = aMeshInfo->GetDim();
MED::EMaillage aType = aMeshInfo->GetType();
@@ -1198,8 +1198,8 @@
if(aType == MED::eNON_STRUCTURE){
- if(MED::PNodeInfo aNodeInfo = aMed->GetPNodeInfo(aMeshInfo)){
- MED::TEntityInfo anEntityInfo = aMed->GetEntityInfo(aMeshInfo);
+ if(MED::PNodeInfo aNodeInfo = myMed->GetPNodeInfo(aMeshInfo)){
+ MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo);
aMesh->myNbPoints = aNodeInfo->GetNbElem();
aMesh->myEntityInfo = anEntityInfo;
@@ -1215,7 +1215,7 @@
BuildMeshOnEntityMap(aMesh,
anEntityInfo,
aNodeInfo,
- aMed);
+ myMed);
#ifndef _DEXCEPT_
}catch(std::exception& exc){
@@ -1227,7 +1227,7 @@
}
} // NON STRUCTURED MESH
else {
- MED::PGrilleInfo aGrilleInfo = aMed->GetPGrilleInfo(aMeshInfo);
+ MED::PGrilleInfo aGrilleInfo = myMed->GetPGrilleInfo(aMeshInfo);
MED::TEntityInfo anEntityInfo;
anEntityInfo[MED::eNOEUD][MED::ePOINT1] = aGrilleInfo->GetNbNodes();
@@ -1244,7 +1244,7 @@
BuildMeshGrilleOnEntityMap(aMesh,
anEntityInfo,
aGrilleInfo,
- aMed);
+ myMed);
#ifndef _DEXCEPT_
}catch(std::exception& exc){
@@ -1279,9 +1279,8 @@
TSetIsDone aSetIsDone(myIsFieldsDone);
TTimerLog aTimerLog(MYDEBUG,"BuildFields");
- MED::PWrapper aMed = MED::CrWrapper(myFileInfo.absFilePath().latin1());
- TInt aNbMeshes = aMed->GetNbMeshes();
+ TInt aNbMeshes = myMed->GetNbMeshes();
TMeshMap& aMeshMap = myMeshMap;
INITMSG(MYDEBUG,"BuildFields - aNbMeshes = "<GetPMeshInfo(iMesh);
+ MED::PMeshInfo aMeshInfo = myMed->GetPMeshInfo(iMesh);
std::string aMeshName = aMeshInfo->GetName();
TMeshMap::const_iterator anIter = aMeshMap.find(aMeshName);
@@ -1304,11 +1303,11 @@
#ifndef _DEXCEPT_
try{
#endif
- MED::TEntityInfo anEntityInfo = aMed->GetEntityInfo(aMeshInfo);
+ MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo);
BuildFieldMap(aMesh,
anEntityInfo,
- aMed);
+ myMed);
#ifndef _DEXCEPT_
}catch(std::exception& exc){
MSG(MYDEBUG,"Follow exception was occured in:\n"<GetNbMeshes();
+ TInt aNbMeshes = myMed->GetNbMeshes();
TMeshMap& aMeshMap = myMeshMap;
INITMSG(MYDEBUG,"BuildMinMax - aNbMeshes = "<GetPMeshInfo(iMesh);
+ MED::PMeshInfo aMeshInfo = myMed->GetPMeshInfo(iMesh);
std::string aMeshName = aMeshInfo->GetName();
TMeshMap::const_iterator anIter = aMeshMap.find(aMeshName);
@@ -1367,23 +1365,23 @@
#ifndef _DEXCEPT_
try{
#endif
- TInt aNbFields = aMed->GetNbFields();
+ TInt aNbFields = myMed->GetNbFields();
INITMSG(MYDEBUG,
"- aMeshName = '"<GetEntityInfo(aMeshInfo);
+ MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo);
for(TInt iField = 1; iField <= aNbFields; iField++){
TTimerLog aTimerLog(MYDEBUG,"BuildMinMax - GetPFieldInfo()");
- MED::PFieldInfo aFieldInfo = aMed->GetPFieldInfo(aMeshInfo,iField);
+ MED::PFieldInfo aFieldInfo = myMed->GetPFieldInfo(aMeshInfo,iField);
std::string aFieldName = aFieldInfo->GetName();
INITMSG(MYDEBUG,"- aFieldName = '"<GetNbTimeStamps(aFieldInfo,
+ TInt aNbTimeStamps = myMed->GetNbTimeStamps(aFieldInfo,
anEntityInfo,
aMEntity,
aGeom2Size);
@@ -1417,12 +1415,12 @@
try{
#endif
#endif
- MED::PTimeStampInfo aTimeStampInfo = aMed->GetPTimeStampInfo(aFieldInfo,
+ MED::PTimeStampInfo aTimeStampInfo = myMed->GetPTimeStampInfo(aFieldInfo,
aMEntity,
aGeom2Size,
iTimeStamp);
- MED::PTimeStampVal aTimeStampVal = aMed->GetPTimeStampVal(aTimeStampInfo,
+ MED::PTimeStampVal aTimeStampVal = myMed->GetPTimeStampVal(aTimeStampInfo,
aMKey2Profile,
aKey2Gauss);
@@ -1543,9 +1541,8 @@
TSetIsDone aSetIsDone(myIsGroupsDone);
TTimerLog aTimerLog(MYDEBUG,"BuildGroups");
- MED::PWrapper aMed = MED::CrWrapper(myFileInfo.absFilePath().latin1());
- TInt aNbMeshes = aMed->GetNbMeshes();
+ TInt aNbMeshes = myMed->GetNbMeshes();
TMeshMap& aMeshMap = myMeshMap;
INITMSG(MYDEBUG,"BuildGroups - aNbMeshes = "<GetPMeshInfo(iMesh);
+ MED::PMeshInfo aMeshInfo = myMed->GetPMeshInfo(iMesh);
std::string aMeshName = aMeshInfo->GetName();
TMeshMap::const_iterator anIter = aMeshMap.find(aMeshName);
@@ -1568,27 +1565,27 @@
MED::EMaillage aType = aMeshInfo->GetType();
- MED::TEntityInfo anEntityInfo = aMed->GetEntityInfo(aMeshInfo);
+ MED::TEntityInfo anEntityInfo = myMed->GetEntityInfo(aMeshInfo);
MED::TEntity2TGeom2ElemInfo anEntity2TGeom2ElemInfo =
- MED::GetEntity2TGeom2ElemInfo(aMed,aMeshInfo,anEntityInfo);
+ MED::GetEntity2TGeom2ElemInfo(myMed,aMeshInfo,anEntityInfo);
#ifndef _DEXCEPT_
try{
#endif
- MED::TFamilyInfoSet aFamilyInfoSet = MED::GetFamilyInfoSet(aMed,aMeshInfo);
+ MED::TFamilyInfoSet aFamilyInfoSet = MED::GetFamilyInfoSet(myMed,aMeshInfo);
if(aType == MED::eNON_STRUCTURE)
BuildFamilyMap(aMesh,
anEntityInfo,
anEntity2TGeom2ElemInfo,
aFamilyInfoSet,
- aMed);
+ myMed);
else
BuildGrilleFamilyMap(aMesh,
anEntityInfo,
aFamilyInfoSet,
- aMed);
+ myMed);
BuildGroupMap(aMesh,
aFamilyInfoSet);
@@ -1622,15 +1619,14 @@
TTimerLog aTimerLog(MYDEBUG,"LoadMeshOnEntity");
INITMSG(MYDEBUG,"LoadMeshOnEntity"<myEntity;
int isPointsUpdated = 0, isCellsOnEntityUpdated = 0;
if(anEntity == NODE_ENTITY){
- isPointsUpdated += LoadPoints(aMed,theMesh);
+ isPointsUpdated += LoadPoints(myMed,theMesh);
}else{
- isPointsUpdated += LoadPoints(aMed,theMesh);
- isCellsOnEntityUpdated += LoadCellsOnEntity(aMed,theMesh,theMeshOnEntity);
+ isPointsUpdated += LoadPoints(myMed,theMesh);
+ isCellsOnEntityUpdated += LoadCellsOnEntity(myMed,theMesh,theMeshOnEntity);
}
return (isPointsUpdated || isCellsOnEntityUpdated);
@@ -1647,15 +1643,14 @@
TTimerLog aTimerLog(MYDEBUG,"LoadFamilyOnEntity");
INITMSG(MYDEBUG,"LoadFamilyOnEntity"<myEntity;
int isPointsUpdated = 0, isCellsOnEntityUpdated = 0;
if(anEntity == NODE_ENTITY){
- isPointsUpdated += LoadPointsOnFamily(aMed,theMesh,theFamily);
+ isPointsUpdated += LoadPointsOnFamily(myMed,theMesh,theFamily);
}else{
- isPointsUpdated += LoadPoints(aMed,theMesh);
- isCellsOnEntityUpdated += LoadCellsOnFamily(aMed,theMesh,theMeshOnEntity,theFamily);
+ isPointsUpdated += LoadPoints(myMed,theMesh);
+ isCellsOnEntityUpdated += LoadCellsOnFamily(myMed,theMesh,theMeshOnEntity,theFamily);
}
return (isPointsUpdated || isCellsOnEntityUpdated);
@@ -1671,18 +1666,17 @@
TTimerLog aTimerLog(MYDEBUG,"LoadMeshOnGroup");
INITMSG(MYDEBUG,"LoadMeshOnGroup"<myEntity;
const PMEDMeshOnEntity aMeshOnEntity = theMesh->myMeshOnEntityMap[anEntity];
- isPointsUpdated += LoadPoints(aMed,theMesh);
+ isPointsUpdated += LoadPoints(myMed,theMesh);
if(anEntity == NODE_ENTITY){
- isPointsUpdated += LoadPointsOnFamily(aMed,theMesh,aFamily);
+ isPointsUpdated += LoadPointsOnFamily(myMed,theMesh,aFamily);
}else{
- isCellsOnEntityUpdated += LoadCellsOnFamily(aMed,theMesh,aMeshOnEntity,aFamily);
+ isCellsOnEntityUpdated += LoadCellsOnFamily(myMed,theMesh,aMeshOnEntity,aFamily);
}
}
@@ -1701,14 +1695,12 @@
TTimerLog aTimerLog(MYDEBUG,"LoadValForTimeOnMesh");
INITMSG(MYDEBUG,"LoadValForTimeOnMesh"<myEntity;
int isPointsUpdated = 0, isCellsOnEntityUpdated = 0;
- isPointsUpdated += LoadPoints(aMed,theMesh);
+ isPointsUpdated += LoadPoints(myMed,theMesh);
if(anEntity != NODE_ENTITY)
- isCellsOnEntityUpdated += LoadCellsOnEntity(aMed,theMesh,theMeshOnEntity);
- int isFieldUpdated = LoadValForTimeOnMesh(aMed,theMesh,theMeshOnEntity,theField,theValForTime);
+ isCellsOnEntityUpdated += LoadCellsOnEntity(myMed,theMesh,theMeshOnEntity);
+ int isFieldUpdated = LoadValForTimeOnMesh(myMed,theMesh,theMeshOnEntity,theField,theValForTime);
return (isPointsUpdated || isCellsOnEntityUpdated || isFieldUpdated);
}
@@ -1725,13 +1717,11 @@
TTimerLog aTimerLog(MYDEBUG,"LoadValForTimeOnGaussPts");
INITMSG(MYDEBUG,"LoadValForTimeOnGaussPts"<myEntity;
int isPointsUpdated = 0, isCellsOnEntityUpdated = 0;
if(anEntity != NODE_ENTITY)
- isCellsOnEntityUpdated += LoadCellsOnEntity(aMed,theMesh,theMeshOnEntity);
- int isFieldUpdated = LoadValForTimeOnGaussPts(aMed,theMesh,theMeshOnEntity,theField,theValForTime);
+ isCellsOnEntityUpdated += LoadCellsOnEntity(myMed,theMesh,theMeshOnEntity);
+ int isFieldUpdated = LoadValForTimeOnGaussPts(myMed,theMesh,theMeshOnEntity,theField,theValForTime);
return (isPointsUpdated || isCellsOnEntityUpdated || isFieldUpdated);
}
Index: VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.hxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.hxx,v
retrieving revision 1.8
retrieving revision 1.8.2.1
diff -c -u -r1.8 -r1.8.2.1
--- VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.hxx 1 Jun 2006 11:36:04 -0000 1.8
+++ VISU_SRC_3.2.2/src/CONVERTOR/VISU_MedConvertor.hxx 13 Oct 2006 12:40:52 -0000 1.8.2.1
@@ -21,6 +21,7 @@
#include "VISU_Convertor_impl.hxx"
+#include "MED_Wrapper.hxx"
#include "MED_Common.hxx"
#include "MED_Structures.hxx"
@@ -201,7 +202,7 @@
bool myIsMinMaxDone;
public:
- VISU_MedConvertor(const std::string& theFileName);
+ VISU_MedConvertor(const std::string& theFileName, MED::PWrapper theMed);
virtual
VISU_Convertor*
@@ -221,6 +222,7 @@
protected:
QFileInfo myFileInfo;
+ MED::PWrapper myMed; // mpv : bug 13568: one med per converter
virtual
int
Index: VISU_SRC_3.2.2/src/VISUGUI/VISU_msg_en.po
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VISU_msg_en.po,v
retrieving revision 1.35.2.1
retrieving revision 1.35.2.4
diff -c -u -r1.35.2.1 -r1.35.2.4
--- VISU_SRC_3.2.2/src/VISUGUI/VISU_msg_en.po 22 Aug 2006 05:30:47 -0000 1.35.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VISU_msg_en.po 20 Oct 2006 11:52:17 -0000 1.35.2.4
@@ -147,6 +147,24 @@
msgid "VISU_SWEEPING_PREF"
msgstr "Sweeping preferences"
+msgid "VISU_LINEAR_SWEEP"
+msgstr "Linear"
+
+msgid "VISU_U_SWEEP"
+msgstr "Periodic"
+
+msgid "VISU_SWEEPING_MODES"
+msgstr "Mode of the sweeping "
+
+msgid "VISU_IS2PI"
+msgstr "Parameter varies:"
+
+msgid "PERIOD_2PI"
+msgstr "From -PI to PI"
+
+msgid "PERIOD_PI"
+msgstr "From 0 to PI"
+
msgid "VISU_TIME_STEP"
msgstr "Time step(second)"
@@ -156,6 +174,9 @@
msgid "VISU_NB_STEPS"
msgstr "Number of steps"
+msgid "VISU_CUTLINE_PREF"
+msgstr "CutLine preferences"
+
msgid "VISU_PREF_MED_IMPORT"
msgstr "MED files import"
@@ -168,6 +189,9 @@
msgid "VISU_USE_SHADING"
msgstr "Use Shading"
+msgid "VISU_DISP_ONLY"
+msgstr "Display only on creation"
+
msgid "VISU_SHRINK"
msgstr "Shrink"
@@ -460,6 +484,9 @@
msgid "VisuGUI_CutLinesDlg::LBL_INVERT_CURVES"
msgstr "Invert all curves"
+msgid "VisuGUI_CutLinesDlg::LBL_ABSOLUTE_LENGTH"
+msgstr "Use absolute length"
+
msgid "VisuGUI_CutLinesDlg::LBL_GENERATE_CURVES"
msgstr "Generate Curves"
@@ -2099,4 +2126,4 @@
msgstr "Plot3D"
msgid "VISU_SCALAR_MAP_ON_DEFORMED_SHAPE"
-msgstr "Scalar Map on Def. Shape"
\ No newline at end of file
+msgstr "Scalar Map on Def. Shape"
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.cxx,v
retrieving revision 1.95.2.2
retrieving revision 1.95.2.6
diff -c -u -r1.95.2.2 -r1.95.2.6
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.cxx 22 Aug 2006 05:30:47 -0000 1.95.2.2
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.cxx 20 Oct 2006 11:52:17 -0000 1.95.2.6
@@ -1608,12 +1608,24 @@
int aCycles = aResourceMgr->integerValue("VISU", "sweeping_number_cycles", 1);
int aSteps = aResourceMgr->integerValue("VISU", "sweeping_number_steps", 40);
+ int aMode = aResourceMgr->integerValue("VISU", "sweeping_modes", 0);
+
+ int is2Pi = aResourceMgr->integerValue("VISU", "sweeping_is2PI", 0);
+
// Sweep
QApplication::setOverrideCursor(Qt::waitCursor);
+
for (int j = 0; j < aCycles; j++) {
for (int i = 0; i <= aSteps; i++) {
try {
- float aPercents = float(i)/aSteps;
+ float aPercents;
+ if( aMode == 1 ){ //if selected Periodic mode of sweeping
+ float aT = ( is2Pi == 1 ? -PI + 2. * PI * float(i)/aSteps : PI * float(i)/aSteps );
+ //This is necessary in order for animation to retrun to the initial picture
+ aPercents = (1.+sin( aT - PI/2. ))/2.;
+ }
+ else //if selected Linear mode of sweeping
+ aPercents = float(i)/aSteps;
aPrsObject->SetMapScale(aPercents);
aPrsObject->UpdateActor(aActor);
vw->getRenderWindow()->Render();
@@ -1690,9 +1702,9 @@
VISU::Storable::TRestoringMap aMap;
_PTR(GenericAttribute) anAttr;
- if (!aSObj->FindAttribute(anAttr, "AttributeComment")) return;
+ if (!aSObj->FindAttribute(anAttr, "AttributeString")) return;
- _PTR(AttributeComment) aComment (anAttr);
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::StrToMap(strIn, aMap);
@@ -2655,8 +2667,8 @@
CORBA::Object_var aCORBAObject = VISU::ClientSObjectToObject(aSObject);
if (CORBA::is_nil(aCORBAObject)) {
_PTR(GenericAttribute) anAttr;
- if (aSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::TRestoringMap pMap;
@@ -2695,8 +2707,8 @@
if ( !aSObject )
continue;
_PTR(GenericAttribute) anAttr;
- if (aSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::TRestoringMap pMap;
@@ -3026,6 +3038,16 @@
// group: "Sweeping preferences"
int sweepGr = addPreference( tr( "VISU_SWEEPING_PREF" ), srangeTab );
setPreferenceProperty( sweepGr, "columns", 1 );
+
+ int modeSw = addPreference( tr( "VISU_SWEEPING_MODES" ), sweepGr, LightApp_Preferences::Selector, "VISU", "sweeping_modes" );
+ QStringList sweep_modes;
+ sweep_modes.append( tr( "VISU_LINEAR_SWEEP" ) );
+ sweep_modes.append( tr( "VISU_U_SWEEP" ) );
+ indices.clear();
+ indices.append( 0 );
+ indices.append( 1 );
+ setPreferenceProperty( modeSw, "strings", sweep_modes );
+ setPreferenceProperty( modeSw, "indexes", indices );
int timestep = addPreference( tr( "VISU_TIME_STEP" ), sweepGr,
LightApp_Preferences::DblSpin, "VISU", "sweeping_time_step" );
@@ -3033,11 +3055,31 @@
LightApp_Preferences::IntSpin, "VISU", "sweeping_number_cycles" );
int nbsteps = addPreference( tr( "VISU_NB_STEPS" ), sweepGr,
LightApp_Preferences::IntSpin, "VISU", "sweeping_number_steps" );
+ int rangeSw = addPreference( tr( "VISU_IS2PI" ), sweepGr, LightApp_Preferences::Selector, "VISU", "sweeping_is2PI" );
+ QStringList ranges;
+ ranges.append( tr( "PERIOD_PI" ) );
+ ranges.append( tr( "PERIOD_2PI" ) );
+ indices.clear();
+ indices.append( 0 );
+ indices.append( 1 );
+ setPreferenceProperty( rangeSw, "strings", ranges );
+ setPreferenceProperty( rangeSw, "indexes", indices );
+
setPreferenceProperty( timestep, "min", 0.1 );
setPreferenceProperty( timestep, "step", 0.1 );
setPreferenceProperty( timestep, "max", 1000 );
setPreferenceProperty( nbcycles, "max", 100 );
- setPreferenceProperty( nbsteps, "max", 200 );
+ setPreferenceProperty( nbsteps, "max", 200 );
+
+ // group: "CutLines preferences"
+ int cutLineTab = addPreference( tr( "CutLines" ) );
+ int cutLineGr = addPreference( tr( "VISU_CUTLINE_PREF" ), cutLineTab );
+ setPreferenceProperty( cutLineGr, "columns", 1 );
+ addPreference( tr( "Show preview" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "show_preview" );
+ addPreference( tr( "Invert all curves" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "invert_all_curves" );
+ addPreference( tr( "Use absolute length" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "use_absolute_length" );
+ addPreference( tr( "Generate data table" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "generate_data_table" );
+ addPreference( tr( "Generate curves" ), cutLineGr, LightApp_Preferences::Bool, "VISU", "generate_curves" );
// group: "MED files import"
int importGr = addPreference( tr( "MED files import" ), srangeTab );
@@ -3136,6 +3178,10 @@
addPreference( tr( "VISU_USE_SHADING" ), representGr,
LightApp_Preferences::Bool, "VISU", "represent_shading" );
+ addPreference( "", representGr, LightApp_Preferences::Space );
+
+ addPreference( tr( "VISU_DISP_ONLY" ), representGr,
+ LightApp_Preferences::Bool, "VISU", "display_only" );
}
void VisuGUI::preferencesChanged( const QString& a, const QString& b)
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.h
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.h,v
retrieving revision 1.29
retrieving revision 1.29.2.1
diff -c -u -r1.29 -r1.29.2.1
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.h 1 Jun 2006 11:36:05 -0000 1.29
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI.h 20 Oct 2006 11:52:17 -0000 1.29.2.1
@@ -78,6 +78,7 @@
public slots:
virtual bool deactivateModule( SUIT_Study* );
virtual bool activateModule( SUIT_Study* );
+ virtual void OnEraseAll();
protected slots:
void OnImportFromFile();
@@ -111,7 +112,7 @@
virtual void OnDisplayPrs();
virtual void OnDisplayOnlyPrs();
virtual void OnErasePrs();
- virtual void OnEraseAll();
+ // virtual void OnEraseAll();
void OnMakeSurfaceframe();
void OnMakeInsideframe();
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.cxx,v
retrieving revision 1.19.2.1
retrieving revision 1.19.2.2
diff -c -u -r1.19.2.1 -r1.19.2.2
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.cxx 23 Jun 2006 13:16:25 -0000 1.19.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.cxx 20 Oct 2006 06:52:23 -0000 1.19.2.2
@@ -62,9 +62,6 @@
using namespace std;
-bool VisuGUI_CutLinesDlg::MYGenerateTable = true;
-bool VisuGUI_CutLinesDlg::MYGenerateCurve = true;
-
VisuGUI_CutLinesDlg::VisuGUI_CutLinesDlg (SalomeApp_Module* theModule)
: QDialog(VISU::GetDesktop(theModule), "VisuGUI_CutLinesDlg", false,
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
@@ -135,8 +132,12 @@
myAllCurvesInvertedCheck->setChecked(false);
aPlaneLayout->addWidget(myAllCurvesInvertedCheck);
+ myUseAbsoluteLengthCheck = new QCheckBox(tr("LBL_ABSOLUTE_LENGTH"), aPlanePane);
+ myUseAbsoluteLengthCheck->setChecked(false);
+ aPlaneLayout->addWidget(myUseAbsoluteLengthCheck);
+
myCreateTable = new QCheckBox (tr("LBL_GENERATE_TABLE"), aPlanePane);
- myCreateTable->setChecked(MYGenerateTable);
+ myCreateTable->setChecked(true);
aPlaneLayout->addWidget( myCreateTable );
QHBox* aCheckPane = new QHBox(aPlanePane);
@@ -144,8 +145,8 @@
aCheckPane->setStretchFactor(aLbl, 0);
myCurvesCheck = new QCheckBox(tr("LBL_GENERATE_CURVES"), aCheckPane);
aCheckPane->setStretchFactor(aCheckPane, 0);
- myCurvesCheck->setChecked(MYGenerateCurve);
- myCurvesCheck->setEnabled(MYGenerateTable);
+ myCurvesCheck->setChecked(true);
+ myCurvesCheck->setEnabled(true);
QLabel* aLbl2 = new QLabel(" ", aCheckPane);
aCheckPane->setStretchFactor(aLbl2, 1);
aPlaneLayout->addWidget( aCheckPane );
@@ -289,6 +290,12 @@
myPrs = thePrs;
myScalarPane->initFromPrsObject(thePrs);
+ SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr();
+ myPreviewCheck->setChecked( aResourceMgr->booleanValue("VISU", "show_preview", false) );
+ myCreateTable->setChecked( aResourceMgr->booleanValue("VISU", "generate_data_table", true) );
+ myCurvesCheck->setChecked( aResourceMgr->booleanValue("VISU", "generate_curves", true) );
+ myCurvesCheck->setEnabled( aResourceMgr->booleanValue("VISU", "generate_curves", true) );
+
myRotXSpn->setValue(thePrs->GetRotateX()*180./PI);
myRotYSpn->setValue(thePrs->GetRotateY()*180./PI);
myPosSpn->setValue(thePrs->GetDisplacement());
@@ -303,8 +310,8 @@
hasInit = true;
myCutLines = new VISU::CutLines_i(thePrs->GetResult(),false);
myCutLines->SameAs(thePrs);
- myCutLines->CopyCurvesInverted(thePrs->GetCurvesInverted());
- if (myCutLines->IsAllCurvesInverted()) myAllCurvesInvertedCheck->setChecked(true);
+ myAllCurvesInvertedCheck->setChecked(myCutLines->IsAllCurvesInverted());
+ myUseAbsoluteLengthCheck->setChecked(myCutLines->IsUseAbsoluteLength());
myBasePlanePos->setText( QString::number(myCutLines->GetBasePlanePosition()) );
myCBSetDef->setChecked(thePrs->IsDefault());
DrawTable();
@@ -342,6 +349,8 @@
}
if (myAllCurvesInvertedCheck->isChecked())
thePrs->SetAllCurvesInverted(true);
+
+ thePrs->SetUseAbsoluteLength(myUseAbsoluteLengthCheck->isChecked());
return 1;
}
@@ -751,93 +760,9 @@
void VisuGUI_CutLinesDlg::accept()
{
- //if ( !VisuGUI::CheckActiveStudyLock() ) {
- // reject();
- // return;
- //}
- MYGenerateTable = myCreateTable->isChecked();
- MYGenerateCurve = myCurvesCheck->isChecked();
- // if (myScalarPane->check()) {
- /*jfa tmp:((QWidget*)sender())->setDisabled(true);
- storeToPrsObject(myPrs);
- if (myIsCreation) {
- if (isGenerateTable()) {
- visuGUI->GetVisuGen()->CreateTable(myPrs->GetEntry());
- if (isGenerateCurves()) {
- SALOMEDSClient_Study* aStudy = study()->studyDS();
- SALOMEDSClient_SObject* aSObject = aStudy->FindObjectID(myPrs->GetEntry());
- if( aSObject ) {
- SALOMEDSClient_ChildIterator* aIter = aStudy->NewChildIterator( aSObject );
- SALOMEDSClient_StudyBuilder* aBuilder = aStudy->NewBuilder();
- for ( ;aIter->More(); aIter->Next()) {
- SALOMEDSClient_SObject* aTblObj = aIter->Value();
- if ( aTblObj ) {
- SALOMEDSClient_GenericAttribute* anAttr;
- if (aTblObj->FindAttribute(anAttr, "AttributeName")) {
- visuGUI->CreatePlot(aTblObj);
- }
- }
- }
- }
- }
- }
- if (GET_VTK_VIEWWINDOW(myMgr)) {
- try {
- visuGUI->CreateActor(myPrs);
- } catch (...) {
- reject();
- return;
- }
- GET_VTK_VIEWWINDOW(myMgr)->onFitAll();
- }
- } else {
- visuGUI->RecreateActor(myPrs);
- if (VTKViewer_ViewWindow* vf = GET_VTK_VIEWWINDOW(myMgr)) {
- if (vf->getRenderer()->GetActors()->GetNumberOfItems() > 0) {
- vf->getRenderer()->ResetCameraClippingRange();
- vf->Repaint();
- }
- }
- // Remove old Table
- SALOMEDSClient_Study* aStudy = study()->studyDS();
- SALOMEDSClient_SObject* aSObject = aStudy->FindObjectID(myPrs->GetEntry());
- if( aSObject ) {
- SALOMEDSClient_ChildIterator* aIter = aStudy->NewChildIterator( aSObject );
- SALOMEDSClient_StudyBuilder* aBuilder = aStudy->NewBuilder();
- for ( ;aIter->More(); aIter->Next()) {
- SALOMEDSClient_SObject* aTblObj = aIter->Value();
- if ( aTblObj ) {
- SALOMEDSClient_GenericAttribute* anAttr;
- if (aTblObj->FindAttribute(anAttr, "AttributeName")) {
- aBuilder->RemoveObjectWithChildren(aIter->Value()); // We should have only one child
- break;
- }
- }
- }
- if (isGenerateTable()) {
- visuGUI->GetVisuGen()->CreateTable(aSObject->GetID().c_str());
- if (isGenerateCurves()) {
- SALOMEDSClient_Study* aStudy = study()->studyDS();
- SALOMEDSClient_ChildIterator* aIter = aStudy->NewChildIterator( aSObject );
- SALOMEDSClient_StudyBuilder* aBuilder = aStudy->NewBuilder();
- for ( ;aIter->More(); aIter->Next()) {
- SALOMEDSClient_SObject* aTblObj = aIter->Value();
- if ( aTblObj ) {
- SALOMEDSClient_GenericAttribute* anAttr;
- if (aTblObj->FindAttribute(anAttr, "AttributeName")) {
- visuGUI->CreatePlot(aTblObj);
- }
- }
- }
- }
- }
- }
- }
- VisuGUI::application()->objectBrowser()->updateTree();*/
myScalarPane->deletePreview();
deletePlanes();
QDialog::accept();
- // }
}
void VisuGUI_CutLinesDlg::reject()
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.h
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.h,v
retrieving revision 1.8.2.1
retrieving revision 1.8.2.2
diff -c -u -r1.8.2.1 -r1.8.2.2
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.h 23 Jun 2006 13:16:25 -0000 1.8.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_CutLinesDlg.h 20 Oct 2006 06:52:23 -0000 1.8.2.2
@@ -110,6 +110,7 @@
SALOME_Actor* myPreviewActorGlyphs;
QCheckBox* myPreviewCheck;
QCheckBox* myAllCurvesInvertedCheck;
+ QCheckBox* myUseAbsoluteLengthCheck;
VISU::CutLines_i* myPrs;
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Module.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Module.cxx,v
retrieving revision 1.8
retrieving revision 1.8.2.1
diff -c -u -r1.8 -r1.8.2.1
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Module.cxx 1 Jun 2006 11:36:05 -0000 1.8
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Module.cxx 17 Oct 2006 10:35:52 -0000 1.8.2.1
@@ -1315,8 +1315,8 @@
Storable::DataToStream(aStream,"mySubId",theSelection.mySubId);
_PTR(GenericAttribute) anAttr;
- anAttr = theStudyBuilder->FindOrCreateAttribute(aNewObj,"AttributeComment");
- _PTR(AttributeComment) aComment(anAttr);
+ anAttr = theStudyBuilder->FindOrCreateAttribute(aNewObj,"AttributeString");
+ _PTR(AttributeString) aComment(anAttr);
aComment->SetValue(aStream.str());
}
@@ -1346,8 +1346,8 @@
// To update selection
_PTR(GenericAttribute) anAttr;
- if(aChildSObject->FindAttribute(anAttr,"AttributeComment")){
- _PTR(AttributeComment) aComment(anAttr);
+ if(aChildSObject->FindAttribute(anAttr,"AttributeString")){
+ _PTR(AttributeString) aComment(anAttr);
QString aStream(aComment->Value().c_str());
Storable::TRestoringMap aMap;
@@ -1419,8 +1419,8 @@
Handle(SALOME_InteractiveObject) anIO = aListIter.Value();
_PTR(SObject) aSObject = aCStudy->FindObjectID(anIO->getEntry());
_PTR(GenericAttribute) anAttr;
- if(aSObject->FindAttribute(anAttr,"AttributeComment")){
- _PTR(AttributeComment) aComment(anAttr);
+ if(aSObject->FindAttribute(anAttr,"AttributeString")){
+ _PTR(AttributeString) aComment(anAttr);
std::string aCommentValue(aComment->Value());
if(aCommentValue.compare("myComment=GAUSSVIEW") >= 0){
aComment->SetValue(aValue.c_str());
@@ -1474,8 +1474,8 @@
_PTR(Study) aCStudy = GetCStudy(GetAppStudy(theModule));
_PTR(GenericAttribute) anAttr;
- if(theSObject->FindAttribute(anAttr,"AttributeComment")){
- _PTR(AttributeComment) aComment(anAttr);
+ if(theSObject->FindAttribute(anAttr,"AttributeString")){
+ _PTR(AttributeString) aComment(anAttr);
QString aStream(aComment->Value().c_str());
Storable::TRestoringMap aMap;
Storable::StrToMap(aStream,aMap);
@@ -1521,8 +1521,8 @@
_PTR(SObject) aSObject = aCStudy->FindObjectID(anIO->getEntry());
myConfigSObject = aSObject;
_PTR(GenericAttribute) anAttr;
- if(aSObject->FindAttribute(anAttr,"AttributeComment")){
- _PTR(AttributeComment) aComment(anAttr);
+ if(aSObject->FindAttribute(anAttr,"AttributeString")){
+ _PTR(AttributeString) aComment(anAttr);
QString aStream(aComment->Value().c_str());
Storable::TRestoringMap aMap;
Storable::StrToMap(aStream,aMap);
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Prs3dTools.h
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Prs3dTools.h,v
retrieving revision 1.9.2.1
retrieving revision 1.9.2.2
diff -c -u -r1.9.2.1 -r1.9.2.2
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Prs3dTools.h 19 Jun 2006 09:28:18 -0000 1.9.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Prs3dTools.h 20 Oct 2006 11:52:18 -0000 1.9.2.2
@@ -203,6 +203,9 @@
aViewWindow = GetViewWindow(theModule);
// Display created presentation.
if (aViewWindow) {
+ if(aResourceMgr->booleanValue("VISU","display_only",false)){
+ theModule->OnEraseAll();
+ }
PublishInView(theModule, aPrs3d, aViewWindow, /*highlight = */true);
aViewWindow->onFitAll();
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_ScalarMapOnDeformedShapeDlg.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_ScalarMapOnDeformedShapeDlg.cxx,v
retrieving revision 1.5.2.2
retrieving revision 1.5.2.3
diff -c -u -r1.5.2.2 -r1.5.2.3
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_ScalarMapOnDeformedShapeDlg.cxx 28 Aug 2006 07:22:18 -0000 1.5.2.2
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_ScalarMapOnDeformedShapeDlg.cxx 17 Oct 2006 10:35:52 -0000 1.5.2.3
@@ -47,7 +47,7 @@
#include "SALOME_ListIO.hxx"
-#include "SALOMEDSClient_AttributeComment.hxx"
+#include "SALOMEDSClient_AttributeString.hxx"
#include "SALOMEDSClient_AttributeName.hxx"
#include
@@ -188,8 +188,8 @@
_PTR(SObject) aSObject = aActiveStudy->FindObjectID(aIO->getEntry());
_PTR(GenericAttribute) anTmpAttr;
- if (aSObject->FindAttribute(anTmpAttr, "AttributeComment")) {
- _PTR(AttributeComment) aTmpComment (anTmpAttr);
+ if (aSObject->FindAttribute(anTmpAttr, "AttributeString")) {
+ _PTR(AttributeString) aTmpComment (anTmpAttr);
string aTmpComm = aTmpComment->Value();
QString aTmpstrIn (aTmpComm.c_str());
VISU::Storable::TRestoringMap aTmpaMap;
@@ -247,8 +247,8 @@
CORBA::Object_var aChildObject = VISU::ClientSObjectToObject(aChildSObj);
_PTR(GenericAttribute) anAttr;
- if (aChildSObj->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aChildSObj->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::TRestoringMap aMap;
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Selection.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Selection.cxx,v
retrieving revision 1.17.2.2
retrieving revision 1.17.2.3
diff -c -u -r1.17.2.2 -r1.17.2.3
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Selection.cxx 7 Sep 2006 05:50:43 -0000 1.17.2.2
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Selection.cxx 17 Oct 2006 10:35:52 -0000 1.17.2.3
@@ -397,8 +397,8 @@
VISU::Storable::TRestoringMap aMap;
if (aSObject) {
_PTR(GenericAttribute) anAttr;
- if (aSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
std::string aString = aComment->Value();
QString strIn( aString.c_str() );
VISU::Storable::StrToMap(strIn, aMap);
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx,v
retrieving revision 1.16.2.1
retrieving revision 1.16.2.2
diff -c -u -r1.16.2.1 -r1.16.2.2
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx 23 Jun 2006 13:16:25 -0000 1.16.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_StreamLinesDlg.cxx 17 Oct 2006 10:35:52 -0000 1.16.2.2
@@ -108,8 +108,8 @@
_PTR(SObject) aSObject = aActiveStudy->FindObjectID(aIO->getEntry());
_PTR(GenericAttribute) anTmpAttr;
- if (aSObject->FindAttribute(anTmpAttr, "AttributeComment")) {
- _PTR(AttributeComment) aTmpComment (anTmpAttr);
+ if (aSObject->FindAttribute(anTmpAttr, "AttributeString")) {
+ _PTR(AttributeString) aTmpComment (anTmpAttr);
string aTmpComm = aTmpComment->Value();
QString aTmpstrIn (aTmpComm.c_str());
VISU::Storable::TRestoringMap aTmpaMap;
@@ -183,8 +183,8 @@
}
_PTR(GenericAttribute) anAttr;
- if (aChildSObj->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aChildSObj->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::TRestoringMap aMap;
@@ -539,8 +539,8 @@
for (aIter->InitEx(true); aIter->More(); aIter->Next() ) {
SALOMEDSClient_SObject* aChildSObj = aIter->Value();
SALOMEDSClient_GenericAttribute* anAttr;
- if (aChildSObj->FindAttribute(anAttr, "AttributeComment")) {
- SALOMEDSClient_AttributeComment* aComment = dynamic_cast( anAttr );
+ if (aChildSObj->FindAttribute(anAttr, "AttributeString")) {
+ SALOMEDSClient_AttributeString* aComment = dynamic_cast( anAttr );
CORBA::String_var aComm = aComment->Value().c_str();
QString strIn(aComm.in());
aMap.clear();
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_TimeAnimation.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_TimeAnimation.cxx,v
retrieving revision 1.31.2.2
retrieving revision 1.31.2.3
diff -c -u -r1.31.2.2 -r1.31.2.3
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_TimeAnimation.cxx 18 Sep 2006 05:44:26 -0000 1.31.2.2
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_TimeAnimation.cxx 23 Oct 2006 14:18:25 -0000 1.31.2.3
@@ -1185,6 +1185,11 @@
TopLayout->addMultiCellWidget(aSaveBox, 7, 7, 0, 3);
+ QCheckBox* aCleanMemCheck = new QCheckBox("Clean memory at each frame",myPlayFrame);
+ aCleanMemCheck->setChecked(myAnimator->isCleaningMemoryAtEachFrame());
+ connect(aCleanMemCheck, SIGNAL(toggled(bool)), myAnimator, SLOT(setCleaningMemoryAtEachFrameSlot(bool)));
+ TopLayout->addMultiCellWidget(aCleanMemCheck, 8, 8, 0, 3);
+
aMainLayout->addWidget(myPlayFrame);
// Animation publishing in study
Index: VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Tools.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Tools.cxx,v
retrieving revision 1.38.2.1
retrieving revision 1.38.2.2
diff -c -u -r1.38.2.1 -r1.38.2.2
--- VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Tools.cxx 22 Aug 2006 05:30:47 -0000 1.38.2.1
+++ VISU_SRC_3.2.2/src/VISUGUI/VisuGUI_Tools.cxx 17 Oct 2006 10:35:52 -0000 1.38.2.2
@@ -224,8 +224,8 @@
VISU::Storable::TRestoringMap aMap;
if (theSObject) {
_PTR(GenericAttribute) anAttr;
- if (theSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (theSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
std::string aValue = aComment->Value();
QString aString (aValue.c_str());
VISU::Storable::StrToMap(aString, aMap);
@@ -257,8 +257,8 @@
_PTR(SObject) aSObject = aStudy->FindObjectID(theEntry.latin1());
if (aSObject) {
_PTR(GenericAttribute) anAttr;
- if (theMap && aSObject->FindAttribute(anAttr,"AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (theMap && aSObject->FindAttribute(anAttr,"AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
std::string aValue = aComment->Value();
QString aString (aValue.c_str());
VISU::Storable::StrToMap(aString, *theMap);
@@ -388,12 +388,12 @@
// (first sub-level) or is a child of such an object
string aNAME, aVisuNAME = GetVisuGen(theModule)->ComponentDataType();
_PTR(GenericAttribute) anAttr;
- _PTR(AttributeComment) aComment;
+ _PTR(AttributeString) aComment;
bool isUnderVISU = false;
_PTR(SObject) aFatherSObject = aSObject->GetFather();
- if (aFatherSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aFatherSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
aNAME = aComment->Value();
if (aNAME == aVisuNAME) {
isUnderVISU = true;
@@ -409,8 +409,8 @@
isUnderVISU = false;
aFatherSObject = aFatherSObject->GetFather();
- if (aFatherSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (aFatherSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
aNAME = aComment->Value();
if (aNAME == aVisuNAME) {
isUnderVISU = true;
@@ -1199,8 +1199,8 @@
}
} else {
_PTR(GenericAttribute) anAttr;
- if (theObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (theObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::TRestoringMap pMap;
Index: VISU_SRC_3.2.2/src/VISU_I/Makefile.in
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/Makefile.in,v
retrieving revision 1.17
retrieving revision 1.17.2.1
diff -c -u -r1.17 -r1.17.2.1
--- VISU_SRC_3.2.2/src/VISU_I/Makefile.in 1 Jun 2006 11:36:05 -0000 1.17
+++ VISU_SRC_3.2.2/src/VISU_I/Makefile.in 23 Oct 2006 12:38:58 -0000 1.17.2.1
@@ -61,6 +61,7 @@
VISU_TimeAnimation.h
LIB_SERVER_IDL = \
+ MED_Gen.idl \
MED.idl \
VISU_Gen.idl \
SALOME_Component.idl \
Index: VISU_SRC_3.2.2/src/VISU_I/VISUConfig.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISUConfig.cc,v
retrieving revision 1.12
retrieving revision 1.12.2.1
diff -c -u -r1.12 -r1.12.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISUConfig.cc 1 Jun 2006 11:36:05 -0000 1.12
+++ VISU_SRC_3.2.2/src/VISU_I/VISUConfig.cc 17 Oct 2006 10:37:39 -0000 1.12.2.1
@@ -265,8 +265,8 @@
SALOMEDS::SObject_var aFieldSO;
for(;anIter->More();anIter->Next()) {
SALOMEDS::GenericAttribute_var anAttr;
- if (anIter->Value()->FindAttribute(anAttr,"AttributeComment")) {
- SALOMEDS::AttributeComment_var aCmnt = SALOMEDS::AttributeComment::_narrow(anAttr);
+ if (anIter->Value()->FindAttribute(anAttr,"AttributeString")) {
+ SALOMEDS::AttributeString_var aCmnt = SALOMEDS::AttributeString::_narrow(anAttr);
CORBA::String_var aString = aCmnt->Value();
string aValue(aString);
if (aValue == theComment) {
@@ -308,8 +308,8 @@
aPRef->SetValue(thePersistentRef);
}
if(strcmp(theComment,"") != 0){
- anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeComment");
- SALOMEDS::AttributeComment_var aCmnt = SALOMEDS::AttributeComment::_narrow(anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeString");
+ SALOMEDS::AttributeString_var aCmnt = SALOMEDS::AttributeString::_narrow(anAttr);
aCmnt->SetValue(theComment);
if(MYDEBUG) INFOS("CreateAttributes - Comment = "<SetValue(thePersistentRef);
}
if (strcmp(theComment, "") != 0) {
- anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeComment");
- _PTR(AttributeComment) aCmnt (anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeString");
+ _PTR(AttributeString) aCmnt (anAttr);
aCmnt->SetValue(theComment);
if (MYDEBUG) INFOS("CreateAttributes - Comment = " << theComment);
}
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.cxx,v
retrieving revision 1.17
retrieving revision 1.17.2.2
diff -c -u -r1.17 -r1.17.2.2
--- VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.cxx 1 Jun 2006 11:36:05 -0000 1.17
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.cxx 19 Oct 2006 13:49:20 -0000 1.17.2.2
@@ -173,6 +173,30 @@
return VISU::eNONE;
}
+ //---------------------------------------------------------------
+ medGeometryElement
+ VISUGeomToMED(int theGeom)
+ {
+ switch(theGeom){
+ case VISU::ePOINT1: return MED_POINT1;
+ case VISU::eSEG2: return MED_SEG2;
+ case VISU::eTRIA3: return MED_TRIA3;
+ case VISU::eQUAD4: return MED_QUAD4;
+ case VISU::eTETRA4: return MED_TETRA4;
+ case VISU::eHEXA8: return MED_HEXA8;
+ case VISU::ePENTA6: return MED_PENTA6;
+ case VISU::ePYRA5: return MED_PYRA5;
+
+ case VISU::eSEG3: return MED_SEG3;
+ case VISU::eTRIA6: return MED_TRIA6;
+ case VISU::eQUAD8: return MED_QUAD8;
+ case VISU::eTETRA10: return MED_TETRA10;
+ case VISU::eHEXA20: return MED_HEXA20;
+ case VISU::ePENTA15: return MED_PENTA15;
+ case VISU::ePYRA13: return MED_PYRA13;
+ }
+ return medGeometryElement(-1);
+ }
//---------------------------------------------------------------
medGeometryElement
@@ -317,7 +341,212 @@
return aMeshOnEntity;
}
-
+
+
+ PCSubProfile
+ CrSubProfile(const VISU::PCMesh theMesh,
+ const VISU::PCField theField,
+ const VISU::TCMeshOnEntity& theMeshOnEntity,
+ SALOME_MED::medGeometryElement theMGeom,
+ // SALOME_MED::long_array_var theGeom2Profile)
+ int nbElts)
+ {
+ if (MYDEBUG) MESSAGE("CrSubProfile");
+ VISU::EGeometry aEGeom = MEDGeom2VISU(theMGeom);
+ vtkIdType aVNbNodes = VISUGeom2NbNodes(aEGeom);
+
+ PCSubProfile aSubProfile(new TCSubProfile());
+ aSubProfile->myGeom = aEGeom;
+ aSubProfile->myMGeom = theMGeom;
+ aSubProfile->myStatus = eAddAll;
+ if(MYDEBUG) MESSAGE("theMGeom = "<myStatus = eRemoveAll;
+ else if( aTimeStampIter == (theMeshOnEntity.myCellsFirstIndex).end() &&
+ theMGeom == SALOME_MED::MED_POINT1)
+ {
+ if(nbElts>0){
+ aSubProfile->myName = "";
+ aSubProfile->myStatus = eAddPart;
+
+ aSubProfile->myNbCells = nbElts;
+ aSubProfile->myCellsSize = aSubProfile->myNbCells;
+ }
+ }
+ else
+ {
+ if(nbElts>0){
+ aSubProfile->myName = "";
+ aSubProfile->myStatus = eAddPart;
+
+ aSubProfile->myNbCells = nbElts;
+ aSubProfile->myCellsSize = aSubProfile->myNbCells*aVNbNodes;
+ }
+ }
+
+ if (MYDEBUG) MESSAGE("CrSubProfile done");
+ return aSubProfile;
+ }
+
+ TProfileKey
+ GetProfileKey(const VISU::PCMesh theMesh,
+ const VISU::PCField theField,
+ const VISU::PCValForTime theValForTime,
+ const VISU::TCMeshOnEntity& theMeshOnEntity)
+ {
+ if (MYDEBUG) MESSAGE("GetProfileKey");
+
+ TProfileKey aProfileKey;
+
+ const TCellsFirstIndex& aFirstIndex = theMeshOnEntity.myCellsFirstIndex;
+ TCellsFirstIndex::const_iterator anIter = aFirstIndex.begin();
+ int aNbElts = 0;
+ if(anIter==aFirstIndex.end() &&
+ (theValForTime->myField->getSupport()->getEntity() == SALOME_MED::MED_NODE))
+ {
+ SALOME_MED::medGeometryElement aMGeom = SALOME_MED::MED_POINT1;
+
+ try{
+ aNbElts = theValForTime->myField->getSupport()->getNumberOfElements(SALOME_MED::MED_NONE);
+ if(MYDEBUG)MESSAGE("aMGeom="<myField->getSupport()->getNumberOfElements(aMGeom);");
+ }
+
+ PCSubProfile aSubProfile = CrSubProfile(theMesh,
+ theField,
+ theMeshOnEntity,
+ aMGeom,
+ aNbElts);
+ aProfileKey.insert(aSubProfile);
+ }
+
+ for(; anIter != aFirstIndex.end(); anIter++){
+ SALOME_MED::medGeometryElement aMGeom = anIter->first;
+ try{
+ aNbElts = theValForTime->myField->getSupport()->getNumberOfElements(aMGeom);
+ if(MYDEBUG)MESSAGE("aMGeom="<myField->getSupport()->getNumberOfElements(aMGeom);");
+ continue;
+ }
+ PCSubProfile aSubProfile = CrSubProfile(theMesh,
+ theField,
+ theMeshOnEntity,
+ aMGeom,
+ aNbElts);
+ aProfileKey.insert(aSubProfile);
+ }
+
+ if (MYDEBUG) MESSAGE("GetProfileKey done");
+ return aProfileKey;
+ }
+
+ void
+ InitProfile(VISU::PCMesh theMesh,
+ VISU::PCField theField,
+ VISU::PCValForTime theValForTime,
+ VISU::TCMeshOnEntity& theMeshOnEntity)
+ {
+ if (MYDEBUG) MESSAGE("InitProfile");
+
+ TProfileMap& aProfileMap = theMeshOnEntity.myProfileMap;
+
+ TProfileKey aProfileKey = GetProfileKey(theMesh,
+ theField,
+ theValForTime,
+ theMeshOnEntity);
+
+ TProfileMap::const_iterator anIter = aProfileMap.find(aProfileKey);
+ if(anIter != aProfileMap.end()){
+ theValForTime->myProfile = anIter->second;
+ if(MYDEBUG) MESSAGE("aProfileMap.find(aProfileKey) aProfile->myGeom=");
+ }else{
+ PCProfile aProfile(new TCProfile());
+ TGeom2SubProfile& aGeom2SubProfile = aProfile->myGeom2SubProfile;
+
+ TProfileKey::const_iterator anIter = aProfileKey.begin();
+ for(; anIter != aProfileKey.end(); anIter++){
+ PCSubProfile aSubProfile(*anIter);
+
+ if(aProfile->myIsAll && aSubProfile->myStatus != eAddAll)
+ aProfile->myIsAll = false;
+
+ VISU::EGeometry aEGeom = aSubProfile->myGeom;
+ aGeom2SubProfile[aEGeom] = aSubProfile;
+ }
+
+ aProfileMap[aProfileKey] = aProfile;
+ theValForTime->myProfile = aProfile;
+ }
+ if (MYDEBUG) MESSAGE("InitProfile done");
+ }
+
+ void
+ LoadProfile(VISU::PCMesh theMesh,
+ VISU::PCField theField,
+ VISU::PCValForTime theValForTime,
+ VISU::PCMeshOnEntity theMeshOnEntity)
+ {
+ PCProfile aProfile = theValForTime->myProfile;
+ if (MYDEBUG) MESSAGE("LoadProfile aProfile->myIsDone="<myIsDone);
+ if(aProfile->myIsDone)
+ return;
+
+ const TGeom2SubProfile& aGeom2SubProfile = aProfile->myGeom2SubProfile;
+ TGeom2SubProfile::const_iterator aGeom2SubProfileIter = aGeom2SubProfile.begin();
+ if(aGeom2SubProfileIter==aGeom2SubProfile.end()){
+ MESSAGE("Warning! No geom 2 sub profile");
+ }
+ for(;aGeom2SubProfileIter!=aGeom2SubProfile.end();aGeom2SubProfileIter++){
+ VISU::EGeometry aEGeom = aGeom2SubProfileIter->first;
+ medGeometryElement aMGeom = VISUGeomToMED(aEGeom);
+ PCSubProfile aSubProfile = aGeom2SubProfileIter->second;
+ SALOME_MED::long_array_var aGeom2ProfileIds;
+ std::vector aGeom2Profile;
+ if(!theValForTime->myField->getSupport()->isOnAllElements()){
+ cout << __LINE__ << endl;
+ try{
+ if(aMGeom == SALOME_MED::MED_POINT1)
+ aGeom2ProfileIds = theValForTime->myField->getSupport()->getNumberFromFile(SALOME_MED::MED_NONE);
+ else
+ aGeom2ProfileIds = theValForTime->myField->getSupport()->getNumberFromFile(aMGeom);
+ int aLen = aGeom2ProfileIds->length();
+ if(MYDEBUG) MESSAGE(" - aMGeom="<" << anId << endl;
+ }
+ cout << endl;
+ } catch(...) {
+ continue;
+ }
+ } else {
+ cout << __LINE__ << endl;
+ SALOME_MED::medEntityMesh aMEntity = theValForTime->myField->getSupport()->getEntity();
+ int aNbElts = theMesh->myMesh->getNumberOfElements(aMEntity,aMGeom);
+ for(int i=0;i0){
+ TSubMeshID& aSubMeshID = aSubProfile->mySubMeshID;
+ int aSize = aGeom2Profile.size();
+ aSubMeshID.resize(aSize);
+
+
+ for(int anId = 0; anId < aSize; anId++){
+ aSubMeshID[anId] = aGeom2Profile[anId]-1; // ENKENKENKENKENEKENKENKN
+ }
+ }
+
+ }
+
+
+ aProfile->myIsDone = true;
+ if (MYDEBUG) MESSAGE("LoadProfile done");
+ }
}
@@ -1014,6 +1243,7 @@
TCell2Connect& aCell2Connect = aSubMesh->myCell2Connect;
aCell2Connect.resize(aNbElem);
+ if(MYDEBUG) MESSAGE("LoadPoints - aNbElem="<myNbComp;
- if(theField->myEntity == NODE_ENTITY){
- VISU::EGeometry aEGeom = VISU::ePOINT1;
- int aNbGauss = theValForTime->GetNbGauss(aEGeom);
- const TNamedPointCoords& aCoords = theMesh->myNamedPointCoords;
- int aNbElem = aCoords.GetNbPoints();
-
- if(MYDEBUG) MESSAGE("ImportField - aNbElem = "<GetMeshValue(VISU::ePOINT1);
- aMeshValue.Init(aNbElem,aNbGauss,aNbComp);
- for(int iElem = 0, anId = 0; iElem < aNbElem; iElem++){
- TValueSliceArr aValueSliceArr = aMeshValue.GetGaussValueSliceArr(iElem);
- for(int iGauss = 0; iGauss < aNbGauss; iGauss++){
- TValueSlice& aValueSlice = aValueSliceArr[iGauss];
- for(int iComp = 0; iComp < aNbComp; iComp++){
- aValueSlice[iComp] = theArray[anId++];
+
+ if(MYDEBUG) MESSAGE("- aNbComp = "<mySupport->getName();
+
+ if(theMeshOnEntity->mySupport->isOnAllElements() &&
+ strcmp(aSupportName.in(),"SupportOnAll_MED_") > 0){
+
+ if(theField->myEntity == NODE_ENTITY){
+ VISU::EGeometry aEGeom = VISU::ePOINT1;
+ int aNbGauss = theValForTime->GetNbGauss(aEGeom);
+ const TNamedPointCoords& aCoords = theMesh->myNamedPointCoords;
+ int aNbElem = aCoords.GetNbPoints();
+
+ if(MYDEBUG) MESSAGE("ImportField - aNbElem = "<GetMeshValue(VISU::ePOINT1);
+ aMeshValue.Init(aNbElem,aNbGauss,aNbComp);
+ for(int iElem = 0, anId = 0; iElem < aNbElem; iElem++){
+ TValueSliceArr aValueSliceArr = aMeshValue.GetGaussValueSliceArr(iElem);
+ for(int iGauss = 0; iGauss < aNbGauss; iGauss++){
+ TValueSlice& aValueSlice = aValueSliceArr[iGauss];
+ for(int iComp = 0; iComp < aNbComp; iComp++){
+ aValueSlice[iComp] = theArray[anId++];
+ }
+ }
+ }
+ } else {
+ SALOME_MED::medGeometryElement* aGeomElems;
+ const TEntity& aVEntity = theField->myEntity;
+ int iGeomEnd = GetEntity2Geom(aVEntity,aGeomElems);
+ for(int iGeom = 0; iGeom < iGeomEnd; iGeom++){
+ SALOME_MED::medGeometryElement aMGeom = aGeomElems[iGeom];
+ VISU::EGeometry aEGeom = MEDGeom2VISU(aMGeom);
+ int aNbGauss = theValForTime->GetNbGauss(aEGeom);
+ const TCellsFirstIndex& aCellsFirstIndex = theMeshOnEntity->myCellsFirstIndex;
+ TCellsFirstIndex::const_iterator aCellsFirstIndexIter = aCellsFirstIndex.find(aMGeom);
+ if(aCellsFirstIndexIter != aCellsFirstIndex.end()){
+ const TIndexAndSize& aIndexAndSize = aCellsFirstIndexIter->second;
+ if(MYDEBUG)
+ MESSAGE("ImportField - aMGeom = "<GetMeshValue(aEGeom);
+ aMeshValue.Init(aNbElem,aNbGauss,aNbComp);
+ for(int iElem = 0, anId = 0; iElem < aNbElem; iElem++, anId += aNbComp){
+ TValueSliceArr aValueSliceArr = aMeshValue.GetGaussValueSliceArr(iElem);
+ for(int iGauss = 0; iGauss < aNbGauss; iGauss++){
+ TValueSlice& aValueSlice = aValueSliceArr[iGauss];
+ for(int iComp = 0; iComp < aNbComp; iComp++)
+ aValueSlice[iComp] = theArray[aStart+anId+iComp];
+ }
+ }
}
}
}
- }else{
- SALOME_MED::medGeometryElement* aGeomElems;
- const TEntity& aVEntity = theField->myEntity;
- int iGeomEnd = GetEntity2Geom(aVEntity,aGeomElems);
- for(int iGeom = 0; iGeom < iGeomEnd; iGeom++){
- SALOME_MED::medGeometryElement aMGeom = aGeomElems[iGeom];
- VISU::EGeometry aEGeom = MEDGeom2VISU(aMGeom);
+ return 1;
+ }
+
+ if(MYDEBUG) MESSAGE("Loading profile");
+ theField->myDataSize = 0;
+
+ InitProfile(theMesh,theField,theValForTime,theMeshOnEntity);
+
+ LoadProfile(theMesh,theField,theValForTime,theMeshOnEntity);
+
+ PCProfile aProfile = theValForTime->myProfile;
+ TGeom2SubProfile& aGeom2SubProfile = aProfile->myGeom2SubProfile;
+
+ TGeom2SubProfile::const_iterator anIter = aGeom2SubProfile.begin();
+ for(; anIter != aGeom2SubProfile.end(); anIter++){
+ VISU::EGeometry aEGeom = anIter->first;
+ PCSubProfile aSubProfile(anIter->second);
+
+ int aNbElem = aSubProfile->myNbCells;
+ theField->myDataSize += aNbElem*aNbComp;
+
+ if(aSubProfile->myStatus != eRemoveAll){
int aNbGauss = theValForTime->GetNbGauss(aEGeom);
- const TCMeshOnEntity::TCellsFirstIndex& aCellsFirstIndex = theMeshOnEntity->myCellsFirstIndex;
- TCMeshOnEntity::TCellsFirstIndex::const_iterator aCellsFirstIndexIter = aCellsFirstIndex.find(aMGeom);
- if(aCellsFirstIndexIter != aCellsFirstIndex.end()){
- const TCMeshOnEntity::TIndexAndSize& aIndexAndSize = aCellsFirstIndexIter->second;
- if(MYDEBUG)
- MESSAGE("ImportField - aMGeom = "<GetMeshValue(aEGeom);
- aMeshValue.Init(aNbElem,aNbGauss,aNbComp);
- for(int iElem = 0, anId = 0; iElem < aNbElem; iElem++, anId += aNbComp){
- TValueSliceArr aValueSliceArr = aMeshValue.GetGaussValueSliceArr(iElem);
- for(int iGauss = 0; iGauss < aNbGauss; iGauss++){
- TValueSlice& aValueSlice = aValueSliceArr[iGauss];
- for(int iComp = 0; iComp < aNbComp; iComp++)
- aValueSlice[iComp] = theArray[aStart+anId+iComp];
+
+ if(MYDEBUG) MESSAGE("- aEGeom = "<myIDMapperFilter;
if(anIDMapperFilter->myIsVTKDone)
@@ -1339,6 +1622,11 @@
theValForTime->myProfile = aProfile;
SALOME_MED::FIELD_var aMEDField = theValForTime->myField;
+
+ SALOME_MED::SUPPORT_var aMEDSupport = aMEDField->getSupport();
+
+ if(aMEDSupport->isOnAllElements()) aProfile->myIsDone = true;
+
SALOME_MED::FIELDDOUBLE_ptr aFieldDouble = SALOME_MED::FIELDDOUBLE::_narrow(aMEDField);
if(!aFieldDouble->_is_nil()){
SALOME_MED::double_array_var anArray = aFieldDouble->getValue(SALOME_MED::MED_FULL_INTERLACE);
@@ -1354,5 +1642,6 @@
anIDMapperFilter->myIsVTKDone = true;
+ MESSAGE("VISU_MEDConvertor::LoadField done");
return 1;
}
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.hxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.hxx,v
retrieving revision 1.13
retrieving revision 1.13.2.1
diff -c -u -r1.13 -r1.13.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.hxx 1 Jun 2006 11:36:05 -0000 1.13
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_CorbaMedConvertor.hxx 17 Oct 2006 13:11:26 -0000 1.13.2.1
@@ -37,6 +37,8 @@
namespace VISU
{
+ typedef std::pair TIndexAndSize; //
+ typedef std::map TCellsFirstIndex; // key: SALOME_MED::medGeometryElement
//---------------------------------------------------------------
struct TCMesh: virtual TMeshImpl
{
@@ -44,16 +46,40 @@
};
typedef SharedPtr PCMesh;
+ //---------------------------------------------------------------
+ struct TCSubProfile: virtual TSubProfileImpl
+ {
+ SALOME_MED::medGeometryElement myMGeom;
+ };
+ typedef SharedPtr PCSubProfile;
//---------------------------------------------------------------
struct TCProfile: virtual TProfileImpl
{};
typedef SharedPtr PCProfile;
+ //---------------------------------------------------------------
+ struct TCGauss: virtual TGaussImpl
+ {
+ };
+ typedef SharedPtr PCGauss;
+
+ struct TCGaussSubMesh: virtual TGaussSubMeshImpl
+ {
+ };
+ typedef SharedPtr PCGaussSubMesh;
+
//---------------------------------------------------------------
- struct TCSubMesh: virtual TSubMeshImpl
+ struct TCGaussMesh: virtual TGaussMeshImpl
{};
+ typedef SharedPtr PCGaussMesh;
+
+
+ //---------------------------------------------------------------
+ struct TCSubMesh: virtual TSubMeshImpl
+ {
+ };
typedef SharedPtr PCSubMesh;
@@ -61,8 +87,6 @@
struct TCMeshOnEntity: virtual TMeshOnEntityImpl
{
SALOME_MED::SUPPORT_var mySupport;
- typedef std::pair TIndexAndSize;
- typedef std::map TCellsFirstIndex;
TCellsFirstIndex myCellsFirstIndex;
};
typedef SharedPtr PCMeshOnEntity;
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.cc,v
retrieving revision 1.12
retrieving revision 1.12.2.1
diff -c -u -r1.12 -r1.12.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.cc 1 Jun 2006 11:36:05 -0000 1.12
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.cc 20 Oct 2006 06:54:01 -0000 1.12.2.1
@@ -67,7 +67,8 @@
Prs3d_i(theResult,theAddToStudy),
ColoredPrs3d_i(theResult,theAddToStudy),
ScalarMap_i(theResult,theAddToStudy),
- myCutLinesPL(NULL)
+ myCutLinesPL(NULL),
+ myUseAbsLength(false)
{}
@@ -78,7 +79,8 @@
Prs3d_i(theResult,theSObject),
ColoredPrs3d_i(theResult,theSObject),
ScalarMap_i(theResult,theSObject),
- myCutLinesPL(NULL)
+ myCutLinesPL(NULL),
+ myUseAbsLength(false)
{
}
@@ -93,7 +95,12 @@
VISU::Storable* VISU::CutLines_i::Create(const char* theMeshName, VISU::Entity theEntity,
const char* theFieldName, int theIteration)
{
- return ScalarMap_i::Create(theMeshName,theEntity,theFieldName,theIteration);
+ TSuperClass::Create(theMeshName,theEntity,theFieldName,theIteration);
+ SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr();
+ SetAllCurvesInverted( aResourceMgr->booleanValue("VISU", "invert_all_curves", false) );
+ SetUseAbsoluteLength( aResourceMgr->booleanValue("VISU", "use_absolute_length", false) );
+
+ return this;
}
@@ -110,6 +117,8 @@
SetOrientation2(CutPlanes::Orientation(VISU::Storable::FindValue(theMap,"myBasePlane[1]").toInt()),
Storable::FindValue(theMap,"aRot[1][0]").toDouble(),
Storable::FindValue(theMap,"aRot[1][1]").toDouble());
+ SetUseAbsoluteLength(VISU::Storable::FindValue(theMap,"myUseAbsLength").toInt());
+
if (VISU::Storable::FindValue(theMap,"myBasePlaneCondition").toInt())
SetDefault();
else
@@ -161,8 +170,10 @@
aStrPos.append(QString::number(GetLinePosition(i)) + "|");
aStrCon.append(QString::number(IsDefaultPosition(i)) + "|");
}
+
Storable::DataToStream( theStr, "myLinePosition", aStrPos.latin1());
Storable::DataToStream( theStr, "myLineCondition", aStrCon.latin1());
+ Storable::DataToStream( theStr,"myUseAbsLength", IsUseAbsoluteLength());
// Storing the map - \a myMapCurvesInverted
QString aStrCurvesInverted;
@@ -284,6 +295,13 @@
myMapCurvesInverted[theCurveNumber] = theInvert;
}
+/*! It control the way the length of cutlines is shown: using aboslute or relative values
+* \param theAbsLength - boolean value, TRUE or false.
+*/
+void VISU::CutLines_i::SetUseAbsoluteLength(CORBA::Boolean theAbsLength){
+ myUseAbsLength = theAbsLength;
+}
+
/*! Checks orientation of curve.
* \param theCurveNumber - integer value, number of cut line.
* \retval TRUE - if line in the table is inverted, else FALSE.
@@ -369,7 +387,11 @@
if(MYDEBUG) MESSAGE("CutPlanes_i::BuildTableOfReal iLine = "<(theOrigin)){
+ CutLines_i* anOrigin = const_cast(aPrs3d);
+ myUseAbsLength = anOrigin->IsUseAbsoluteLength();
+ CopyCurvesInverted(anOrigin->GetCurvesInverted());
+ }
+}
+
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.hh
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.hh,v
retrieving revision 1.8
retrieving revision 1.8.2.1
diff -c -u -r1.8 -r1.8.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.hh 1 Jun 2006 11:36:05 -0000 1.8
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_CutLines_i.hh 20 Oct 2006 06:54:01 -0000 1.8.2.1
@@ -89,6 +89,9 @@
virtual void SetCurveInverted(CORBA::Long theCurveNumber,CORBA::Boolean theInvert);
virtual CORBA::Boolean IsCurveInverted(CORBA::Long theCurveNumber);
+ virtual void SetUseAbsoluteLength(CORBA::Boolean theAbsLength);
+ virtual CORBA::Boolean IsUseAbsoluteLength() {return myUseAbsLength;}
+
virtual void SetNbLines(CORBA::Long theNb);
virtual CORBA::Long GetNbLines();
typedef VISU::CutLines TInterface;
@@ -103,6 +106,7 @@
VISU_CutLinesPL *myCutLinesPL;
TCurvesInv myMapCurvesInverted;
+ CORBA::Boolean myUseAbsLength;
public:
static int IsPossible(Result_i* theResult, const char* theMeshName, VISU::Entity theEntity,
@@ -113,6 +117,7 @@
virtual void ToStream(std::ostringstream& theStr);
virtual Storable* Restore(const Storable::TRestoringMap& theMap);
+ virtual void SameAs( const Prs3d_i* Origin );
virtual
VISU_Actor*
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_DumpPython.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_DumpPython.cc,v
retrieving revision 1.8.2.2
retrieving revision 1.8.2.4
diff -c -u -r1.8.2.2 -r1.8.2.4
--- VISU_SRC_3.2.2/src/VISU_I/VISU_DumpPython.cc 22 Aug 2006 05:31:48 -0000 1.8.2.2
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_DumpPython.cc 17 Oct 2006 10:37:39 -0000 1.8.2.4
@@ -299,9 +299,9 @@
{
SALOMEDS::GenericAttribute_var anAttr;
SALOMEDS::SObject_var aFatherSObject = theSObject->GetFather();
- if(aFatherSObject->FindAttribute(anAttr,"AttributeComment")){
- SALOMEDS::AttributeComment_var aComment =
- SALOMEDS::AttributeComment::_narrow(anAttr);
+ if(aFatherSObject->FindAttribute(anAttr,"AttributeString")){
+ SALOMEDS::AttributeString_var aComment =
+ SALOMEDS::AttributeString::_narrow(anAttr);
CORBA::String_var aValue = aComment->Value();
Storable::TRestoringMap aMap;
Storable::StrToMap(aValue.in(),aMap);
@@ -1013,9 +1013,9 @@
case VISU::TTABLE:
if(dynamic_cast(GetServant(anObj).in())){
SALOMEDS::GenericAttribute_var anAttr;
- if(theSObject->FindAttribute(anAttr,"AttributeComment")){
+ if(theSObject->FindAttribute(anAttr,"AttributeString")){
using namespace SALOMEDS;
- AttributeComment_var aComment = AttributeComment::_narrow(anAttr);
+ AttributeString_var aComment = AttributeString::_narrow(anAttr);
CORBA::String_var aValue = aComment->Value();
Storable::TRestoringMap aMap;
Storable::StrToMap(aValue.in(),aMap);
@@ -1100,9 +1100,9 @@
}
} else { /*if(!CORBA::is_nil(anObj))*/
SALOMEDS::GenericAttribute_var anAttr;
- if (theSObject->FindAttribute(anAttr,"AttributeComment")) {
- SALOMEDS::AttributeComment_var aComment =
- SALOMEDS::AttributeComment::_narrow(anAttr);
+ if (theSObject->FindAttribute(anAttr,"AttributeString")) {
+ SALOMEDS::AttributeString_var aComment =
+ SALOMEDS::AttributeString::_narrow(anAttr);
CORBA::String_var aValue = aComment->Value();
Storable::TRestoringMap aMap;
Storable::StrToMap(aValue.in(),aMap);
@@ -1141,7 +1141,7 @@
theStr<
#include CORBA_SERVER_HEADER(SALOME_Session)
#include CORBA_SERVER_HEADER(SALOME_ModuleCatalog)
+#include CORBA_SERVER_HEADER(MED_Gen)
// QT Includes
#include
@@ -291,11 +292,25 @@
if(MYDEBUG) MESSAGE("VISU_Gen_i::~VISU_Gen_i");
}
- void CorrectSObjectType(SALOMEDS::SObject_ptr theSObject)
+ void CorrectSObjectType(SALOMEDS::SObject_ptr theSObject, SALOMEDS::StudyBuilder_ptr theBuilder)
{
SALOMEDS::GenericAttribute_var anAttr;
- if ( theSObject->FindAttribute(anAttr, "AttributeComment") ) {
- SALOMEDS::AttributeComment_var aAttComment = SALOMEDS::AttributeComment::_narrow(anAttr);
+ bool isAttrStringFound = false;
+
+ if( theSObject->FindAttribute(anAttr, "AttributeComment") ) {
+ //SRN: Replace an AttributeComment with AttributeString
+ SALOMEDS::AttributeComment_var aComment = SALOMEDS::AttributeComment::_narrow(anAttr);
+ string aValue = aComment->Value();
+ theBuilder->RemoveAttribute(theSObject, "AttributeComment");
+ anAttr = theBuilder->FindOrCreateAttribute(theSObject, "AttributeString");
+ SALOMEDS::AttributeString_var aStringAttr = SALOMEDS::AttributeString::_narrow(anAttr);
+ aStringAttr->SetValue(aValue.c_str());
+ isAttrStringFound = true;
+
+ }
+
+ if ( isAttrStringFound || theSObject->FindAttribute(anAttr, "AttributeString") ) {
+ SALOMEDS::AttributeString_var aAttComment = SALOMEDS::AttributeString::_narrow(anAttr);
if ( aAttComment ) {
string aValue = aAttComment->Value();
if ( aValue.compare("") ) {
@@ -360,12 +375,14 @@
SALOMEDS::Study_var aStudy = theComponent->GetStudy();
SALOMEDS::ChildIterator_var anIter = aStudy->NewChildIterator(theComponent);
+ SALOMEDS::StudyBuilder_var aStudyBuilder = aStudy->NewBuilder();
+
for (anIter->InitEx(true); anIter->More(); anIter->Next()) {
SALOMEDS::SObject_var aSObject = anIter->Value();
- CorrectSObjectType(aSObject);
+ CorrectSObjectType(aSObject, aStudyBuilder);
}
- SALOMEDS::StudyBuilder_var aStudyBuilder = aStudy->NewBuilder();
+
string aDir = isMultiFile ? theURL : SALOMEDS_Tool::GetTmpDir();
TCollection_AsciiString aTmpDir (const_cast(aDir.c_str()));
VisuTmpDir = aTmpDir.ToCString();
@@ -593,6 +610,20 @@
myStudyDocument = SALOMEDS::Study::_duplicate(theStudy);
ProcessVoidEvent(new TEvent(aStudyName));
+
+ // Load MED component if necessary
+ if(!myStudyDocument->FindComponent("MED")->_is_nil())
+ {
+ SALOME_LifeCycleCORBA aLCC(SalomeApp_Application::namingService());
+ Engines::Component_var aComponent = aLCC.FindOrLoad_Component("FactoryServer","MED");
+ SALOME_MED::MED_Gen_var aMedEngine = SALOME_MED::MED_Gen::_narrow(aComponent);
+
+ if(!CORBA::is_nil(aMedEngine))
+ {
+ SALOMEDS::StudyBuilder_var aStudyBuilder = myStudyDocument->NewBuilder();
+ aStudyBuilder->LoadWith( myStudyDocument->FindComponent( "MED" ), aMedEngine );
+ }
+ }
} else {
INFOS("CORBA::is_nil(theStudy)");
}
@@ -1173,7 +1204,7 @@
aResultSO = SALOMEDS::SObject::_duplicate(theObject);
//Just for Result::Restore to find the Comment attribute :(
- SALOMEDS::GenericAttribute_var anAttr = aStudyBuilder->FindOrCreateAttribute(aResultSO, "AttributeComment");
+ SALOMEDS::GenericAttribute_var anAttr = aStudyBuilder->FindOrCreateAttribute(aResultSO, "AttributeString");
Storable* aStorable = Storable::Create(aResultSO,aFileName,aString);
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_Prs3d_i.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_Prs3d_i.cc,v
retrieving revision 1.14
retrieving revision 1.14.2.1
diff -c -u -r1.14 -r1.14.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_Prs3d_i.cc 1 Jun 2006 11:36:05 -0000 1.14
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_Prs3d_i.cc 26 Sep 2006 09:43:12 -0000 1.14.2.1
@@ -91,18 +91,36 @@
}
}
+struct TRemoveActorsFromRendererEvent: public SALOME_Event
+{
+ typedef boost::signal0 TRemoveActorsFromRendererSignalType;
+ const TRemoveActorsFromRendererSignalType& myRemoveActorsFromRendererSignalVar;
+
+ TRemoveActorsFromRendererEvent
+ (const TRemoveActorsFromRendererSignalType& theRemoveActorsFromRendererSignalVar):
+ myRemoveActorsFromRendererSignalVar(theRemoveActorsFromRendererSignalVar)
+ {}
+
+ virtual
+ void
+ Execute()
+ {
+ myRemoveActorsFromRendererSignalVar();
+ }
+};
+
VISU::Prs3d_i
-::~Prs3d_i()
+::~Prs3d_i()
{
if(MYDEBUG) MESSAGE("Prs3d_i::~Prs3d_i - this = "<Delete();
myResult->Destroy();
}
//----------------------------------------------------------------------------
-VISU::Storable*
+VISU::Storable*
VISU::Prs3d_i
::Restore(const Storable::TRestoringMap& theMap)
{
@@ -125,7 +143,7 @@
//----------------------------------------------------------------------------
-SALOMEDS::SObject_var
+SALOMEDS::SObject_var
VISU::Prs3d_i
::GetSObject()
{
@@ -137,25 +155,25 @@
return mySObject;
}
-Result_i*
+Result_i*
VISU::Prs3d_i
-::GetResult() const
-{
+::GetResult() const
+{
return myResult;
}
-const std::string&
+const std::string&
VISU::Prs3d_i
-::GetMeshName() const
-{
- return myMeshName;
+::GetMeshName() const
+{
+ return myMeshName;
}
//----------------------------------------------------------------------------
void
VISU::Prs3d_i
-::Update()
+::Update()
{
if(MYDEBUG) MESSAGE("Prs3d_i::Update - this = "<GetMapper();
vtkDataSet *aDataSet = aMapper->GetInput();
@@ -185,7 +203,7 @@
void
VISU::Prs3d_i
-::RemoveFromStudy()
+::RemoveFromStudy()
{
struct TRemoveFromStudy: public SALOME_Event
{
@@ -198,7 +216,7 @@
myRemovable(theRemovable),
myRemoveFromStudySignal(theRemoveFromStudySignal)
{}
-
+
virtual
void
Execute()
@@ -213,21 +231,21 @@
//----------------------------------------------------------------------------
-VISU_PipeLine*
+VISU_PipeLine*
VISU::Prs3d_i
::GetPipeLine()
{
return GetPL();
}
-VISU_PipeLine*
+VISU_PipeLine*
VISU::Prs3d_i
::GetPL()
{
return myPipeLine;
}
-vtkUnstructuredGrid*
+vtkUnstructuredGrid*
VISU::Prs3d_i::
GetInput()
{
@@ -274,7 +292,7 @@
void
VISU::Prs3d_i
-::RemoveActor(VISU_Actor* theActor)
+::RemoveActor(VISU_Actor* theActor)
{
if(MYDEBUG) MESSAGE("Prs3d_i::RemoveActor - this = "<FindOrCreateAttribute(aNewObj, "AttributeComment");
- _PTR(AttributeComment) aCmnt (anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(aNewObj, "AttributeString");
+ _PTR(AttributeString) aCmnt (anAttr);
aCmnt->SetValue(theComment);
}
return aNewObj->GetID();
@@ -281,8 +281,8 @@
aName->SetValue(theName);
}
if (theComment != "") {
- anAttr = aStudyBuilder->FindOrCreateAttribute(aSObject, "AttributeComment");
- _PTR(AttributeComment) aCmnt (anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(aSObject, "AttributeString");
+ _PTR(AttributeString) aCmnt (anAttr);
aCmnt->SetValue(theComment);
}
}
@@ -1365,9 +1365,9 @@
GetComment(), VISU::TRESULT, myFileInfo.filePath().latin1(),
myInitFileName.c_str()); // Restoring of Python dump
SALOMEDS::GenericAttribute_var anAttr;
- if (!theSObject->FindAttribute(anAttr, "AttributeComment"))
- throw std::runtime_error("Build - There is no AttributeComment for the SObject !!!");
- SALOMEDS::AttributeComment_var aCmnt = SALOMEDS::AttributeComment::_narrow(anAttr);
+ if (!theSObject->FindAttribute(anAttr, "AttributeString"))
+ throw std::runtime_error("Build - There is no AttributeString for the SObject !!!");
+ SALOMEDS::AttributeString_var aCmnt = SALOMEDS::AttributeString::_narrow(anAttr);
aCmnt->SetValue(aComment.latin1());
}
bool anIsBuildAll = VISU::GetResourceMgr()->booleanValue("VISU", "full_med_loading", false);
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_Table_i.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_Table_i.cc,v
retrieving revision 1.15.2.1
retrieving revision 1.15.2.2
diff -c -u -r1.15.2.1 -r1.15.2.2
--- VISU_SRC_3.2.2/src/VISU_I/VISU_Table_i.cc 22 Aug 2006 05:31:48 -0000 1.15.2.1
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_Table_i.cc 17 Oct 2006 10:37:39 -0000 1.15.2.2
@@ -180,9 +180,9 @@
else{
aComment.sprintf("myComment=%s;myType=%d;mySourceId=TableAttr",GetComment(),VISU::TTABLE);
SALOMEDS::SObject_var aFatherSObject = SO->GetFather();
- if(aFatherSObject->FindAttribute(anAttr,"AttributeComment")){
- SALOMEDS::AttributeComment_var aCommentAttr =
- SALOMEDS::AttributeComment::_narrow(anAttr);
+ if(aFatherSObject->FindAttribute(anAttr,"AttributeString")){
+ SALOMEDS::AttributeString_var aCommentAttr =
+ SALOMEDS::AttributeString::_narrow(anAttr);
CORBA::String_var aValue = aCommentAttr->Value();
Storable::TRestoringMap aMap;
Storable::StrToMap(aValue.in(),aMap);
@@ -1248,8 +1248,8 @@
SALOMEDS::AttributeName_var aName = SALOMEDS::AttributeName::_narrow(anAttr);
QFileInfo aFileInfo(theFileName);
aName->SetValue(aFileInfo.fileName().latin1());
- anAttr = aStudyBuilder->FindOrCreateAttribute(aFileObject, "AttributeComment");
- SALOMEDS::AttributeComment_var aComment = SALOMEDS::AttributeComment::_narrow(anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(aFileObject, "AttributeString");
+ SALOMEDS::AttributeString_var aComment = SALOMEDS::AttributeString::_narrow(anAttr);
QString aString;
aString.sprintf("myComment=ImportTables;myFileName=%s",
aFileInfo.absFilePath().latin1());
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.cxx
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.cxx,v
retrieving revision 1.31.2.1
retrieving revision 1.31.2.3
diff -c -u -r1.31.2.1 -r1.31.2.3
--- VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.cxx 4 Sep 2006 11:35:20 -0000 1.31.2.1
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.cxx 23 Oct 2006 14:17:57 -0000 1.31.2.3
@@ -55,7 +55,7 @@
#include "SUIT_Session.h"
#include "SUIT_Study.h"
-#include "SALOMEDSClient_AttributeComment.hxx"
+#include "SALOMEDSClient_AttributeString.hxx"
#include "SALOMEDSClient_AttributeName.hxx"
#include
@@ -102,6 +102,7 @@
myTimeMax = 0;
myLastError = "";
myCycling = false;
+ myCleaningMemoryAtEachFrame = false;
myAnimEntry = "";
@@ -202,7 +203,6 @@
myView->update();
}
-
namespace
{
//------------------------------------------------------------------------
@@ -406,7 +406,7 @@
//------------------------------------------------------------------------
-CORBA::Boolean VISU_TimeAnimation::generateFrames() {
+CORBA::Boolean VISU_TimeAnimation::_generateFrames() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return false;
@@ -445,7 +445,14 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::clearView() {
+CORBA::Boolean VISU_TimeAnimation::generateFrames()
+{
+ return ProcessEvent(new TMemFunEvent
+ (this,&VISU_TimeAnimation::_generateFrames));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_clearView() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -466,12 +473,54 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::stopAnimation() {
+void VISU_TimeAnimation::clearView()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_clearView));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::visibilityOff(int num_field, int num_frame) {
+ FieldData& aData = myFieldsLst[num_field];
+ VISU_Actor* aActor = aData.myActors[num_frame];
+ if (! myCleaningMemoryAtEachFrame) {
+ //
+ // Usual behaviour : VisibilityOff()
+ // Problem : It don't clean the memory so if there is
+ // a lot of frames, the memory grows dramatically
+ //
+ aActor->VisibilityOff();
+ } else {
+ //
+ // myCleaningMemoryAtEachFrame behaviour:
+ // Delete the actor and re-creation it with VisibilityOff()
+ // since it takes memory only at VisibilityOn()
+ //
+ // Delete the actor
+ aActor->RemoveFromRender(myView->getRenderer());
+ //aActor->Delete();
+ // Re-create the actor
+ aActor = aData.myPrs[num_frame]->CreateActor();
+ myView->AddActor(aActor);
+ aActor->VisibilityOff();
+ aData.myActors[num_frame] = aActor;
+ }
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_stopAnimation() {
myIsActive = false;
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::startAnimation() {
+void VISU_TimeAnimation::stopAnimation()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_stopAnimation));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_startAnimation() {
if (!myIsActive) {
myIsActive = true;
QThread::start();
@@ -479,7 +528,15 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::nextFrame() {
+void VISU_TimeAnimation::startAnimation()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_startAnimation));
+}
+
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_nextFrame() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -489,7 +546,8 @@
int i;
for (i = 0; i < getNbFields(); i++)
if (myFieldsLst[i].myActors[myFrame] != 0)
- myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ //myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ visibilityOff(i, myFrame);
myFrame++;
for (i = 0; i < getNbFields(); i++)
@@ -502,7 +560,14 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::prevFrame() {
+void VISU_TimeAnimation::nextFrame()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_nextFrame));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_prevFrame() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -512,7 +577,8 @@
int i;
for (i = 0; i < getNbFields(); i++)
if (myFieldsLst[i].myActors[myFrame] != 0)
- myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ //myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ visibilityOff(i, myFrame);
myFrame--;
for (i = 0; i < getNbFields(); i++)
@@ -525,7 +591,14 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::firstFrame() {
+void VISU_TimeAnimation::prevFrame()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_prevFrame));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_firstFrame() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -535,7 +608,8 @@
for (i = 0; i < getNbFields(); i++)
if(!myFieldsLst[i].myActors.empty())
if (myFieldsLst[i].myActors[myFrame] != 0)
- myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ //myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ visibilityOff(i, myFrame);
myFrame = 0;
for (i = 0; i < getNbFields(); i++)
if(!myFieldsLst[i].myActors.empty())
@@ -548,7 +622,14 @@
}
//------------------------------------------------------------------------
-void VISU_TimeAnimation::lastFrame() {
+void VISU_TimeAnimation::firstFrame()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_firstFrame));
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::_lastFrame() {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -557,7 +638,8 @@
int i;
for (i = 0; i < getNbFields(); i++)
if (myFieldsLst[i].myActors[myFrame] != 0)
- myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ //myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ visibilityOff(i, myFrame);
myFrame = myFieldsLst[0].myNbFrames-1;
for (i = 0; i < getNbFields(); i++)
@@ -568,10 +650,17 @@
myView->Repaint();
}
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::lastFrame()
+{
+ ProcessVoidEvent(new TVoidMemFunEvent
+ (this,&VISU_TimeAnimation::_lastFrame));
+}
+
//------------------------------------------------------------------------
// For Batchmode using
-void VISU_TimeAnimation::gotoFrame(CORBA::Long theFrame) {
+void VISU_TimeAnimation::_gotoFrame(CORBA::Long theFrame) {
if (!myView) {
MESSAGE("Viewer is not defined for animation");
return;
@@ -579,12 +668,13 @@
if ((theFrame < 0) || (theFrame > (getNbFrames()-1)))
return;
stopAnimation();
- qApp->lock();
- qApp->syncX();
+ //qApp->lock();
+ //qApp->syncX();
int i;
for (i = 0; i < getNbFields(); i++)
if (myFieldsLst[i].myActors[myFrame] != 0)
- myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ //myFieldsLst[i].myActors[myFrame]->VisibilityOff();
+ visibilityOff(i, myFrame);
myFrame = theFrame;
for (i = 0; i < getNbFields(); i++)
@@ -593,9 +683,16 @@
emit frameChanged(myFrame, myFieldsLst[0].myTiming[myFrame]);
myView->Repaint();
- qApp->flushX();
- qApp->processEvents(3);
- qApp->unlock();
+ //qApp->flushX();
+ //qApp->processEvents(3);
+ //qApp->unlock();
+}
+
+//------------------------------------------------------------------------
+void VISU_TimeAnimation::gotoFrame(CORBA::Long theFrame)
+{
+ ProcessVoidEvent(new TVoidMemFun1ArgEvent
+ (this,&VISU_TimeAnimation::_gotoFrame,theFrame));
}
@@ -640,10 +737,12 @@
FieldData& aData = myFieldsLst[i];
if (myFrame > 0) {
if (aData.myActors[myFrame-1] != 0)
- aData.myActors[myFrame-1]->VisibilityOff();
+ //aData.myActors[myFrame-1]->VisibilityOff();
+ visibilityOff(i, myFrame-1);
} else {
if (aData.myActors[aData.myNbFrames-1] != 0)
- aData.myActors[aData.myNbFrames-1]->VisibilityOff();
+ //aData.myActors[aData.myNbFrames-1]->VisibilityOff();
+ visibilityOff(i, aData.myNbFrames-1);
}
if (aData.myActors[myFrame] != 0) {
aData.myActors[myFrame]->VisibilityOn();
@@ -675,12 +774,20 @@
}
qApp->unlock();
msleep(delay);
+ if (!myIsActive) {
+ emit stopped();
+ return;
+ }
qApp->lock();
if (isDumping) {
// We must unlock mutex for some time before grabbing to allow view updating
qApp->unlock();
msleep(delay);
+ if (!myIsActive) { // this check was taken from WP_DEB branch
+ emit stopped();
+ return;
+ }
qApp->lock();
if(!(myFieldsLst[0].myField)) // break, if field was deleted.
break;
@@ -823,8 +930,8 @@
VISU::Storable::TRestoringMap aMap;
if (theSObject) {
_PTR(GenericAttribute) anAttr;
- if (theSObject->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aComment (anAttr);
+ if (theSObject->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aComment (anAttr);
std::string aString = aComment->Value();
QString strIn (aString.c_str());
VISU::Storable::StrToMap(strIn, aMap);
@@ -990,8 +1097,8 @@
VISU::TANIMATION,myTimeMinVal,myTimeMaxVal);
_PTR(GenericAttribute) anAttr;
- anAttr = aStudyBuilder->FindOrCreateAttribute(aAnimSObject, "AttributeComment");
- _PTR(AttributeComment) aCmnt (anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(aAnimSObject, "AttributeString");
+ _PTR(AttributeString) aCmnt (anAttr);
aCmnt->SetValue(aComment.latin1());
_PTR(ChildIterator) anIter = myStudy->NewChildIterator(aAnimSObject);
@@ -1016,8 +1123,8 @@
if (anPrsIter->More()) {
_PTR(SObject) aPrsObj = anPrsIter->Value();
- anAttr = aStudyBuilder->FindOrCreateAttribute(aPrsObj, "AttributeComment");
- aCmnt = _PTR(AttributeComment)(anAttr);
+ anAttr = aStudyBuilder->FindOrCreateAttribute(aPrsObj, "AttributeString");
+ aCmnt = _PTR(AttributeString)(anAttr);
aCmnt->SetValue(aPrsComment.c_str());
anAttr = aStudyBuilder->FindOrCreateAttribute(aPrsObj, "AttributeName");
@@ -1045,9 +1152,9 @@
VISU::Storable::TRestoringMap aMap;
_PTR(GenericAttribute) anAttr;
- if (!aAnimSObject->FindAttribute(anAttr, "AttributeComment")) return;
+ if (!aAnimSObject->FindAttribute(anAttr, "AttributeString")) return;
- _PTR(AttributeComment) aComment (anAttr);
+ _PTR(AttributeString) aComment (anAttr);
string aComm = aComment->Value();
QString strIn (aComm.c_str());
VISU::Storable::StrToMap(strIn,aMap);
@@ -1098,8 +1205,8 @@
continue;
generatePresentations(getNbFields()-1);
- if (!aPrsObj->FindAttribute(anAttr, "AttributeComment")) continue;
- _PTR(AttributeComment) aPrsComment (anAttr);
+ if (!aPrsObj->FindAttribute(anAttr, "AttributeString")) continue;
+ _PTR(AttributeString) aPrsComment (anAttr);
string aPrsComm = aPrsComment->Value();
if (aPrsComm.length() > 0) {
QString strPrsIn (aPrsComm.c_str());
@@ -1183,8 +1290,9 @@
CORBA::Boolean VISU_TimeAnimation_i::generateFrames()
{
- return ProcessEvent(new TMemFunEvent
- (myAnim,&VISU_TimeAnimation::generateFrames));
+ //return ProcessEvent(new TMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::generateFrames));
+ return myAnim->generateFrames();
}
void VISU_TimeAnimation_i::generatePresentations (CORBA::Long theFieldNum)
@@ -1194,50 +1302,58 @@
void VISU_TimeAnimation_i::clearView()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::clearView));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::clearView));
+ myAnim->clearView();
}
void VISU_TimeAnimation_i::stopAnimation()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::stopAnimation));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::stopAnimation));
+ myAnim->stopAnimation();
}
void VISU_TimeAnimation_i::startAnimation()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::startAnimation));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::startAnimation));
+ myAnim->startAnimation();
}
void VISU_TimeAnimation_i::nextFrame()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::nextFrame));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::nextFrame));
+ myAnim->nextFrame();
}
void VISU_TimeAnimation_i::prevFrame()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::prevFrame));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::prevFrame));
+ myAnim->prevFrame();
}
void VISU_TimeAnimation_i::firstFrame()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::firstFrame));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::firstFrame));
+ myAnim->firstFrame();
}
void VISU_TimeAnimation_i::lastFrame()
{
- ProcessVoidEvent(new TVoidMemFunEvent
- (myAnim,&VISU_TimeAnimation::lastFrame));
+ //ProcessVoidEvent(new TVoidMemFunEvent
+ // (myAnim,&VISU_TimeAnimation::lastFrame));
+ myAnim->lastFrame();
}
void VISU_TimeAnimation_i::gotoFrame(CORBA::Long theFrame)
{
- ProcessVoidEvent(new TVoidMemFun1ArgEvent
- (myAnim,&VISU_TimeAnimation::gotoFrame,theFrame));
+ //ProcessVoidEvent(new TVoidMemFun1ArgEvent
+ // (myAnim,&VISU_TimeAnimation::gotoFrame,theFrame));
+ myAnim->gotoFrame(theFrame);
}
CORBA::Long VISU_TimeAnimation_i::getNbFields()
@@ -1329,6 +1445,10 @@
return myAnim->isCycling();
}
+CORBA::Boolean VISU_TimeAnimation_i::isCleaningMemoryAtEachFrame(){
+ return myAnim->isCleaningMemoryAtEachFrame();
+}
+
CORBA::Double VISU_TimeAnimation_i::getMinTime()
{
return myAnim->getMinTime();
@@ -1349,6 +1469,10 @@
myAnim->setCycling(theCycle);
}
+void VISU_TimeAnimation_i::setCleaningMemoryAtEachFrame(CORBA::Boolean theCycle){
+ myAnim->setCleaningMemoryAtEachFrame(theCycle);
+}
+
SALOMEDS::SObject_ptr VISU_TimeAnimation_i::publishInStudy()
{
return myAnim->publishInStudy();
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.h
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.h,v
retrieving revision 1.12
retrieving revision 1.12.2.1
diff -c -u -r1.12 -r1.12.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.h 1 Jun 2006 11:36:05 -0000 1.12
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_TimeAnimation.h 23 Oct 2006 14:17:57 -0000 1.12.2.1
@@ -57,6 +57,19 @@
class VISU_TimeAnimation: public QObject, public QThread
{
Q_OBJECT;
+
+ private:
+ // PAL8166
+ CORBA::Boolean _generateFrames();
+ void _clearView();
+ void _stopAnimation();
+ void _startAnimation();
+ void _nextFrame();
+ void _prevFrame();
+ void _firstFrame();
+ void _lastFrame();
+ void _gotoFrame(CORBA::Long theFrame);
+
public:
//static VISU::Result_i* createPresent (SALOMEDS::SObject_var theField);
//static VISU::Storable::TRestoringMap getMapOfValue (SALOMEDS::SObject_var theSObject);
@@ -84,6 +97,7 @@
void clearData(FieldData& theData);
void clearFieldData() { myFieldsLst.clear();};
+ void visibilityOff(int num_field, int num_frame);
void stopAnimation();
void startAnimation();
void nextFrame();
@@ -123,12 +137,14 @@
QString getLastErrorMsg() { return myLastError; }
CORBA::Boolean isCycling() { return myCycling; }
+ CORBA::Boolean isCleaningMemoryAtEachFrame() { return myCleaningMemoryAtEachFrame; }
CORBA::Double getMinTime() { return myTimeMin;}
CORBA::Double getMaxTime() { return myTimeMax;}
void setProportional(CORBA::Boolean theProp) { myProportional = theProp; }
void setCycling(CORBA::Boolean theCycle) { myCycling = theCycle; }
+ void setCleaningMemoryAtEachFrame(CORBA::Boolean theCycle) { myCleaningMemoryAtEachFrame = theCycle; }
SALOMEDS::SObject_ptr publishInStudy();
void restoreFromStudy(SALOMEDS::SObject_ptr theField);
@@ -139,6 +155,7 @@
public slots:
void setProportionalSlot(bool theProp) { myProportional = theProp; }
void setCyclingSlot(bool theCycle) { myCycling = theCycle; }
+ void setCleaningMemoryAtEachFrameSlot(bool theCycle) { myCleaningMemoryAtEachFrame = theCycle; }
signals:
void frameChanged(long theNewFrame, double theTime);
@@ -160,6 +177,7 @@
int mySpeed;
bool myProportional;
bool myCycling;
+ bool myCleaningMemoryAtEachFrame;
_PTR(Study) myStudy;
double myTimeMinVal, myTimeMaxVal; //!< Range of time stams, set by user
@@ -228,12 +246,14 @@
virtual char* setDumpFormat(const char* theFormat);
virtual CORBA::Boolean isCycling();
+ virtual CORBA::Boolean isCleaningMemoryAtEachFrame();
virtual CORBA::Double getMinTime();
virtual CORBA::Double getMaxTime();
virtual void setProportional(CORBA::Boolean theProp);
virtual void setCycling(CORBA::Boolean theCycle);
+ virtual void setCleaningMemoryAtEachFrame(CORBA::Boolean theCycle);
virtual SALOMEDS::SObject_ptr publishInStudy();
virtual void restoreFromStudy(SALOMEDS::SObject_ptr theField);
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.cc
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.cc,v
retrieving revision 1.19.2.1
retrieving revision 1.19.2.2
diff -c -u -r1.19.2.1 -r1.19.2.2
--- VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.cc 24 Aug 2006 13:23:20 -0000 1.19.2.1
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.cc 17 Oct 2006 10:37:39 -0000 1.19.2.2
@@ -1610,8 +1610,8 @@
_PTR(SObject) anObj = aList[i];
string anEntry = anObj->GetID();
if(MYDEBUG) MESSAGE("View3D_i::SaveViewParams - anEntry = " << anEntry);
- if (anObj->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aCmnt (anAttr);
+ if (anObj->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aCmnt (anAttr);
string aComm (aCmnt->Value());
if (MYDEBUG) MESSAGE("View3D_i::SaveViewPoint - aComm = " << aComm);
if (aComm.compare(View3D_i::myComment) >= 0) {
@@ -1671,8 +1671,8 @@
_PTR(SObject) anObj = aList[i];
string anEntry = anObj->GetID();
if (MYDEBUG) MESSAGE("View3D_i::RestoreViewPoint - anEntry = " << anEntry);
- if (anObj->FindAttribute(anAttr, "AttributeComment")) {
- _PTR(AttributeComment) aCmnt (anAttr);
+ if (anObj->FindAttribute(anAttr, "AttributeString")) {
+ _PTR(AttributeString) aCmnt (anAttr);
QString strIn(aCmnt->Value().c_str());
Storable::TRestoringMap aMap;
Storable::StrToMap(strIn, aMap);
Index: VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.hh
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.hh,v
retrieving revision 1.9
retrieving revision 1.9.2.1
diff -c -u -r1.9 -r1.9.2.1
--- VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.hh 1 Jun 2006 11:36:05 -0000 1.9
+++ VISU_SRC_3.2.2/src/VISU_I/VISU_View_i.hh 26 Sep 2006 08:31:03 -0000 1.9.2.1
@@ -259,7 +259,7 @@
static void SetFocalPoint (SUIT_ViewWindow* theViewWindow, const CORBA::Double theFocalPnt[3]);
virtual void SetFocalPoint (const VISU::View3D::XYZ theCoord);
- static void View3D_i::GetFocalPoint (SUIT_ViewWindow* theViewWindow, CORBA::Double theFocalPnt[3]);
+ static void GetFocalPoint (SUIT_ViewWindow* theViewWindow, CORBA::Double theFocalPnt[3]);
virtual VISU::View3D::XYZ_slice* GetFocalPoint();
static void SetParallelScale (SUIT_ViewWindow* theViewWindow, CORBA::Double theScale);
Index: VISU_SRC_3.2.2/src/VISU_SWIG/visu.py
===================================================================
RCS file: /home/server/cvs/VISU/VISU_SRC_3.2.2/src/VISU_SWIG/visu.py,v
retrieving revision 1.22.2.1
retrieving revision 1.22.2.2
diff -c -u -r1.22.2.1 -r1.22.2.2
--- VISU_SRC_3.2.2/src/VISU_SWIG/visu.py 15 Jun 2006 12:11:00 -0000 1.22.2.1
+++ VISU_SRC_3.2.2/src/VISU_SWIG/visu.py 17 Oct 2006 10:34:29 -0000 1.22.2.2
@@ -463,8 +463,8 @@
aFieldName = anAttr.Value()
print " ", aFieldName
- anAttr = aFieldSObj.FindAttribute("AttributeComment")[1]
- anAttr = anAttr._narrow(SALOMEDS.AttributeComment);
+ anAttr = aFieldSObj.FindAttribute("AttributeString")[1]
+ anAttr = anAttr._narrow(SALOMEDS.AttributeString);
aFieldComment = anAttr.Value()
aMap = StrToMap(aFieldComment)
@@ -479,8 +479,8 @@
aTimeStampName = anAttr.Value()
print " ", aTimeStampName
- anAttr = aTimeStampSObj.FindAttribute("AttributeComment")[1]
- anAttr = anAttr._narrow(SALOMEDS.AttributeComment);
+ anAttr = aTimeStampSObj.FindAttribute("AttributeString")[1]
+ anAttr = anAttr._narrow(SALOMEDS.AttributeString);
aTimeStampComment = anAttr.Value()
aMap = StrToMap(aTimeStampComment)
aMeshName = aMap["myMeshName"]