diff -Nru ifrit-3.3.4/build/CMakeLists.txt ifrit-3.4.2/build/CMakeLists.txt --- ifrit-3.3.4/build/CMakeLists.txt 2011-01-27 17:50:57.000000000 +0000 +++ ifrit-3.4.2/build/CMakeLists.txt 2013-07-11 01:23:15.000000000 +0000 @@ -237,6 +237,14 @@ ADD_DEFINITIONS(-DI_CUSTOM_VP1000) ENDIF(tmp) ENDIF(CustomVP1000) + +IF(Extension:ART) + FILE(GLOB tmp ${src}/special/artio/*.c) + IF(tmp) + SET(sources ${sources} ${tmp}) + INCLUDE_DIRECTORIES(${src}/special/artio) + ENDIF(tmp) +ENDIF(Extension:ART) # # Create target diff -Nru ifrit-3.3.4/configure/iconfigure.h ifrit-3.4.2/configure/iconfigure.h --- ifrit-3.3.4/configure/iconfigure.h 2011-01-27 17:50:59.000000000 +0000 +++ ifrit-3.4.2/configure/iconfigure.h 2013-07-11 01:23:15.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iconfiguresettings.ext ifrit-3.4.2/configure/iconfiguresettings.ext --- ifrit-3.3.4/configure/iconfiguresettings.ext 2011-01-27 17:51:03.000000000 +0000 +++ ifrit-3.4.2/configure/iconfiguresettings.ext 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iedition.cpp ifrit-3.4.2/configure/iedition.cpp --- ifrit-3.3.4/configure/iedition.cpp 2011-01-27 17:51:01.000000000 +0000 +++ ifrit-3.4.2/configure/iedition.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iedition.h ifrit-3.4.2/configure/iedition.h --- ifrit-3.3.4/configure/iedition.h 2011-01-27 17:51:00.000000000 +0000 +++ ifrit-3.4.2/configure/iedition.h 2013-07-11 01:23:15.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iextensionbuilder.cpp ifrit-3.4.2/configure/iextensionbuilder.cpp --- ifrit-3.3.4/configure/iextensionbuilder.cpp 2011-01-27 17:51:01.000000000 +0000 +++ ifrit-3.4.2/configure/iextensionbuilder.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iextensionbuilder.h ifrit-3.4.2/configure/iextensionbuilder.h --- ifrit-3.3.4/configure/iextensionbuilder.h 2011-01-27 17:51:00.000000000 +0000 +++ ifrit-3.4.2/configure/iextensionbuilder.h 2013-07-11 01:23:15.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iextensiondefines.h ifrit-3.4.2/configure/iextensiondefines.h --- ifrit-3.3.4/configure/iextensiondefines.h 2011-01-27 17:51:00.000000000 +0000 +++ ifrit-3.4.2/configure/iextensiondefines.h 2013-07-11 01:23:15.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iextensionfactory.cpp ifrit-3.4.2/configure/iextensionfactory.cpp --- ifrit-3.3.4/configure/iextensionfactory.cpp 2011-01-27 17:51:02.000000000 +0000 +++ ifrit-3.4.2/configure/iextensionfactory.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iextensionfactory.h ifrit-3.4.2/configure/iextensionfactory.h --- ifrit-3.3.4/configure/iextensionfactory.h 2011-01-27 17:51:00.000000000 +0000 +++ ifrit-3.4.2/configure/iextensionfactory.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/ifrit.cpp ifrit-3.4.2/configure/ifrit.cpp --- ifrit-3.3.4/configure/ifrit.cpp 2011-01-27 17:51:02.000000000 +0000 +++ ifrit-3.4.2/configure/ifrit.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iopengl.h ifrit-3.4.2/configure/iopengl.h --- ifrit-3.3.4/configure/iopengl.h 2011-01-27 17:51:00.000000000 +0000 +++ ifrit-3.4.2/configure/iopengl.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/ishellfactory.cpp ifrit-3.4.2/configure/ishellfactory.cpp --- ifrit-3.3.4/configure/ishellfactory.cpp 2011-01-27 17:51:02.000000000 +0000 +++ ifrit-3.4.2/configure/ishellfactory.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/ishellfactory.h ifrit-3.4.2/configure/ishellfactory.h --- ifrit-3.3.4/configure/ishellfactory.h 2011-01-27 17:51:01.000000000 +0000 +++ ifrit-3.4.2/configure/ishellfactory.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/iversion.cpp ifrit-3.4.2/configure/iversion.cpp --- ifrit-3.3.4/configure/iversion.cpp 2011-01-27 17:51:02.000000000 +0000 +++ ifrit-3.4.2/configure/iversion.cpp 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -33,9 +33,9 @@ // // IFrIT version // -#define IVERSION_BASE "3.3.4" +#define IVERSION_BASE "3.4.2" -#define IVERSION_EXT_ART "2.3.1" +#define IVERSION_EXT_ART "2.4.1" #define IVERSION_EXT_MV "1.2.1" #define IVERSION_EXT_VTK "1.1.0" #define IVERSION_EXT_GADGET "1.1.0" @@ -152,6 +152,22 @@ // Ported to VTK 5.6.1, added GPU Volume rendering support // Removed Event Recorder as it caused compilation errors on some compilers // +// 120320 Base-3.3.5 ART-2.3.2 MV-1.2.1 VTK-1.1.0 GADGET-1.1.0 +// A few bug fixes. +// Ported to VTK 5.8.0, added GPU Volume rendering support +// +// 120809 Base-3.4.0 ART-2.4.0 MV-1.2.1 VTK-1.1.0 GADGET-1.1.0 +// Mioved to Mercurial SC +// ARTIO and CART io support +// Some widget modification (FileName, Color) +// Removed CameraPath Animator mode, fixed title page and logo +// +// 121219 Base-3.4.1 ART-2.4.0 MV-1.2.1 VTK-1.1.0 GADGET-1.1.0 +// Minor bug fix +// +// 130710 Base-3.4.2 ART-2.4.1 MV-1.2.1 VTK-1.1.0 GADGET-1.1.0 +// Added support for selecting sub-volume of the ART mesh, other minor fixes +// // // ToDo (major additions) diff -Nru ifrit-3.3.4/configure/iversion.h ifrit-3.4.2/configure/iversion.h --- ifrit-3.3.4/configure/iversion.h 2011-01-27 17:51:01.000000000 +0000 +++ ifrit-3.4.2/configure/iversion.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/configure/ivtk.h ifrit-3.4.2/configure/ivtk.h --- ifrit-3.3.4/configure/ivtk.h 2011-01-27 17:51:01.000000000 +0000 +++ ifrit-3.4.2/configure/ivtk.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/.#iactorcollection.cpp.1.1 ifrit-3.4.2/core/.#iactorcollection.cpp.1.1 --- ifrit-3.3.4/core/.#iactorcollection.cpp.1.1 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#iactorcollection.cpp.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,56 +0,0 @@ -//LICENSE A - - -#include "iactorcollection.h" - - -#include "iactor.h" - -// -// Templates -// -#include "iarraytemplate.h" - - -iActorCollection* iActorCollection::New() -{ - return new iActorCollection(); -} - - -iActorCollection::iActorCollection() -{ -} - - -iActorCollection::~iActorCollection() -{ - int i; - for(i=0; iUnRegister(this); -} - - -void iActorCollection::SetVisibility(bool s) -{ - int i; - for(i=0; iSetVisibility(s?1:0); -} - - -void iActorCollection::AddActor(iActor *a) -{ - if(a != 0) - { - mActors.AddUnique(a); - a->Register(this); - } -} - - -void iActorCollection::RemoveActor(iActor *a) -{ - if(a != 0) - { - if(mActors.Remove(a)) a->UnRegister(this); - } -} diff -Nru ifrit-3.3.4/core/.#iactorcollection.h.1.1 ifrit-3.4.2/core/.#iactorcollection.h.1.1 --- ifrit-3.3.4/core/.#iactorcollection.h.1.1 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#iactorcollection.h.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,44 +0,0 @@ -//LICENSE A - -// -// A simple collection of iActors -// -#ifndef IACTORCOLLECTION_H -#define IACTORCOLLECTION_H - - -#include - - -#include "iarray.h" - -class iActor; - - -class iActorCollection : public vtkObject -{ - -public: - - vtkTypeMacro(iActorCollection,vtkObject); - static iActorCollection* New(); - - void SetVisibility(bool s); - - void AddActor(iActor *a); - void RemoveActor(iActor *a); - -protected: - - virtual ~iActorCollection(); - -private: - - iActorCollection(); - - iPointerArray mActors; -}; - -#endif // IACTORCOLLECTION_H - - diff -Nru ifrit-3.3.4/core/.#ishell.cpp.1.1 ifrit-3.4.2/core/.#ishell.cpp.1.1 --- ifrit-3.3.4/core/.#ishell.cpp.1.1 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#ishell.cpp.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,843 +0,0 @@ -//LICENSE A - - -#include "ishell.h" - - -#include "icontrolmodule.h" -#include "icontrolscript.h" -#include "idirectory.h" -#include "ierror.h" -#include "ieventobserver.h" -#include "ierrorstatus.h" -#include "ifile.h" -#include "iimagefactory.h" -#include "ioutputchannel.h" -#include "iparallelmanager.h" -#include "ishellfactory.h" -#include "iviewmodule.h" -#include "ivtk.h" - -#include -#include - -#ifdef I_OFFSCREEN -#include -#include -#endif - -// -// Templates -// -#include "iarraytemplate.h" - - -using namespace iParameter; - - -const iString iShell::mOptionPrefix = "-"; - - -namespace iShell_Private -{ - void CheckSystem(); - void TestPerformance(); - - class BatchModeObserver : public iScriptObserver - { - - public: - - BatchModeObserver(iScript *s) : iScriptObserver(s) - { - } - - protected: - - virtual void OnScriptStartBody(){} - virtual void OnScriptStopBody(const iString &error){} - - virtual void OnScriptBeginLineBody(int line, const iString &text) - { - iConsole::Display(iConsole::_Info,"Executing line #"+iString::FromNumber(line)+": "+text); - } - - virtual void OnScriptEndLineBody(int , const iString &){} - virtual bool OnScriptCheckAbortBody(int cur, int num, int level) - { - if(cur>-1 && num>0) - { - iConsole::Display(iConsole::_Info,"Loop: level #"+iString::FromNumber(level)+", iteration "+iString::FromNumber(cur)+" out of "+iString::FromNumber(num)); - } - return false; - } - }; -}; - - -using namespace iShell_Private; - - -void iShell::RunApplication(const iString &t, int argc, char **argv) -{ -#ifdef I_DEBUG -// iHelpFactory::CreateUserGuide(iHelpFactory::_Publish); return; -#endif - iShell *tmp = iShell::New(t,argc,argv); - if(tmp != 0) - { - tmp->Run(); - tmp->Delete(); - } -} - - -iShell::iShell(const iString &type, int, char **) : mType(type) -{ - int i; - - mRunning = false; - mControlModule = 0; // control module must be created after the constructor is finished - mNumProcs = 0; - - mCurInitStep = 0; - for(i=0; i<4; i++) - { - mInitSteps[i].Current = 0; - } - mInitSteps[0].Total = 10; // needs to be set manually during development. How to do it automatically? - mInitSteps[1].Total = 161; // needs to be set manually during development. How to do it automatically? - mInitSteps[2].Total = 1382; // needs to be set manually during development. How to do it automatically? - mInitSteps[3].Total = 13; // needs to be set manually during development. How to do it automatically? - - // - // Define some basic command-line options - // - this->AddCommandLineOption("h",false,"show this help"); - this->AddCommandLineOption("help",false,"show this help"); - this->AddCommandLineOption("-help",false,"show this help"); - this->AddCommandLineOption("i",true,"load the state from a file with name "); - this->AddCommandLineOption("np",true,"set the number of processors to use to "); - this->AddCommandLineOption("test",false,"test performance and exit (must be the first and only option)"); - this->AddCommandLineOption("b",true,"execute a control script from a file in the screenless mode"); - - // - // Set environment variables - // Is the base-dir environment variable set? - // - char *e = getenv("IFRIT_DIR"); - if(e != 0) - { - mEnvBaseDir = iString(e); - if(mEnvBaseDir.IsEmpty()) mEnvBaseDir = iDirectory::Current(); - if(!mEnvBaseDir.EndsWith(iDirectory::Separator())) mEnvBaseDir += iDirectory::Separator(); - } - else - { - // - // Get the home directory, if it exists - // - e = getenv("APPDATA"); // windows? - if(e != 0) - { - mEnvBaseDir = iString(e) + iDirectory::Separator() + "IfrIT" + iDirectory::Separator(); - } - else // unix? - { - e = getenv("HOME"); - mEnvBaseDir = iString(e) + iDirectory::Separator() + ".ifrit" + iDirectory::Separator(); - } - // - // Is it readable? - // - iDirectory dir; - if(!dir.Open(mEnvBaseDir)) - { - // - // try to create - // - if(!dir.Make(mEnvBaseDir)) - { - mEnvBaseDir = iDirectory::Current(); - } - } - } - - // - // Read other environment here - // - e = getenv("IFRIT_DATA_DIR"); if(e != 0) mEnvDataDir = iString(e) + iDirectory::Separator(); else mEnvDataDir = iDirectory::Current(); - e = getenv("IFRIT_IMAGE_DIR"); if(e != 0) mEnvImageDir = iString(e) + iDirectory::Separator(); else mEnvImageDir = iDirectory::Current(); - e = getenv("IFRIT_SCRIPT_DIR"); if(e != 0) mEnvScriptDir = iString(e) + iDirectory::Separator(); else mEnvScriptDir = mEnvBaseDir; - e = getenv("IFRIT_PALETTE_DIR"); if(e != 0) mEnvPaletteDir = iString(e) + iDirectory::Separator(); else mEnvPaletteDir = mEnvBaseDir; - - iDirectory::ExpandFileName(mEnvBaseDir); - iDirectory::ExpandFileName(mEnvDataDir); - iDirectory::ExpandFileName(mEnvImageDir); - iDirectory::ExpandFileName(mEnvScriptDir); - iDirectory::ExpandFileName(mEnvPaletteDir); - - mInitTimer = vtkTimerLog::New(); IERROR_ASSERT(mInitTimer); - mInitTimer->StartTimer(); - -#ifdef I_OFFSCREEN - // - // Configure Graphics Factory - // - vtkGraphicsFactory *graphics_factory = vtkGraphicsFactory::New(); IERROR_ASSERT(graphics_factory); - graphics_factory->SetOffScreenOnlyMode(1); - graphics_factory->SetUseMesaClasses(1); - // - // Configure Imaging Factory - vtkImagingFactory *imaging_factory = vtkImagingFactory::New(); IERROR_ASSERT(imaging_factory); - imaging_factory->SetUseMesaClasses(1); -#endif -} - - -iShell::~iShell() -{ - // - // This ensures that control module is deleted after the shell is deleted. - // - // mControlModule->Delete(); - mInitTimer->Delete(); -} - - -iShell* iShell::New(const iString &t, int argc, char **argv) -{ - // - // Check that sizes of basic types are correct - // - CheckSystem(); - // - // Check if a test call - // - if(argc==2 && iString(argv[1])==(mOptionPrefix+"test")) - { - TestPerformance(); - return 0; - } - // - // Also use options to specify shell - they overwrite the default choice - // - iString st = t; - int firstOption = 1; - if(argc>1 && iString(argv[1]).Part(0,mOptionPrefix.Length())==mOptionPrefix) - { - iString list, help, s = iString(argv[1]).Part(mOptionPrefix.Length()); - iShellFactory::GetSupportedShells(list,help); - if(list.Contains(s+"/") == 1) - { - st = s; - firstOption = 2; - } - } - // - // If there is no default and no option, ask ShellFactory to query the user - // - if(st.IsEmpty()) - { - iConsole::Display(iConsole::_FatalError,"No shell has been specified. Use a \"-\" option to specify a two-letter shell abbreviation ."); - return 0; - } - // - // Create shell - // - iShell *tmp = iShellFactory::CreateShell(st,argc,argv); - if(tmp == 0) - { - iConsole::Display(iConsole::_FatalError,"Shell '"+st+"' is not included in this installation."); - return 0; - } - tmp->mFirstOption = firstOption; - // - // Make sure Image factory is up to date - // - iImageFactory::FindIcon("genie1.png"); - // - // Parse command line options - // - tmp->DefineSpecificCommandLineOptions(); - tmp->ParseCommandLineOptions(argc,argv); - -#ifdef I_DEBUG - //tmp->mNumProcs = 2; -#endif - - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->PrepareForConstruction(); - } - -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // This ensures that "tmp->this" pointer is correct before a control module is created. - // - tmp->mCurInitStep = 1; - tmp->mControlModule = iControlModule::New(tmp); IERROR_ASSERT(tmp->mControlModule); - if(tmp->mNumProcs >= 0) tmp->mControlModule->GetParallelManager()->ResetMaxNumberOfProcessors(tmp->mNumProcs); - // - // Set the state file name - // - if(tmp->mStateFileName.IsEmpty()) - { - iString fname = tmp->GetEnvironment(_EnvironmentBase) + "ifrit.ini"; - if(iFile::IsReadable(fname)) tmp->mStateFileName = fname; - } - -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // Really construct the shell: control module needs to be fully initialized before a shell - // is really constructed. - // - tmp->mCurInitStep = 2; - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->ConstructorBody(); - } - // - // Check that vtkIdType is 64-bit on a 64-bit machine - // - if(sizeof(vtkIdType)==4 && sizeof(long)==8) - { - iConsole::Display(iConsole::_Notification,"This machine is 64-bit, but VTK has been compiled with 32-bit ids.\n" - " This configuration is inconsistent and is prone to crashes. \n" - " It is highly recommended that you recompile VTK with \n" - " advanced option VTK_USE_64BIT_IDS set to ON \n" - " and then recompile IFrIT. "); - } - // - // Load widget info into ObjectKeyHelp objects. - // -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // Load the state file if needed - // - tmp->mCurInitStep = 3; - if(!tmp->mStateFileName.IsEmpty()) - { - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->PrepareToLoadStateFile(); - } - if(!tmp->GetControlModule()->LoadStateFromFile(tmp->mStateFileName)) - { - iConsole::Display(iConsole::_HighError,"Unable to load the state file.\n Default values of parameters will be used."); - } - } -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - - if(tmp->mScriptFileName.IsEmpty()) - { -#ifdef I_OFFSCREEN - // - // In the off-screen mode we need the script - // - iConsole::Display(iConsole::_FatalError,"A batch script filename is required in the off-screen-only mode."); - return 0; -#else - // - // Start the shell - // - tmp->Start(); - return tmp; -#endif - } - else - { - // - // Execute script and exit - // - int i, n = tmp->mControlModule->GetNumberOfViewModules(); - for(i=0; imControlModule->GetViewModule(i)->GetRenderWindow()->SetOffScreenRendering(1); - } - - if(tmp->mControlModule->GetViewModule(0)->GetRenderWindow()->GetOffScreenRendering() == 0) - { - iConsole::Display(iConsole::_FatalError,"This platform+shell combination does not support off-screen rendering.\n Off-screen rendering is needed for executing a script in a batch mode."); - return 0; - } - // - // Execute the batch script - // - iFile F(tmp->mScriptFileName); - - if(!F.Open(iFile::_Read,iFile::_Text)) - { - iConsole::Display(iConsole::_FatalError,iString("File ")+tmp->mScriptFileName+" cannot be open for reading."); - return 0; - } - - iConsole::Display(iConsole::_Info,"Reading the file..."); - iString text, line; - while(F.ReadLine(line)) text += "\n" + line; - text += "\n"; - - iControlScript *cs = tmp->mControlModule->GetControlScript(); - iConsole::Display(iConsole::_Info,"Compiling the script..."); - - cs->SetText(text); - if(!cs->Compile()) - { - iConsole::Display(iConsole::_FatalError,iString("Syntax error in script, line ")+iString::FromNumber(cs->GetThisLine())+" : "+cs->GetErrorStatus()->Message()); - return 0; - } - - cs->SetAutoRender(false); - - iConsole::Display(iConsole::_Info,"Running the script..."); - BatchModeObserver *obs = new BatchModeObserver(cs); - cs->Execute(); - if(obs != 0) delete obs; - if(cs->GetErrorStatus()->IsError()) - { - iConsole::Display(iConsole::_HighError,iString("Runtime error in script, line ")+iString::FromNumber(cs->GetThisLine())+" : "+cs->GetErrorStatus()->Message()); - } - else iConsole::Display(iConsole::_Info,"Done."); - - tmp->Delete(); - return 0; - } -} - - -void iShell::Delete() -{ - // - // We are just about to start deleting objects. First thing we do is to block all - // observers since we do not know at each moment in the deleting process which objects - // are still present and which have been already deleted. - // - iEventObserver::BlockAllEventObservers(true); - - // - // Check whether the error log was created by iConsole: - // - iOutputChannel::GetInstance()->NotifyIfLogCreated(); - - // - // Go on rampage! - // - if(mScriptFileName.IsEmpty()) - { - this->DestructorBody(); - } - - // - // This ensures that control module is deleted before the shell is deleted. - // - mControlModule->Delete(); - - this->vtkObjectBase::Delete(); -} - - -void iShell::Run() -{ - mRunning = true; - this->RunBody(); - mRunning = false; -} - - -void iShell::AddCommandLineOption(const iString &root, bool hasValue, const iString &help) -{ - Option tmp; - tmp.Name = root; - tmp.NeedsValue = hasValue; - tmp.Help = help; - mOptions.Add(tmp); -} - - -void iShell::ParseCommandLineOptions(int argc, char **argv) -{ - int i, j; - Option o; - bool done; - - i = mFirstOption; - while(i < argc) - { - done = false; - if(iString(argv[i]).Part(0,mOptionPrefix.Length()) == mOptionPrefix) - { - o.Name = argv[i] + mOptionPrefix.Length(); - for(j=0; !done && j16384) return false; - mNumProcs = n; - return true; - } - - if(o.Name == "i") - { - iString fn(o.Value); - iDirectory::ExpandFileName(fn,this->GetEnvironment(_EnvironmentBase)); - if(iFile::IsReadable(fn)) - { - mStateFileName = fn; - return true; - } - else - { - iConsole::Display(iConsole::_HighError,"File "+fn+" is not accessible.\nIFrIT will now exit."); - exit(1); - } - } - - if(o.Name == "b") - { - iString fn (o.Value); - iDirectory::ExpandFileName(fn,this->GetEnvironment(_EnvironmentBase)); - if(iFile::IsReadable(fn)) - { - mScriptFileName = fn; - return true; - } - else - { - iConsole::Display(iConsole::_HighError,"File "+fn+" is not accessible.\nIFrIT will now exit."); - exit(1); - } - } - - return this->AnalyseOneExtendedCommandLineOption(o); -} - - -// -// Environment querying -// -const iString& iShell::GetEnvironment(int key) const -{ - static const iString none; - - switch(key) - { - case _EnvironmentBase: - { - return mEnvBaseDir; - } - case _EnvironmentData: - { - return mEnvDataDir; - } - case _EnvironmentImage: - { - return mEnvImageDir; - } - case _EnvironmentScript: - { - return mEnvScriptDir; - } - case _EnvironmentPalette: - { - return mEnvPaletteDir; - } - default: - { - return none; - } - } -} - - -bool iShell::HasStateFile() const -{ - return !mStateFileName.IsEmpty(); -} - - -bool iShell::LoadShellStateFromFile(iFile &F) -{ - if(mScriptFileName.IsEmpty()) - { - return this->LoadShellStateFromFileBody(F); - } - else return true; -} - - -bool iShell::SaveShellStateToFile(iFile &F) const -{ - if(mScriptFileName.IsEmpty()) - { - return this->SaveShellStateToFileBody(F); - } - else return true; -} - - -void iShell::OnInitAtom() -{ - mInitSteps[mCurInitStep].Current++; - mInitTimer->StopTimer(); - if(mInitTimer->GetElapsedTime() > 0.1) - { - mInitTimer->StartTimer(); - this->OnInitAtomBody(true); - } - else - { - this->OnInitAtomBody(false); - } -} - - -void iShell::OnInitAtomBody(bool) -{ -} - - -void iShell::OnLoadStateFileAtom(int prog) -{ - this->OnLoadStateFileAtomBody(prog); -} - - -void iShell::OnLoadStateFileAtomBody(int) -{ -} - - -#ifdef I_DEBUG - -void iShell::InitHelper() -{ - if(mInitSteps[mCurInitStep].Current != mInitSteps[mCurInitStep].Total) - { - int step = mCurInitStep; - int total = mInitSteps[mCurInitStep].Current; - int bp = 0; - } -} - -#endif - - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace iShell_Private -{ - void CheckSystem() - { - // - // Check that sizes of basic types are correct - // - if(sizeof(int)!=4 || sizeof(float)!=4 || sizeof(double)!=8 || sizeof(void*)!=sizeof(long)) - { - int sint = sizeof(int); - int sflt = sizeof(float); - int sdbl = sizeof(double); - int sptr = sizeof(void*); - int slng = sizeof(long); - iConsole::Display(iConsole::_HighError,"IFrIT has not been ported to this machine."); - exit(0); - } - } - - float TestRenderingPerformance(vtkRenderer *ren) - { - // - // Set up the timer - // - ren->GetActiveCamera()->SetPosition(0.0,0.0,1.0); - ren->ResetCamera(); - - vtkTimerLog *timer = vtkTimerLog::New(); - timer->StartTimer(); - - int i; - float r = 0.0f; - do - { - for(i=0; i<10; i++) - { - ren->GetActiveCamera()->Azimuth(0.1); - ren->GetRenderWindow()->Render(); - } - timer->StopTimer(); - r += 0.01f; - } - while(timer->GetElapsedTime() < 10.0); - - timer->Delete(); - - return r; - } - - - void TestPerformance() - { - const float renRateScale[2] = { 5.62e-2f, 4.61e-2f }; - - vtkRenderer *ren = vtkRenderer::New(); - vtkRenderWindow *win = vtkRenderWindow::New(); - win->AddRenderer(ren); - ren->Delete(); - - vtkImageData *data = vtkImageData::New(); - data->SetDimensions(17,17,17); - data->SetSpacing(0.125,0.125,0.125); - data->SetOrigin(-1.0,-1.0,-1.0); - data->SetScalarTypeToUnsignedChar(); - data->SetNumberOfScalarComponents(1); - data->AllocateScalars(); - - // unsigned char *ptr = (unsigned char *)data->GetScalarPointer(); - - vtkCubeSource *cube = vtkCubeSource::New(); - cube->Update(); - - vtkGlyph3D *glyph = vtkGlyph3D::New(); - glyph->SetScaleModeToDataScalingOff(); - glyph->SetScaleFactor(0.08); - glyph->SetSource(cube->GetOutput()); - glyph->SetInput(data); - cube->Delete(); - glyph->Update(); - - vtkPolyDataMapper *mapper = vtkPolyDataMapper::New(); - vtkActor *actor = vtkActor::New(); - - mapper->ScalarVisibilityOff(); - - actor->GetProperty()->SetColor(0.0,0.0,0.0); - actor->SetMapper(mapper); - mapper->Delete(); - - mapper->SetInput(glyph->GetOutput()); - glyph->Delete(); - - ren->AddActor(actor); - actor->Delete(); - - // - // set the scene - // - win->SetSize(512,512); - ren->SetBackground(1.0,1.0,1.0); - - // - // draw the resulting scene - // - win->Render(); - win->SetWindowName("IFrIT - Performance Test"); - - iString ws = "Rendering performance (relative to NVIDIA Quadro FX 4000/AGP 8x):\n"; - float rr; - - actor->GetProperty()->SetOpacity(1.0); - actor->GetProperty()->SetColor(0.0,0.0,1.0); - rr = TestRenderingPerformance(ren)/renRateScale[0]; - ws += "Opaque:\t\t " + iString::FromNumber(round(rr)) + "%\n"; - - actor->GetProperty()->SetOpacity(0.03); - actor->GetProperty()->SetColor(1.0,0.0,0.0); - rr = TestRenderingPerformance(ren)/renRateScale[1]; - ws += "Transparent:\t " + iString::FromNumber(round(rr)) + "%\n"; - - iConsole::Display(iConsole::_Info,ws); - - data->Delete(); - win->RemoveRenderer(ren); - win->Delete(); - } -}; diff -Nru ifrit-3.3.4/core/.#ishell.cpp.1.30 ifrit-3.4.2/core/.#ishell.cpp.1.30 --- ifrit-3.3.4/core/.#ishell.cpp.1.30 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#ishell.cpp.1.30 1970-01-01 00:00:00.000000000 +0000 @@ -1,837 +0,0 @@ -//LICENSE A - - -#include "ishell.h" - - -#include "icontrolmodule.h" -#include "icontrolscript.h" -#include "idirectory.h" -#include "ierror.h" -#include "ieventobserver.h" -#include "ierrorstatus.h" -#include "ifile.h" -#include "iimagefactory.h" -#include "ioutputchannel.h" -#include "iparallelmanager.h" -#include "ishellfactory.h" -#include "iviewmodule.h" - -#include -#include - -#ifdef I_OFFSCREEN -#include -#include -#endif - -// -// Templates -// -#include "iarraytemplate.h" - - -using namespace iParameter; - - -const iString iShell::mOptionPrefix = "-"; - - -namespace iShell_Private -{ - void CheckSystem(); - void TestPerformance(); - - class BatchModeObserver : public iScriptObserver - { - - public: - - BatchModeObserver(iScript *s) : iScriptObserver(s) - { - } - - protected: - - virtual void OnScriptStartBody(){} - virtual void OnScriptStopBody(const iString &error){} - - virtual void OnScriptBeginLineBody(int line, const iString &text) - { - iConsole::Display(iConsole::_Info,"Executing line #"+iString::FromNumber(line)+": "+text); - } - - virtual void OnScriptEndLineBody(int , const iString &){} - virtual bool OnScriptCheckAbortBody(int cur, int num, int level) - { - if(cur>-1 && num>0) - { - iConsole::Display(iConsole::_Info,"Loop: level #"+iString::FromNumber(level)+", iteration "+iString::FromNumber(cur)+" out of "+iString::FromNumber(num)); - } - return false; - } - }; -}; - - -using namespace iShell_Private; - - -void iShell::RunApplication(const iString &t, int argc, char **argv) -{ -#ifdef I_DEBUG -// iHelpFactory::CreateUserGuide(iHelpFactory::_Publish); return; -#endif - iShell *tmp = iShell::New(t,argc,argv); - if(tmp != 0) - { - tmp->Run(); - tmp->Delete(); - } -} - - -iShell::iShell(const iString &type, int, char **) : mType(type) -{ - int i; - - mRunning = false; - mControlModule = 0; // control module must be created after the constructor is finished - mNumProcs = 0; - - mCurInitStep = 0; - for(i=0; i<4; i++) - { - mInitSteps[i].Current = 0; - } - mInitSteps[0].Total = 10; // needs to be set manually during development. How to do it automatically? - mInitSteps[1].Total = 161; // needs to be set manually during development. How to do it automatically? - mInitSteps[2].Total = 1382; // needs to be set manually during development. How to do it automatically? - mInitSteps[3].Total = 13; // needs to be set manually during development. How to do it automatically? - - // - // Define some basic command-line options - // - this->AddCommandLineOption("h",false,"show this help"); - this->AddCommandLineOption("help",false,"show this help"); - this->AddCommandLineOption("-help",false,"show this help"); - this->AddCommandLineOption("i",true,"load the state from a file with name "); - this->AddCommandLineOption("np",true,"set the number of processors to use to "); - this->AddCommandLineOption("test",false,"test performance and exit (must be the first and only option)"); - this->AddCommandLineOption("b",true,"execute a control script from a file in the screenless mode"); - - // - // Set environment variables - // Is the base-dir environment variable set? - // - char *e = getenv("IFRIT_DIR"); - if(e != 0) - { - mEnvBaseDir = iString(e); - if(mEnvBaseDir.IsEmpty()) mEnvBaseDir = iDirectory::Current(); - if(!mEnvBaseDir.EndsWith(iDirectory::Separator())) mEnvBaseDir += iDirectory::Separator(); - } - else - { - // - // Get the home directory, if it exists - // - e = getenv("APPDATA"); // windows? - if(e != 0) - { - mEnvBaseDir = iString(e) + iDirectory::Separator() + "IfrIT" + iDirectory::Separator(); - } - else // unix? - { - e = getenv("HOME"); - mEnvBaseDir = iString(e) + iDirectory::Separator() + ".ifrit" + iDirectory::Separator(); - } - // - // Is it readable? - // - iDirectory dir; - if(!dir.Open(mEnvBaseDir)) - { - // - // try to create - // - if(!dir.Make(mEnvBaseDir)) - { - mEnvBaseDir = iDirectory::Current(); - } - } - } - - // - // Read other environment here - // - e = getenv("IFRIT_DATA_DIR"); if(e != 0) mEnvDataDir = iString(e) + iDirectory::Separator(); else mEnvDataDir = iDirectory::Current(); - e = getenv("IFRIT_IMAGE_DIR"); if(e != 0) mEnvImageDir = iString(e) + iDirectory::Separator(); else mEnvImageDir = iDirectory::Current(); - e = getenv("IFRIT_SCRIPT_DIR"); if(e != 0) mEnvScriptDir = iString(e) + iDirectory::Separator(); else mEnvScriptDir = mEnvBaseDir; - e = getenv("IFRIT_PALETTE_DIR"); if(e != 0) mEnvPaletteDir = iString(e) + iDirectory::Separator(); else mEnvPaletteDir = mEnvBaseDir; - - iDirectory::ExpandFileName(mEnvBaseDir); - iDirectory::ExpandFileName(mEnvDataDir); - iDirectory::ExpandFileName(mEnvImageDir); - iDirectory::ExpandFileName(mEnvScriptDir); - iDirectory::ExpandFileName(mEnvPaletteDir); - - mInitTimer = vtkTimerLog::New(); IERROR_ASSERT(mInitTimer); - mInitTimer->StartTimer(); - -#ifdef I_OFFSCREEN - // - // Configure Graphics Factory - // - vtkGraphicsFactory *graphics_factory = vtkGraphicsFactory::New(); IERROR_ASSERT(graphics_factory); - graphics_factory->SetOffScreenOnlyMode(1); - graphics_factory->SetUseMesaClasses(1); - // - // Configure Imaging Factory - vtkImagingFactory *imaging_factory = vtkImagingFactory::New(); IERROR_ASSERT(imaging_factory); - imaging_factory->SetUseMesaClasses(1); -#endif -} - - -iShell::~iShell() -{ - // - // This ensures that control module is deleted after the shell is deleted. - // - // mControlModule->Delete(); - mInitTimer->Delete(); -} - - -iShell* iShell::New(const iString &t, int argc, char **argv) -{ - // - // Check that sizes of basic types are correct - // - CheckSystem(); - // - // Check if a test call - // - if(argc==2 && iString(argv[1])==(mOptionPrefix+"test")) - { - TestPerformance(); - return 0; - } - // - // Also use options to specify shell - they overwrite the default choice - // - iString st = t; - int firstOption = 1; - if(argc>1 && iString(argv[1]).Part(0,mOptionPrefix.Length())==mOptionPrefix) - { - iString list, help, s = iString(argv[1]).Part(mOptionPrefix.Length()); - iShellFactory::GetSupportedShells(list,help); - if(list.Contains(s+"/") == 1) - { - st = s; - firstOption = 2; - } - } - // - // If there is no default and no option, ask ShellFactory to query the user - // - if(st.IsEmpty()) - { - iConsole::Display(iConsole::_FatalError,"No shell has been specified. Use a \"-\" option to specify a two-letter shell abbreviation ."); - return 0; - } - // - // Create shell - // - iShell *tmp = iShellFactory::CreateShell(st,argc,argv); - if(tmp == 0) - { - iConsole::Display(iConsole::_FatalError,"Shell '"+st+"' is not included in this installation."); - return 0; - } - tmp->mFirstOption = firstOption; - // - // Make sure Image factory is up to date - // - iImageFactory::FindIcon("genie1.png"); - // - // Parse command line options - // - tmp->DefineSpecificCommandLineOptions(); - tmp->ParseCommandLineOptions(argc,argv); - -#ifdef I_DEBUG - //tmp->mNumProcs = 2; -#endif - - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->PrepareForConstruction(); - } - -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // This ensures that "tmp->this" pointer is correct before a control module is created. - // - tmp->mCurInitStep = 1; - tmp->mControlModule = iControlModule::New(tmp); IERROR_ASSERT(tmp->mControlModule); - if(tmp->mNumProcs >= 0) tmp->mControlModule->GetParallelManager()->ResetMaxNumberOfProcessors(tmp->mNumProcs); - // - // Set the state file name - // - if(tmp->mStateFileName.IsEmpty()) - { - iString fname = tmp->GetEnvironment(_EnvironmentBase) + "ifrit.ini"; - if(iFile::IsReadable(fname)) tmp->mStateFileName = fname; - } - -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // Really construct the shell: control module needs to be fully initialized before a shell - // is really constructed. - // - tmp->mCurInitStep = 2; - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->ConstructorBody(); - } - // - // Check that vtkIdType is 64-bit on a 64-bit machine - // - if(sizeof(vtkIdType)==4 && sizeof(long)==8) - { - iConsole::Display(iConsole::_Notification,"This machine is 64-bit, but VTK has been compiled with 32-bit ids.\n" - " This configuration is inconsistent and is prone to crashes. \n" - " It is highly recommended that you recompile VTK with \n" - " advanced option VTK_USE_64BIT_IDS set to ON \n" - " and then recompile IFrIT. "); - } - // - // Load widget info into ObjectKeyHelp objects. - // -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - // - // Load the state file if needed - // - tmp->mCurInitStep = 3; - if(!tmp->mStateFileName.IsEmpty()) - { - if(tmp->mScriptFileName.IsEmpty()) - { - tmp->PrepareToLoadStateFile(); - } - if(!tmp->GetControlModule()->LoadStateFromFile(tmp->mStateFileName)) - { - iConsole::Display(iConsole::_HighError,"Unable to load the state file.\n Default values of parameters will be used."); - } - } -#ifdef I_DEBUG - tmp->InitHelper(); -#endif - - if(tmp->mScriptFileName.IsEmpty()) - { -#ifdef I_OFFSCREEN - // - // In the off-screen mode we need the script - // - iConsole::Display(iConsole::_FatalError,"A batch script filename is required in the off-screen-only mode."); - return 0; -#else - // - // Start the shell - // - tmp->Start(); - return tmp; -#endif - } - else - { - // - // Execute script and exit - // - int i, n = tmp->mControlModule->GetNumberOfViewModules(); - for(i=0; imControlModule->GetViewModule(i)->GetRenderWindow()->SetOffScreenRendering(1); - } - - if(tmp->mControlModule->GetViewModule(0)->GetRenderWindow()->GetOffScreenRendering() == 0) - { - iConsole::Display(iConsole::_FatalError,"This platform+shell combination does not support off-screen rendering.\n Off-screen rendering is needed for executing a script in a batch mode."); - return 0; - } - // - // Execute the batch script - // - iFile F(tmp->mScriptFileName); - - if(!F.Open(iFile::_Read,iFile::_Text)) - { - iConsole::Display(iConsole::_FatalError,iString("File ")+tmp->mScriptFileName+" cannot be open for reading."); - return 0; - } - - iConsole::Display(iConsole::_Info,"Reading the file..."); - iString text, line; - while(F.ReadLine(line)) text += "\n" + line; - text += "\n"; - - iControlScript *cs = tmp->mControlModule->GetControlScript(); - iConsole::Display(iConsole::_Info,"Compiling the script..."); - - cs->SetText(text); - if(!cs->Compile()) - { - iConsole::Display(iConsole::_FatalError,iString("Syntax error in script, line ")+iString::FromNumber(cs->GetThisLine())+" : "+cs->GetErrorStatus()->Message()); - return 0; - } - - cs->SetAutoRender(false); - - iConsole::Display(iConsole::_Info,"Running the script..."); - BatchModeObserver *obs = new BatchModeObserver(cs); - cs->Execute(); - if(obs != 0) delete obs; - if(cs->GetErrorStatus()->IsError()) - { - iConsole::Display(iConsole::_HighError,iString("Runtime error in script, line ")+iString::FromNumber(cs->GetThisLine())+" : "+cs->GetErrorStatus()->Message()); - } - else iConsole::Display(iConsole::_Info,"Done."); - - tmp->Delete(); - return 0; - } -} - - -void iShell::Delete() -{ - // - // We are just about to start deleting objects. First thing we do is to block all - // observers since we do not know at each moment in the deleting process which objects - // are still present and which have been already deleted. - // - iEventObserver::BlockAllEventObservers(true); - - // - // Check whether the error log was created by iConsole: - // - iOutputChannel::GetInstance()->NotifyIfLogCreated(); - - // - // Go on rampage! - // - if(mScriptFileName.IsEmpty()) - { - this->DestructorBody(); - } - - // - // This ensures that control module is deleted before the shell is deleted. - // - mControlModule->Delete(); - - this->vtkObjectBase::Delete(); -} - - -void iShell::Run() -{ - mRunning = true; - this->RunBody(); - mRunning = false; -} - - -void iShell::AddCommandLineOption(const iString &root, bool hasValue, const iString &help) -{ - Option tmp; - tmp.Name = root; - tmp.NeedsValue = hasValue; - tmp.Help = help; - mOptions.Add(tmp); -} - - -void iShell::ParseCommandLineOptions(int argc, char **argv) -{ - int i, j; - Option o; - bool done; - - i = mFirstOption; - while(i < argc) - { - done = false; - if(iString(argv[i]).Part(0,mOptionPrefix.Length()) == mOptionPrefix) - { - o.Name = argv[i] + mOptionPrefix.Length(); - for(j=0; !done && j16384) return false; - mNumProcs = n; - return true; - } - - if(o.Name == "i") - { - iString fn(o.Value); - iDirectory::ExpandFileName(fn,this->GetEnvironment(_EnvironmentBase)); - if(iFile::IsReadable(fn)) - { - mStateFileName = fn; - return true; - } - else - { - iConsole::Display(iConsole::_HighError,"File "+fn+" is not accessible.\nIFrIT will now exit."); - exit(1); - } - } - - if(o.Name == "b") - { - iString fn (o.Value); - iDirectory::ExpandFileName(fn,this->GetEnvironment(_EnvironmentBase)); - if(iFile::IsReadable(fn)) - { - mScriptFileName = fn; - return true; - } - else - { - iConsole::Display(iConsole::_HighError,"File "+fn+" is not accessible.\nIFrIT will now exit."); - exit(1); - } - } - - return this->AnalyseOneExtendedCommandLineOption(o); -} - - -// -// Environment querying -// -const iString& iShell::GetEnvironment(int key) const -{ - static const iString none; - - switch(key) - { - case _EnvironmentBase: - { - return mEnvBaseDir; - } - case _EnvironmentData: - { - return mEnvDataDir; - } - case _EnvironmentImage: - { - return mEnvImageDir; - } - case _EnvironmentScript: - { - return mEnvScriptDir; - } - case _EnvironmentPalette: - { - return mEnvPaletteDir; - } - default: - { - return none; - } - } -} - - -bool iShell::HasStateFile() const -{ - return !mStateFileName.IsEmpty(); -} - - -bool iShell::LoadShellStateFromFile(iFile &F) -{ - if(mScriptFileName.IsEmpty()) - { - return this->LoadShellStateFromFileBody(F); - } - else return true; -} - - -bool iShell::SaveShellStateToFile(iFile &F) const -{ - if(mScriptFileName.IsEmpty()) - { - return this->SaveShellStateToFileBody(F); - } - else return true; -} - - -void iShell::OnInitAtom() -{ - mInitSteps[mCurInitStep].Current++; - mInitTimer->StopTimer(); - if(mInitTimer->GetElapsedTime() > 0.1) - { - mInitTimer->StartTimer(); - this->OnInitAtomBody(true); - } - else - { - this->OnInitAtomBody(false); - } -} - - -void iShell::OnInitAtomBody(bool) -{ -} - - -void iShell::OnLoadStateFileAtom(int prog) -{ - this->OnLoadStateFileAtomBody(prog); -} - - -void iShell::OnLoadStateFileAtomBody(int) -{ -} - - -#ifdef I_DEBUG - -void iShell::InitHelper() -{ - if(mInitSteps[mCurInitStep].Current != mInitSteps[mCurInitStep].Total) - { - int step = mCurInitStep; - int total = mInitSteps[mCurInitStep].Current; - int bp = 0; - } -} - -#endif - - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace iShell_Private -{ - void CheckSystem() - { - // - // Check that sizes of basic types are correct - // - if(sizeof(int)!=4 || sizeof(float)!=4 || sizeof(double)!=8 || sizeof(void*)!=sizeof(long)) - { - iConsole::Display(iConsole::_HighError,"IFrIT has not been ported to this machine."); - exit(0); - } - } - - float TestPerformanceWorker(vtkRenderer *ren, vtkSphereSource* sphere) - { - // - // Set up the timer - // - ren->GetActiveCamera()->SetPosition(0.0,0.0,1.0); - ren->ResetCamera(); - - vtkTimerLog *timer = vtkTimerLog::New(); - timer->StartTimer(); - - int i; - float r = 0.0f; - do - { - for(i=0; i<10; i++) - { - ren->GetActiveCamera()->Azimuth(0.1); - ren->GetRenderWindow()->Render(); - } - timer->StopTimer(); - r += 0.01f; - } - while(timer->GetElapsedTime() < 10.0); - - timer->Delete(); - - return r; - } - - - void TestPerformance() - { - const float renRateScale[2] = { 5.62e-2f, 4.61e-2f }; - - vtkRenderer *ren = vtkRenderer::New(); - vtkRenderWindow *win = vtkRenderWindow::New(); - win->AddRenderer(ren); - ren->Delete(); - - vtkImageData *data = vtkImageData::New(); - data->SetDimensions(17,17,17); - data->SetSpacing(0.125,0.125,0.125); - data->SetOrigin(-1.0,-1.0,-1.0); - data->SetScalarTypeToUnsignedChar(); - data->SetNumberOfScalarComponents(1); - data->AllocateScalars(); - - // unsigned char *ptr = (unsigned char *)data->GetScalarPointer(); - - vtkCubeSource *cube = vtkCubeSource::New(); - cube->Update(); - - vtkGlyph3D *glyph = vtkGlyph3D::New(); - glyph->SetScaleModeToDataScalingOff(); - glyph->SetScaleFactor(0.08); - glyph->SetSource(cube->GetOutput()); - glyph->SetInput(data); - cube->Delete(); - glyph->Update(); - - vtkPolyDataMapper *mapper = vtkPolyDataMapper::New(); - vtkActor *actor = vtkActor::New(); - - mapper->ScalarVisibilityOff(); - - actor->GetProperty()->SetColor(0.0,0.0,0.0); - actor->SetMapper(mapper); - mapper->Delete(); - - mapper->SetInput(glyph->GetOutput()); - glyph->Delete(); - - ren->AddActor(actor); - actor->Delete(); - - // - // set the scene - // - win->SetSize(512,512); - ren->SetBackground(1.0,1.0,1.0); - - // - // draw the resulting scene - // - win->Render(); - win->SetWindowName("IFrIT - Performance Test"); - - iString ws = "Rendering performance (relative to NVIDIA Quadro FX 4000/AGP 8x):\n"; - float rr; - - actor->GetProperty()->SetOpacity(1.0); - actor->GetProperty()->SetColor(0.0,0.0,1.0); - rr = TestRenderingPerformance(ren)/renRateScale[0]; - ws += "Opaque:\t\t " + iString::FromNumber(round(rr)) + "%\n"; - - actor->GetProperty()->SetOpacity(0.03); - actor->GetProperty()->SetColor(1.0,0.0,0.0); - rr = TestRenderingPerformance(ren)/renRateScale[1]; - ws += "Transparent:\t " + iString::FromNumber(round(rr)) + "%\n"; - - iConsole::Display(iConsole::_Info,ws); - - data->Delete(); - win->RemoveRenderer(ren); - win->Delete(); - } -}; diff -Nru ifrit-3.3.4/core/.#iuniformgridfileloader.cpp.1.1 ifrit-3.4.2/core/.#iuniformgridfileloader.cpp.1.1 --- ifrit-3.3.4/core/.#iuniformgridfileloader.cpp.1.1 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#iuniformgridfileloader.cpp.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,1587 +0,0 @@ -//LICENSE A - - -#include "iuniformgridfileloader.h" - - -#include "icalculator.h" -#include "icommoneventobservers.h" -#include "idatalimits.h" -#include "idatasubject.h" -#include "ierrorstatus.h" -#include "ifile.h" -#include "iparallel.h" -#include "iparallelmanager.h" -#include "iparallelworker.h" -#include "iuniformgriddata.h" -#include "iviewmodule.h" -#include "ivtk.h" - -#include -#include -#ifndef IVTK_44 -#include -#endif - -#include "iparameter.h" -using namespace iParameter; - -// -// Templates (needed for some compilers) -// -#include "iarraytemplate.h" -#include "ibuffertemplate.h" -#include "icalculatortemplate.h" - - -// -// Helper classes for parallel executions -// -class iUniformGridHelper : protected iParallelWorker -{ - -public: - - iUniformGridHelper(iUniformGridFileLoader *loader); - - void ShiftData(int numCom, int dim, int dn, int dataDims[3], float *data, float *buf); - void ExpandUp(float *array, int nc, int oldDims[3], int newDims[3]); - void CollapseDown(float *array, int nc, int oldDims[3], int newDims[3]); - void PadPeriodically(float *array, int nc, int oldDims[3], int newDims[3]); - -protected: - - virtual int ExecuteStep(int step, iParallel::ProcessorInfo &p); - - void ExecuteShiftData(iParallel::ProcessorInfo &p); - void ExecutePadPeriodically(iParallel::ProcessorInfo &p); - - iUniformGridFileLoader *mLoader; - - int mNumCom; - int *mDims; - float *mArr1, *mArr2; - - float mProgStart, mProgStep; - - int mItmp1, mItmp2; -}; - - -class iUniformScalarsHelper : protected iParallelWorker -{ - -public: - - iUniformScalarsHelper(iUniformScalarsFileLoader *loader); - - void OperateOnData1(int nvar, int dims[3], const iString &calculatorExpression, bool doVector, float ps, float dp); - void OperateOnData2(int nvar, int dims[3], float *fMin, float *fMax, bool &overflow, float ps, float dp); - -protected: - - virtual int ExecuteStep(int step, iParallel::ProcessorInfo &p); - - void ExecuteOperateOnData1(iParallel::ProcessorInfo &p); - void ExecuteOperateOnData2(iParallel::ProcessorInfo &p); - - iUniformScalarsFileLoader *mLoader; - iProgressEventObserver *mObserver; - - iString mCalculatorExpression; - - int mNumVars, mNumProcs, *mDims; - - iBuffer mMin, mMax; - float mProgStart, mProgStep; - - bool mDoVector, mOverflow; -}; - - -// -// Main classes -// -// ******************************************************************** -// -// Generic GridFileLoader class -// -// ******************************************************************** -// -iUniformGridFileLoader::iUniformGridFileLoader(iDataReader *r, int priority, bool usePeriodicOffsets) : iFieldFileLoader(r,priority), mMaxDimension(1670000), mBufferSizeOffset(1), mUsePeriodicOffsets(usePeriodicOffsets) -{ - mNumVars = mNumComponents = 0; - - mOriginOffset[0] = mOriginOffset[1] = mOriginOffset[2] = 0.0; - - mVoxelLocation = _VoxelLocationVertex; - - mFileDims[0] = mFileDims[1] = mFileDims[2] = 0; - mDataDims[0] = mDataDims[1] = mDataDims[2] = 0; - - mBufferSize = 0; - mBuffer = 0; - - mScaledDim = -1; - - mHelper = new iUniformGridHelper(this); IERROR_ASSERT(mHelper); -} - - -iUniformGridFileLoader::~iUniformGridFileLoader() -{ - delete mHelper; -} - - -void iUniformGridFileLoader::ReadFileBody(const iString &suffix, const iString &fname) -{ - // - // is the suffix valid? - // - if(suffix.Lower()!="txt" && suffix.Lower()!="bin") - { - this->GetErrorStatus()->Set("Incorrect file suffix."); - return; - } - - // - // Read the data - // - if(suffix.Lower() == "txt") this->ReadTxtFile(fname); else this->ReadBinFile(fname); -} - - -void iUniformGridFileLoader::ReadBinFile(const iString &fname) -{ - int i; - vtkIdType l, ntot; - float vmin, vmax, *d; - iFile F(fname); - bool err; - - if(!F.Open(iFile::_Read,iFile::_Binary)) - { - this->GetErrorStatus()->Set("File does not exist."); - return; - } - - mObserver->Started(iProgressEventObserver::_Reading); - mObserver->SetProgress(0.0); - - // - // auto-detect data endiness - // - if(!this->DetectFortranFileStructure(F,3*sizeof(int))) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - // - // Read the header - // - err = false; - int ndim[3]; - if(!this->ReadFortranRecord(F,Buffer(ndim,3),0.0,0.0)) err = true; - - if(ndim[0]<1 || ndim[0]>mMaxDimension || ndim[1]<1 || ndim[1]>mMaxDimension || ndim[2]<1 || ndim[2]>mMaxDimension) err = true; - - if(err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - ntot = (vtkIdType)ndim[0]*ndim[1]*ndim[2]; - // - // Measure the file size by skipping blocks with size of one variable - // - int nvar, nrec; - int mar = F.SetMarker(); - for(nrec=0; nrec<999 && this->SkipFortranRecord(F,long(sizeof(float))*ntot); nrec++); - F.ReturnToMarker(mar,true); - - nvar = nrec; - this->SetIndicies(nvar,nrec); - // - // If no records, exit - // - if(nvar < 1) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted data."); - return; - } - mObserver->SetProgress(0.01); - // - // parameters for the Progress Bar - // - float prog1 = 0.99/nrec; - // - // Allocate memory; erase the old mBuffer if needed. - // - long newBufferSize = long(ndim[0]+mBufferSizeOffset)*long(ndim[1]+mBufferSizeOffset)*long(ndim[2]+mBufferSizeOffset)*long(nvar); - if(newBufferSize>mBufferSize || newBufferSizeFinished(); - this->GetErrorStatus()->Set("Not enough memory to load the data."); - return; - } - } - // - // Read the data from the file. - // - d = new float[ntot]; - if(d == 0) - { - this->EraseBuffer(); - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Not enough memory to load the data."); - return; - } - - for(i=0; !err && iReadFortranRecord(F,Buffer(d,ntot),0.01+prog1*i,prog1); - if(err || mObserver->IsAborted()) break; - - this->AssignBinData(nvar,ntot,i,d); - vmin = vmax = d[0]; - for(l=1; l d[l]) vmin = d[l]; - if(vmax < d[l]) vmax = d[l]; - mVarMin[i] = vmin; - mVarMax[i] = vmax; - } - } - - delete [] d; - - mObserver->SetProgress(1.0); - mObserver->Finished(); - F.Close(); - - if(err || mObserver->IsAborted()) - { - this->EraseBuffer(); - if(err) this->GetErrorStatus()->Set("Corrupted data."); else this->GetErrorStatus()->SetAbort(); - return; - } - - mNumVars = nvar; - for(i=0; i<3; i++) mFileDims[i] = ndim[i]; -} - - -void iUniformGridFileLoader::ReadTxtFile(const iString &fname) -{ - int i, n1, n2, n3, ret; - iString s; - long ntot, l; - float f[999]; - iFile F(fname); - bool err; - - if(!F.Open(iFile::_Read,iFile::_Text)) - { - this->GetErrorStatus()->Set("File does not exist."); - return; - } - - mObserver->Started(iProgressEventObserver::_Reading); - mObserver->SetProgress(0.0); - // - // Read the header - // - err = false; - if(!F.ReadLine(s)) err = true; - - ret = sscanf(s.ToCharPointer(),"%d %d %d",&n1,&n2,&n3); - if(ret != 3) err = true; - - if(n1<1 || n1>mMaxDimension || n2<1 || n2>mMaxDimension || n3<1 || n3>mMaxDimension) err = true; - - if(err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - ntot = (vtkIdType)n1*n2*n3; - // - // Find out the number of variables - // - if(!F.ReadLine(s)) err = true; - ret = sscanf(s.ToCharPointer(),"%g %g %g %g %g %g %g %g %g %g",&f[0],&f[1],&f[2],&f[3],&f[4],&f[5],&f[6],&f[7],&f[8],&f[9]); - if(ret<1 || ret>10) err = true; - int nvar = 0, nrec = ret; - - nvar = nrec; - this->SetIndicies(nvar,nrec); - // - // If no records or an error, exit - // - if(nvar<1 || err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted data."); - return; - } - - mObserver->SetProgress(0.01); - // - // Allocate memory; erase the old mBuffer if needed. - // - long newBufferSize = long(n1+mBufferSizeOffset)*long(n2+mBufferSizeOffset)*long(n3+mBufferSizeOffset)*long(nvar); - if(newBufferSize>mBufferSize || newBufferSizeFinished(); - this->GetErrorStatus()->Set("Not enough memory to create the data."); - return; - } - } - // - // Save the first line - // - this->AssignTxtData(nvar,ntot,0,f); - for(i=0; iSetProgress(0.01+(float)l/ntot); - if(mObserver->IsAborted()) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->SetAbort(); - return; - } - } - - this->AssignTxtData(nvar,ntot,l,f); - for(i=0; i f[i]) mVarMin[i] = f[i]; - if(mVarMax[i] < f[i]) mVarMax[i] = f[i]; - } - } - - mObserver->SetProgress(1.0); - mObserver->Finished(); - F.Close(); - - if(err || mObserver->IsAborted()) - { - this->EraseBuffer(); - if(err) this->GetErrorStatus()->Set("Corrupted data."); else this->GetErrorStatus()->SetAbort(); - return; - } - - mNumVars = nvar; - mFileDims[0] = n1; - mFileDims[1] = n2; - mFileDims[2] = n3; -} - - -void iUniformGridFileLoader::EraseBuffer() -{ - delete [] mBuffer; - mBuffer = 0; - mBufferSize = 0; -} - - -void iUniformGridFileLoader::FinalizeBody() -{ - int i; - - // - // Do not do anything if there is no data - // - if(mBuffer!=0 && mFileDims[0]>0 && mFileDims[1]>0 && mFileDims[2]>0) - { - // - // Configure Limits and components - // - mNumComponents = 0; - this->GetStream(0)->Subject->GetLimits()->ResetVars(); - this->SetArraysAndComponents(); -#ifdef I_CHECK1 - if(mNumVars != mNumComponents) - { - IERROR_LOW("Bug in iUniformGridFileLoader."); - } -#endif - - this->OperateOnData(); - - // - // Specify data dimensions - // - for(i=0; i<3; i++) mDataDims[i] = mFileDims[i]; - - // - // Implement periodic BC - // - if(mUsePeriodicOffsets && mVoxelLocation==_VoxelLocationCenter && this->IsBoxPeriodic()) - { - // - // Expand the box and add extra values. - // - for(i=0; i<3; i++) if(this->IsDirectionPeriodic(i)) mDataDims[i]++; - mHelper->ExpandUp(mBuffer,mNumComponents,mFileDims,mDataDims); - mHelper->PadPeriodically(mBuffer,mNumComponents,mFileDims,mDataDims); - } - - this->ReleaseData(); - } -} - - -void iUniformGridFileLoader::SetVoxelLocation(int m) -{ - if(m>=0 && m<__NumVoxelLocations && mVoxelLocation!=m) - { - int oldLoc = mVoxelLocation; - mVoxelLocation = m; - - if(this->IsThereData()) - { - if(mUsePeriodicOffsets && this->IsBoxPeriodic()) - { - int i; - if(oldLoc==_VoxelLocationVertex && mVoxelLocation==_VoxelLocationCenter) - { - for(i=0; i<3; i++) if(this->IsDirectionPeriodic(i)) mDataDims[i] = mFileDims[i] + 1; - mHelper->ExpandUp(mBuffer,mNumComponents,mFileDims,mDataDims); - mHelper->PadPeriodically(mBuffer,mNumComponents,mFileDims,mDataDims); - } - if(oldLoc==_VoxelLocationCenter && mVoxelLocation==_VoxelLocationVertex) - { - mHelper->CollapseDown(mBuffer,mNumComponents,mDataDims,mFileDims); - for(i=0; i<3; i++) mDataDims[i] = mFileDims[i]; - } - } - this->ReleaseData(); - this->NotifyDependencies(); - } - } -} - - -void iUniformGridFileLoader::ReleaseData() -{ - double org[3], spa[3]; - this->ComputeSpacing(org,spa); - - iUniformGridData *data = iUniformGridData::New(); IERROR_ASSERT(data); - data->SetDimensions(mDataDims); - data->SetOrigin(org); - data->SetSpacing(spa); - - data->SetInternalProperties(mVoxelLocation,mFileDims,mDataDims); - - this->AttachBuffer(data); - this->AttachDataToStream(0,data); - - data->Delete(); -} - - -void iUniformGridFileLoader::Polish(vtkDataSet *ds) -{ -#ifndef IVTK_44 - // - // Extra class needed under VTK 5. What a mess! - // - vtkImageData *d = vtkImageData::SafeDownCast(ds); - if(d != 0) - { - vtkInformation *info = d->GetPipelineInformation(); - if(info == 0) - { - info = vtkInformation::New(); IERROR_ASSERT(info); - d->SetPipelineInformation(info); - } - - double spa[3], org[3]; - d->GetOrigin(org); - d->GetSpacing(spa); - - info->Set(vtkDataObject::ORIGIN(),org,3); - info->Set(vtkDataObject::SPACING(),spa,3); - } -#endif -} - - -void iUniformGridFileLoader::SetScaledDimension(int v) -{ - if(v>=-2 && v<=2) - { - mScaledDim = v; - - if(!this->IsBoxPeriodic() && this->IsThereData()) - { - // - // Reset spacing - // - vtkStructuredPoints *data = iRequiredCast(INFO,this->GetStream(0)->ReleasedData); - - double org[3], spa[3]; - this->ComputeSpacing(org,spa); - data->SetOrigin(org); - data->SetSpacing(spa); - this->ShiftDataBody(data,mShift); - } - } -} - - -void iUniformGridFileLoader::ComputeSpacing(double org[3], double spa[3]) -{ - int i; - - if(mFileDims[0]<=0 || mFileDims[1]<=0 || mFileDims[2]<=0) return; - - // - // Now we need to decide whether the data are CellData or PointData. We use voxelLocation for that: - // if it is 0, we have point data and we place the first point into (-1,-1,-1) corner; - // if it is 1, we have cell data and we place the first point into the center of the first cell (mOriginOffset). - // - float shift; - if(mVoxelLocation == _VoxelLocationVertex) - { - shift = 0.0; - } - else - { - shift = 0.5; - } - for(i=0; i<3; i++) mOriginOffset[i] = shift*2.0/mFileDims[i]; - - // - // Find longest and short dimensions - // - int nmax, nmin; - int imax = 0, imin = 0; - nmax = nmin = mFileDims[0]; - for(i=1; i<3; i++) - { - if(nmax < mFileDims[i]) - { - nmax = mFileDims[i]; - imax = i; - } - if(mFileDims[i]>1 && nmin>mFileDims[i]) - { - nmin = mFileDims[i]; - imin = i; - } - } - - for(i=0; i<3; i++) this->SetDirectionPeriodic(i,mFileDims[i]==nmax); - - if(this->IsBoxPeriodic()) - { - i = imax; - } - else - { - switch (mScaledDim) - { - case -1: - { - i = imin; - break; - } - case 0: - case 1: - case 2: - { - if(mFileDims[mScaledDim] > 1) i = mScaledDim; else i = imin; - break; - } - case -2: - default: - { - i = imax; - break; - } - } - } - - double s = (2.0-2*mOriginOffset[i])/(mFileDims[i]-1); - - for(i=0; i<3; i++) - { - org[i] = -1.0 + shift*s; - spa[i] = s; - } -} - - -void iUniformGridFileLoader::ShiftDataBody(vtkDataSet *dataIn, double dx[3]) -{ - vtkStructuredPoints *data = vtkStructuredPoints::SafeDownCast(dataIn); - if(data==0 || !this->IsThereData(0)) return; - - int d, dn; - for(d=0; d<3; d++) - { - dn = round(dx[d]*mDataDims[d]) % mDataDims[d]; - if(this->IsDirectionPeriodic(d) && dn!=0) - { - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*mNumComponents; - float *buf = new float[mNumComponents*mDataDims[d]]; if(buf == 0) return; - if(data->GetPointData()!=0 && data->GetPointData()->GetScalars()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetScalars()->GetVoidPointer(0),buf); - } - if(data->GetPointData()!=0 && data->GetPointData()->GetVectors()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetVectors()->GetVoidPointer(0),buf); - } - if(data->GetPointData()!=0 && data->GetPointData()->GetTensors()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetTensors()->GetVoidPointer(0),buf); - } - delete[] buf; - - double org[3]; - data->GetOrigin(org); - org[d] += 2.0*(dx[d]-float(dn)/mDataDims[d]); - data->SetOrigin(org); - } - else - { - double org[3]; - data->GetOrigin(org); - org[d] += 2.0*dx[d]; - data->SetOrigin(org); - } - } - - data->Modified(); -} - - -bool iUniformGridFileLoader::IsCompatible(iUniformGridFileLoader *other) const -{ - return (this->IsThereData() && other!=0 && other->IsThereData() && mVoxelLocation==other->mVoxelLocation && mFileDims[0]==other->mFileDims[0] && mFileDims[1]==other->mFileDims[1] && mFileDims[2]==other->mFileDims[2]); -} - - -// -// ******************************************************************** -// -// iUniformVectorsFileLoader class -// -// ******************************************************************** -// -iUniformVectorsFileLoader::iUniformVectorsFileLoader(iDataReader *r) : iUniformGridFileLoader(r,100,false) -{ -} - - -void iUniformVectorsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - nvar = 3; - ncomp = 3; -} - - -void iUniformVectorsFileLoader::AssignBinData(int, vtkIdType ntot, int com, float *d) -{ - vtkIdType l; - for(l=0; lGetStream(0)->Subject->GetLimits()->AddVar(0); - if(!this->GetStream(0)->Subject->GetFixedLimits()) - { - this->GetStream(0)->Subject->GetLimits()->SetMin(0,0.0f); - this->GetStream(0)->Subject->GetLimits()->SetMax(0,sqrt(mVarMax[0]*mVarMax[0]+mVarMax[1]*mVarMax[1]+mVarMax[2]*mVarMax[2])); - } -} - - -void iUniformVectorsFileLoader::AttachBuffer(vtkStructuredPoints *data) -{ - // - // Attach the actual data - // - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*3; - vtkFloatArray *array = vtkFloatArray::New(); IERROR_ASSERT(array); - array->SetNumberOfComponents(3); - array->SetArray(mBuffer,size,1); - array->SetName("Vectors"); - data->GetPointData()->SetVectors(array); - array->Delete(); -} - - -// -// ******************************************************************** -// -// iUniformTensorsFileLoader class -// -// ******************************************************************** -// -iUniformTensorsFileLoader::iUniformTensorsFileLoader(iDataReader *r) : iUniformGridFileLoader(r,200,false) -{ -} - - -void iUniformTensorsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - nvar = 9; - ncomp = 6; -} - - -void iUniformTensorsFileLoader::AssignBinData(int, vtkIdType ntot, int com, float *d) -{ - int noff1, noff2; - vtkIdType l; - - switch(com) - { - case 0: { noff1 = 0; noff2 = -1; break; } - case 1: { noff1 = 1; noff2 = 3; break; } - case 2: { noff1 = 2; noff2 = 6; break; } - case 3: { noff1 = 4; noff2 = -1; break; } - case 4: { noff1 = 5; noff2 = 7; break; } - case 5: { noff1 = 8; noff2 = -1; break; } - default: - { - noff1 = 0; noff2 = -1; - IERROR_LOW("Bug detected."); - } - } - - for(l=0; l 0) for(l=0; lGetStream(0)->Subject->GetLimits()->AddVar(0); - if(this->GetStream(0)->Subject->GetFixedLimits()) - { - this->GetStream(0)->Subject->GetLimits()->SetMin(0,0.0f); - this->GetStream(0)->Subject->GetLimits()->SetMax(0,sqrt(mVarMax[0]*mVarMax[0]+mVarMax[1]*mVarMax[1]+mVarMax[2]*mVarMax[2]+mVarMax[3]*mVarMax[3]+mVarMax[4]*mVarMax[4]+mVarMax[5]*mVarMax[5]+mVarMax[6]*mVarMax[6]+mVarMax[7]*mVarMax[7]+mVarMax[8]*mVarMax[8])); - } -} - - -void iUniformTensorsFileLoader::AttachBuffer(vtkStructuredPoints *data) -{ - // - // Attach the actual data - // - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*9; - vtkFloatArray *array = vtkFloatArray::New(); IERROR_ASSERT(array); - array->SetNumberOfComponents(9); - array->SetArray(mBuffer,size,1); - array->SetName("Tensors"); - data->GetPointData()->SetTensors(array); - array->Delete(); -} - - -// -// ******************************************************************** -// -// iUniformScalarsFileLoader class -// -// ******************************************************************** -// -iUniformScalarsFileLoader::iUniformScalarsFileLoader(iDataReader *r, iUniformVectorsFileLoader *vs) : iUniformGridFileLoader(r,0,true) -{ - mVectorFieldLoader = vs; - - mCalculatorOutput = 0; -// mCalculatorExpression = ""; - - mHelper2 = new iUniformScalarsHelper(this); IERROR_ASSERT(mHelper2); -} - - -iUniformScalarsFileLoader::~iUniformScalarsFileLoader() -{ - delete mHelper2; -} - - -void iUniformScalarsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - // - // Try to set all the records from the file. DataLimits will either expand to accommodate - // all of them or limit the allowed number to the number of listed records. - // - this->GetStream(0)->Subject->GetLimits()->BlockNotifications(true); - this->GetStream(0)->Subject->GetLimits()->AssignVars(nvar); - this->GetStream(0)->Subject->GetLimits()->BlockNotifications(false); - ncomp = nvar = this->GetStream(0)->Subject->GetLimits()->GetNumVars(); -} - - -void iUniformScalarsFileLoader::AssignBinData(int nvar, vtkIdType ntot, int com, float *d) -{ - vtkIdType l; - for(l=0; lSetNumberOfComponents(mNumVars); - array->SetArray(mBuffer,size,1); - array->SetName("Scalars"); - data->GetPointData()->SetScalars(array); - array->Delete(); - - data->SetScalarTypeToFloat(); - data->SetNumberOfScalarComponents(mNumVars); -} - - -void iUniformScalarsFileLoader::SetArraysAndComponents() -{ - mNumComponents = mNumVars; - this->GetStream(0)->Subject->GetLimits()->AssignVars(mNumVars); - // - // Limits are set after the data are operated upon - // -} - - -void iUniformScalarsFileLoader::SetCalculatorOutput(int n) -{ - if(n>=0 && nGetStream(0)->Subject->GetLimits()->GetNumVars()) - { - mCalculatorOutput = n; - } -} - - -void iUniformScalarsFileLoader::SetCalculatorExpression(const iString &s) -{ - mCalculatorExpression = s; -} - - -void iUniformScalarsFileLoader::OperateOnData() -{ - int n; - float fMin = iMath::_LargeFloat, fMax = -iMath::_LargeFloat, f = 0.0; - - iDataLimits *slim = this->GetStream(0)->Subject->GetLimits(); - iDataLimits *vlim = mVectorFieldLoader->GetSubject(0)->GetLimits(); - slim->BlockNotifications(true); - int nvar = slim->GetNumVars(); - - // - // Do the array function first - // - if(mCalculatorOutput>=0 && mCalculatorOutputGetObserver()->Started(iProgressEventObserver::_Operating); - this->GetObserver()->SetProgress(0.0); - - bool doVector = false; - if(this->IsCompatible(mVectorFieldLoader)) doVector = true; - - mHelper2->OperateOnData1(nvar,mFileDims,mCalculatorExpression,doVector,0.0,1.0); - } - - this->GetObserver()->Started(iProgressEventObserver::_Formatting); - this->GetObserver()->SetProgress(0.0); - - // - // Format everything in parallel - // - mVarMin.Extend(nvar); - mVarMax.Extend(nvar); - mHelper2->OperateOnData2(nvar,mFileDims,mVarMin,mVarMax,mOverflow,0.0,1.0); - -#ifdef I_CHECK2 - // - // Format everything serially - // - vtkIdType lMin, lMax, size = (vtkIdType)mFileDims[0]*mFileDims[1]*mFileDims[2]; - for(n=0; n fMax) - { - lMax = l; - fMax = f; - } - if(f < fMin) - { - lMin = l; - fMin = f; - } - } - if(fabs(mVarMin[n]-fMin)>iMath::_FloatRes || fabs(mVarMax[n]-fMax)>iMath::_FloatRes) - { - IERROR_REPORT_BUG; - } - } -#endif - - this->GetObserver()->SetProgress(1.0); - this->GetObserver()->Finished(); - - // - // Correct limits in log stretching - // - if(!this->GetStream(0)->Subject->GetFixedLimits()) - { - for(n=0; nGetStretch(n) == 1) - { - fMin = 0.1*floor(10.0*fMin); - fMax = 0.1*floor(1+10.0*fMax); - } - slim->SetMin(n,fMin); - slim->SetMax(n,fMax); - } - } - - slim->BlockNotifications(false); -} - - -// -// Helper class -// -iUniformGridHelper::iUniformGridHelper(iUniformGridFileLoader *loader) : iParallelWorker(loader->GetViewModule()->GetParallelManager()) -{ - mLoader = loader; -} - - -void iUniformGridHelper::ShiftData(int numCom, int dim, int dn, int dataDims[3], float *data, float *buf) -{ - mNumCom = numCom; - mDims = dataDims; - mItmp2 = dn; - mItmp1 = dim; - mArr1 = data; - mArr2 = buf; - - this->ParallelExecute(1); -} - - -void iUniformGridHelper::ExpandUp(float *array, int nc, int oldDims[3], int newDims[3]) -{ - // - // Can we do this in parallel? - // - int i, j, k; - float *ptr; - - if(array==0 || nc<1 || oldDims[0]<1 || oldDims[1]<1 || oldDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::ExpandUp."); - return; - } - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]+1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for expanding data."); - return; - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Started(iProgressEventObserver::_Formatting); - } - - long oldN12 = nc*oldDims[0]*oldDims[1]; - long newN12 = nc*newDims[0]*newDims[1]; - long size12 = oldN12*sizeof(float); - - if(newN12 > oldN12) - { - // - // Move plains - // - for(k=oldDims[2]-1; k>=1; k--) - { - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5*float(oldDims[2]-1-k)/oldDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - memmove(array+k*newN12,array+k*oldN12,size12); // will memcpy work? - } - } - - long oldN1 = nc*oldDims[0]; - long newN1 = nc*newDims[0]; - long size1 = oldN1*sizeof(float); - - if(newN1 > oldN1) - { - // - // Move rows - // - for(k=0; kGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5+0.5*float(k)/oldDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - ptr = array + k*newN12; - for(j=oldDims[1]-1; j>=1; j--) - { - memmove(ptr+j*newN1,ptr+j*oldN1,size1); - } - } - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Finished(); - } -} - - -void iUniformGridHelper::CollapseDown(float *array, int nc, int oldDims[3], int newDims[3]) -{ - // - // Can we do this in parallel? - // - int i, j, k; - float *ptr; - - if(array==0 || nc<1 || newDims[0]<1 || newDims[1]<1 || newDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::CompressDown."); - return; - } - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]-1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for collapsing data."); - return; - } - - long oldN12 = nc*oldDims[0]*oldDims[1]; - long oldN1 = nc*oldDims[0]; - long newN1 = nc*newDims[0]; - long size1 = newN1*sizeof(float); - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Started(iProgressEventObserver::_Formatting); - } - - if(newN1 < oldN1) - { - // - // Move rows - // - for(k=0; kGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5*float(k)/newDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - - ptr = array + k*oldN12; - for(j=1; jGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5+0.5*float(k)/newDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - memmove(array+k*newN12,array+k*oldN12,size12); // will memcpy work? - } - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Finished(); - } -} - - -void iUniformGridHelper::PadPeriodically(float *array, int nc, int oldDims[3], int newDims[3]) -{ - int i, j, k; - float *ptr; - long size, offset; - - if(array==0 || nc<1 || oldDims[0]<1 || oldDims[1]<1 || oldDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::PadPeriodically."); - return; - } - - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]+1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for padding data."); - return; - } - - // - // Do x-direction - // - if(newDims[0] > oldDims[0]) - { - size = nc*sizeof(float); - offset = oldDims[0]*nc; - for(k=0; k oldDims[1]) - { - size = newDims[0]*nc*sizeof(float); - offset = oldDims[1]*newDims[0]*nc; - for(k=0; k oldDims[2]) - { - size = newDims[1]*newDims[0]*nc*sizeof(float); - offset = oldDims[2]*newDims[1]*newDims[0]*nc; - - memcpy(array+offset,array,size); - } - -#ifdef I_CHECK2 - bool ok = true; - int l, ijk1[3], ijk2[3]; - for(k=0; ok && k<3; k++) if(newDims[k] > oldDims[k]) - { - i = (k+1) % 3; - j = (k+2) % 3; - ijk1[k] = 0; - ijk2[k] = oldDims[k]; - - for(ijk1[j]=ijk2[j]=0; ok && ijk1[j]ExecuteShiftData(p); - return 0; - } - default: - { -#ifdef I_CHECK1 - IERROR_REPORT_BUG; -#endif - return 2; - } - } -} - - -// -// Shift an nc-component vertical array (treat the mesh array as nvar 1-component vertical arrays) -// -void iUniformGridHelper::ExecuteShiftData(iParallel::ProcessorInfo &p) -{ - int n, l1, l2, l, lold, add1; - int d1 = 0, d2 = 0; - - int d = mItmp1; - int dn = mItmp2; - - switch(d) - { - case 0: { d1 = 1; d2 = 2; break; } - case 1: { d1 = 0; d2 = 2; break; } - case 2: { d1 = 0; d2 = 1; break; } - } - - int ddim = mDims[d]; - long off0 = 0L, off1 = 0L, add2; - - int kbeg, kend, kstp; - iParallel::SplitRange(p,mDims[d1],kbeg,kend,kstp); - - for(l1=kbeg; l1GetObserver() != 0) - { - if(this->IsMaster(p)) mLoader->GetObserver()->SetProgress((d+(float)(l1-kbeg)/(kend-kbeg))/3.0); - if(mLoader->GetObserver()->IsAborted()) return; - } - for(l2=0; l2= ddim) lold -= ddim; - - add1 = mNumCom*l; - add2 = off0 + off1*lold; - - for(n=0; nGetViewModule()->GetParallelManager()) -{ - mLoader = subject; - mObserver = subject->GetObserver(); -} - - -void iUniformScalarsHelper::OperateOnData1(int nvar, int dims[3], const iString &calculatorExpression, bool doVector, float ps, float dp) -{ - mNumVars = nvar; - mDims = dims; - mCalculatorExpression = calculatorExpression; - mDoVector = doVector; - - mProgStart = ps; - mProgStep = dp; - - iCalculator calc; - iCalculator::real_var var("Var",mNumVars,&calc); - iCalculator::real_var vec("Vec",3); - if(mDoVector) calc.AddVariable(&vec); - - if(!calc.Compile(mCalculatorExpression) || !calc.Link()) - { - IERROR_LOW(calc.GetErrorMessage()); - } - else - { - this->ParallelExecute(1); - } -} - - -void iUniformScalarsHelper::OperateOnData2(int nvar, int dims[3], float *fMin, float *fMax, bool &overflow, float ps, float dp) -{ - int i, n; - - mNumVars = nvar; - mDims = dims; - mNumProcs = this->GetManager()->GetNumberOfProcessors(); - mMin.Extend(mNumVars*mNumProcs); - mMax.Extend(mNumVars*mNumProcs); - - mProgStart = ps; - mProgStep = dp; - mOverflow = false; - - this->ParallelExecute(2); - - for(n=0; n mMin[n+nvar*i]) fMin[n] = mMin[n+nvar*i]; - if(fMax[n] < mMax[n+nvar*i]) fMax[n] = mMax[n+nvar*i]; - } - } - - overflow = mOverflow; -} - - -int iUniformScalarsHelper::ExecuteStep(int step, iParallel::ProcessorInfo &p) -{ - switch(step) - { - case 1: - { - this->ExecuteOperateOnData1(p); - return 0; - } - case 2: - { - if(mNumProcs != p.NumProcs) return 3; - this->ExecuteOperateOnData2(p); - return 0; - } - default: - { -#ifdef I_CHECK1 - IERROR_REPORT_BUG; -#endif - return 2; - } - } -} - - -// -// Operate on mesh data -// -void iUniformScalarsHelper::ExecuteOperateOnData1(iParallel::ProcessorInfo &p) -{ - float *arr1 = mLoader->GetDataPointer(); - float *arr2 = mLoader->mVectorFieldLoader->GetDataPointer(); - - if(arr1==0 || (mDoVector && arr2==0)) return; - - long size = (long)mDims[0]*mDims[1]*mDims[2]; - int nout = mLoader->GetCalculatorOutput(); - long l, kbeg, kend, kstp; - iParallel::SplitRange(p,size,kbeg,kend,kstp); - - float progScale = mProgStep/kstp; - - // - // Create our calculator - // - iCalculator calc; - - iCalculator::real_ptr var(arr1+kbeg*mNumVars,"Var",mNumVars,&calc); - iCalculator::real_ptr vec(arr2==0?arr1:arr2+kbeg*3,"Vec",3); - if(mDoVector) - { - calc.AddVariable(&vec); - } - - if(!calc.Compile(mCalculatorExpression) || !calc.Link()) return; - - const float *output = calc.GetResultData(); - - for(l=kbeg; lIsMaster(p)) mObserver->SetProgress(mProgStart+progScale*(l-kbeg)); - if(mObserver->IsAborted()) return; - } - if(!calc.Execute()) break; - arr1[nout+mNumVars*l] = *output; - ++var; - ++vec; - } -} - - -void iUniformScalarsHelper::ExecuteOperateOnData2(iParallel::ProcessorInfo &p) -{ - float fMin, fMax; - long size = (long)mDims[0]*mDims[1]*mDims[2]; - long kbeg, kend, kstp; - iParallel::SplitRange(p,size,kbeg,kend,kstp); - - // - // Format everything - // - iDataLimits *lim = mLoader->GetSubject(0)->GetLimits(); - - long l, larr; - int n; - - float *arr1 = mLoader->GetDataPointer(); - if(arr1 == 0) return; - - float progScale = mProgStep/(mNumVars*kstp); - - for(n=0; nIsMaster(p)) mObserver->SetProgress(mProgStart+progScale*(larr-kbeg+n*kstp)); - if(mObserver->IsAborted()) return; - } - l = n + mNumVars*larr; - if(arr1[l] < -iMath::_LargeFloat) - { - mOverflow = true; - arr1[l] = -iMath::_LargeFloat; - } - if(arr1[l] > iMath::_LargeFloat) - { - mOverflow = true; - arr1[l] = iMath::_LargeFloat; - } - if(arr1[l] > fMax) fMax = arr1[l]; - if(arr1[l] < fMin) fMin = arr1[l]; - } - - if(mNumProcs == p.NumProcs) - { - mMin[n+mNumVars*p.ThisProc] = fMin; - mMax[n+mNumVars*p.ThisProc] = fMax; - } - } -} - diff -Nru ifrit-3.3.4/core/.#iuniformgridfileloader.cpp.1.2 ifrit-3.4.2/core/.#iuniformgridfileloader.cpp.1.2 --- ifrit-3.3.4/core/.#iuniformgridfileloader.cpp.1.2 2011-01-27 17:50:27.000000000 +0000 +++ ifrit-3.4.2/core/.#iuniformgridfileloader.cpp.1.2 1970-01-01 00:00:00.000000000 +0000 @@ -1,1587 +0,0 @@ -//LICENSE A - - -#include "iuniformgridfileloader.h" - - -#include "icalculator.h" -#include "icommoneventobservers.h" -#include "idatalimits.h" -#include "idatasubject.h" -#include "ierrorstatus.h" -#include "ifile.h" -#include "iparallel.h" -#include "iparallelmanager.h" -#include "iparallelworker.h" -#include "iuniformgriddata.h" -#include "iviewmodule.h" -#include "ivtk.h" - -#include -#include -#ifndef IVTK_44 -#include -#endif - -#include "iparameter.h" -using namespace iParameter; - -// -// Templates (needed for some compilers) -// -#include "iarraytemplate.h" -#include "ibuffertemplate.h" -#include "icalculatortemplate.h" - - -// -// Helper classes for parallel executions -// -class iUniformGridHelper : protected iParallelWorker -{ - -public: - - iUniformGridHelper(iUniformGridFileLoader *loader); - - void ShiftData(int numCom, int dim, int dn, int dataDims[3], float *data, float *buf); - void ExpandUp(float *array, int nc, int oldDims[3], int newDims[3]); - void CollapseDown(float *array, int nc, int oldDims[3], int newDims[3]); - void PadPeriodically(float *array, int nc, int oldDims[3], int newDims[3]); - -protected: - - virtual int ExecuteStep(int step, iParallel::ProcessorInfo &p); - - void ExecuteShiftData(iParallel::ProcessorInfo &p); - void ExecutePadPeriodically(iParallel::ProcessorInfo &p); - - iUniformGridFileLoader *mLoader; - - int mNumCom; - int *mDims; - float *mArr1, *mArr2; - - float mProgStart, mProgStep; - - int mItmp1, mItmp2; -}; - - -class iUniformScalarsHelper : protected iParallelWorker -{ - -public: - - iUniformScalarsHelper(iUniformScalarsFileLoader *loader); - - void OperateOnData1(int nvar, int dims[3], const iString &calculatorExpression, bool doVector, float ps, float dp); - void OperateOnData2(int nvar, int dims[3], float *fMin, float *fMax, bool &overflow, float ps, float dp); - -protected: - - virtual int ExecuteStep(int step, iParallel::ProcessorInfo &p); - - void ExecuteOperateOnData1(iParallel::ProcessorInfo &p); - void ExecuteOperateOnData2(iParallel::ProcessorInfo &p); - - iUniformScalarsFileLoader *mLoader; - iProgressEventObserver *mObserver; - - iString mCalculatorExpression; - - int mNumVars, mNumProcs, *mDims; - - iBuffer mMin, mMax; - float mProgStart, mProgStep; - - bool mDoVector, mOverflow; -}; - - -// -// Main classes -// -// ******************************************************************** -// -// Generic GridFileLoader class -// -// ******************************************************************** -// -iUniformGridFileLoader::iUniformGridFileLoader(iDataReader *r, int priority, bool usePeriodicOffsets) : iFieldFileLoader(r,priority), mMaxDimension(1670000), mBufferSizeOffset(1), mUsePeriodicOffsets(usePeriodicOffsets) -{ - mNumVars = mNumComponents = 0; - - mOriginOffset[0] = mOriginOffset[1] = mOriginOffset[2] = 0.0; - - mVoxelLocation = _VoxelLocationVertex; - - mFileDims[0] = mFileDims[1] = mFileDims[2] = 0; - mDataDims[0] = mDataDims[1] = mDataDims[2] = 0; - - mBufferSize = 0; - mBuffer = 0; - - mScaledDim = -1; - - mHelper = new iUniformGridHelper(this); IERROR_ASSERT(mHelper); -} - - -iUniformGridFileLoader::~iUniformGridFileLoader() -{ - delete mHelper; -} - - -void iUniformGridFileLoader::ReadFileBody(const iString &suffix, const iString &fname) -{ - // - // is the suffix valid? - // - if(suffix.Lower()!="txt" && suffix.Lower()!="bin") - { - this->GetErrorStatus()->Set("Incorrect file suffix."); - return; - } - - // - // Read the data - // - if(suffix.Lower() == "txt") this->ReadTxtFile(fname); else this->ReadBinFile(fname); -} - - -void iUniformGridFileLoader::ReadBinFile(const iString &fname) -{ - int i; - vtkIdType l, ntot; - float vmin, vmax, *d; - iFile F(fname); - bool err; - - if(!F.Open(iFile::_Read,iFile::_Binary)) - { - this->GetErrorStatus()->Set("File does not exist."); - return; - } - - mObserver->Started(iProgressEventObserver::_Reading); - mObserver->SetProgress(0.0); - - // - // auto-detect data endiness - // - if(!this->DetectFortranFileStructure(F,3*sizeof(int))) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - // - // Read the header - // - err = false; - int ndim[3]; - if(!this->ReadFortranRecord(F,Buffer(ndim,3),0.0,0.0)) err = true; - - if(ndim[0]<1 || ndim[0]>mMaxDimension || ndim[1]<1 || ndim[1]>mMaxDimension || ndim[2]<1 || ndim[2]>mMaxDimension) err = true; - - if(err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - ntot = (vtkIdType)ndim[0]*ndim[1]*ndim[2]; - // - // Measure the file size by skipping blocks with size of one variable - // - int nvar, nrec; - int mar = F.SetMarker(); - for(nrec=0; nrec<999 && this->SkipFortranRecord(F,long(sizeof(float))*ntot); nrec++); - F.ReturnToMarker(mar,true); - - nvar = nrec; - this->SetIndicies(nvar,nrec); - // - // If no records, exit - // - if(nvar < 1) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted data."); - return; - } - mObserver->SetProgress(0.01); - // - // parameters for the Progress Bar - // - float prog1 = 0.99/nrec; - // - // Allocate memory; erase the old mBuffer if needed. - // - vtkIdType newBufferSize = (vtkIdType)(ndim[0]+mBufferSizeOffset)*(vtkIdType)(ndim[1]+mBufferSizeOffset)*(vtkIdType)(ndim[2]+mBufferSizeOffset)*nvar; - if(newBufferSize>mBufferSize || newBufferSizeFinished(); - this->GetErrorStatus()->Set("Not enough memory to load the data."); - return; - } - } - // - // Read the data from the file. - // - d = new float[ntot]; - if(d == 0) - { - this->EraseBuffer(); - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Not enough memory to load the data."); - return; - } - - for(i=0; !err && iReadFortranRecord(F,Buffer(d,ntot),0.01+prog1*i,prog1); - if(err || mObserver->IsAborted()) break; - - this->AssignBinData(nvar,ntot,i,d); - vmin = vmax = d[0]; - for(l=1; l d[l]) vmin = d[l]; - if(vmax < d[l]) vmax = d[l]; - mVarMin[i] = vmin; - mVarMax[i] = vmax; - } - } - - delete [] d; - - mObserver->SetProgress(1.0); - mObserver->Finished(); - F.Close(); - - if(err || mObserver->IsAborted()) - { - this->EraseBuffer(); - if(err) this->GetErrorStatus()->Set("Corrupted data."); else this->GetErrorStatus()->SetAbort(); - return; - } - - mNumVars = nvar; - for(i=0; i<3; i++) mFileDims[i] = ndim[i]; -} - - -void iUniformGridFileLoader::ReadTxtFile(const iString &fname) -{ - int i, n1, n2, n3, ret; - iString s; - vtkIdType ntot, l; - float f[999]; - iFile F(fname); - bool err; - - if(!F.Open(iFile::_Read,iFile::_Text)) - { - this->GetErrorStatus()->Set("File does not exist."); - return; - } - - mObserver->Started(iProgressEventObserver::_Reading); - mObserver->SetProgress(0.0); - // - // Read the header - // - err = false; - if(!F.ReadLine(s)) err = true; - - ret = sscanf(s.ToCharPointer(),"%d %d %d",&n1,&n2,&n3); - if(ret != 3) err = true; - - if(n1<1 || n1>mMaxDimension || n2<1 || n2>mMaxDimension || n3<1 || n3>mMaxDimension) err = true; - - if(err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted header."); - return; - } - - ntot = (vtkIdType)n1*n2*n3; - // - // Find out the number of variables - // - if(!F.ReadLine(s)) err = true; - ret = sscanf(s.ToCharPointer(),"%g %g %g %g %g %g %g %g %g %g",&f[0],&f[1],&f[2],&f[3],&f[4],&f[5],&f[6],&f[7],&f[8],&f[9]); - if(ret<1 || ret>10) err = true; - int nvar = 0, nrec = ret; - - nvar = nrec; - this->SetIndicies(nvar,nrec); - // - // If no records or an error, exit - // - if(nvar<1 || err) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->Set("Corrupted data."); - return; - } - - mObserver->SetProgress(0.01); - // - // Allocate memory; erase the old mBuffer if needed. - // - vtkIdType newBufferSize = (vtkIdType)(n1+mBufferSizeOffset)*(vtkIdType)(n2+mBufferSizeOffset)*(vtkIdType)(n3+mBufferSizeOffset)*nvar; - if(newBufferSize>mBufferSize || newBufferSizeFinished(); - this->GetErrorStatus()->Set("Not enough memory to create the data."); - return; - } - } - // - // Save the first line - // - this->AssignTxtData(nvar,ntot,0,f); - for(i=0; iSetProgress(0.01+(float)l/ntot); - if(mObserver->IsAborted()) - { - F.Close(); - mObserver->Finished(); - this->GetErrorStatus()->SetAbort(); - return; - } - } - - this->AssignTxtData(nvar,ntot,l,f); - for(i=0; i f[i]) mVarMin[i] = f[i]; - if(mVarMax[i] < f[i]) mVarMax[i] = f[i]; - } - } - - mObserver->SetProgress(1.0); - mObserver->Finished(); - F.Close(); - - if(err || mObserver->IsAborted()) - { - this->EraseBuffer(); - if(err) this->GetErrorStatus()->Set("Corrupted data."); else this->GetErrorStatus()->SetAbort(); - return; - } - - mNumVars = nvar; - mFileDims[0] = n1; - mFileDims[1] = n2; - mFileDims[2] = n3; -} - - -void iUniformGridFileLoader::EraseBuffer() -{ - delete [] mBuffer; - mBuffer = 0; - mBufferSize = 0; -} - - -void iUniformGridFileLoader::FinalizeBody() -{ - int i; - - // - // Do not do anything if there is no data - // - if(mBuffer!=0 && mFileDims[0]>0 && mFileDims[1]>0 && mFileDims[2]>0) - { - // - // Configure Limits and components - // - mNumComponents = 0; - this->GetStream(0)->Subject->GetLimits()->ResetVars(); - this->SetArraysAndComponents(); -#ifdef I_CHECK1 - if(mNumVars != mNumComponents) - { - IERROR_LOW("Bug in iUniformGridFileLoader."); - } -#endif - - this->OperateOnData(); - - // - // Specify data dimensions - // - for(i=0; i<3; i++) mDataDims[i] = mFileDims[i]; - - // - // Implement periodic BC - // - if(mUsePeriodicOffsets && mVoxelLocation==_VoxelLocationCenter && this->IsBoxPeriodic()) - { - // - // Expand the box and add extra values. - // - for(i=0; i<3; i++) if(this->IsDirectionPeriodic(i)) mDataDims[i]++; - mHelper->ExpandUp(mBuffer,mNumComponents,mFileDims,mDataDims); - mHelper->PadPeriodically(mBuffer,mNumComponents,mFileDims,mDataDims); - } - - this->ReleaseData(); - } -} - - -void iUniformGridFileLoader::SetVoxelLocation(int m) -{ - if(m>=0 && m<__NumVoxelLocations && mVoxelLocation!=m) - { - int oldLoc = mVoxelLocation; - mVoxelLocation = m; - - if(this->IsThereData()) - { - if(mUsePeriodicOffsets && this->IsBoxPeriodic()) - { - int i; - if(oldLoc==_VoxelLocationVertex && mVoxelLocation==_VoxelLocationCenter) - { - for(i=0; i<3; i++) if(this->IsDirectionPeriodic(i)) mDataDims[i] = mFileDims[i] + 1; - mHelper->ExpandUp(mBuffer,mNumComponents,mFileDims,mDataDims); - mHelper->PadPeriodically(mBuffer,mNumComponents,mFileDims,mDataDims); - } - if(oldLoc==_VoxelLocationCenter && mVoxelLocation==_VoxelLocationVertex) - { - mHelper->CollapseDown(mBuffer,mNumComponents,mDataDims,mFileDims); - for(i=0; i<3; i++) mDataDims[i] = mFileDims[i]; - } - } - this->ReleaseData(); - this->NotifyDependencies(); - } - } -} - - -void iUniformGridFileLoader::ReleaseData() -{ - double org[3], spa[3]; - this->ComputeSpacing(org,spa); - - iUniformGridData *data = iUniformGridData::New(); IERROR_ASSERT(data); - data->SetDimensions(mDataDims); - data->SetOrigin(org); - data->SetSpacing(spa); - - data->SetInternalProperties(mVoxelLocation,mFileDims,mDataDims); - - this->AttachBuffer(data); - this->AttachDataToStream(0,data); - - data->Delete(); -} - - -void iUniformGridFileLoader::Polish(vtkDataSet *ds) -{ -#ifndef IVTK_44 - // - // Extra class needed under VTK 5. What a mess! - // - vtkImageData *d = vtkImageData::SafeDownCast(ds); - if(d != 0) - { - vtkInformation *info = d->GetPipelineInformation(); - if(info == 0) - { - info = vtkInformation::New(); IERROR_ASSERT(info); - d->SetPipelineInformation(info); - } - - double spa[3], org[3]; - d->GetOrigin(org); - d->GetSpacing(spa); - - info->Set(vtkDataObject::ORIGIN(),org,3); - info->Set(vtkDataObject::SPACING(),spa,3); - } -#endif -} - - -void iUniformGridFileLoader::SetScaledDimension(int v) -{ - if(v>=-2 && v<=2) - { - mScaledDim = v; - - if(!this->IsBoxPeriodic() && this->IsThereData()) - { - // - // Reset spacing - // - vtkStructuredPoints *data = iRequiredCast(INFO,this->GetStream(0)->ReleasedData); - - double org[3], spa[3]; - this->ComputeSpacing(org,spa); - data->SetOrigin(org); - data->SetSpacing(spa); - this->ShiftDataBody(data,mShift); - } - } -} - - -void iUniformGridFileLoader::ComputeSpacing(double org[3], double spa[3]) -{ - int i; - - if(mFileDims[0]<=0 || mFileDims[1]<=0 || mFileDims[2]<=0) return; - - // - // Now we need to decide whether the data are CellData or PointData. We use voxelLocation for that: - // if it is 0, we have point data and we place the first point into (-1,-1,-1) corner; - // if it is 1, we have cell data and we place the first point into the center of the first cell (mOriginOffset). - // - float shift; - if(mVoxelLocation == _VoxelLocationVertex) - { - shift = 0.0; - } - else - { - shift = 0.5; - } - for(i=0; i<3; i++) mOriginOffset[i] = shift*2.0/mFileDims[i]; - - // - // Find longest and short dimensions - // - int nmax, nmin; - int imax = 0, imin = 0; - nmax = nmin = mFileDims[0]; - for(i=1; i<3; i++) - { - if(nmax < mFileDims[i]) - { - nmax = mFileDims[i]; - imax = i; - } - if(mFileDims[i]>1 && nmin>mFileDims[i]) - { - nmin = mFileDims[i]; - imin = i; - } - } - - for(i=0; i<3; i++) this->SetDirectionPeriodic(i,mFileDims[i]==nmax); - - if(this->IsBoxPeriodic()) - { - i = imax; - } - else - { - switch (mScaledDim) - { - case -1: - { - i = imin; - break; - } - case 0: - case 1: - case 2: - { - if(mFileDims[mScaledDim] > 1) i = mScaledDim; else i = imin; - break; - } - case -2: - default: - { - i = imax; - break; - } - } - } - - double s = (2.0-2*mOriginOffset[i])/(mFileDims[i]-1); - - for(i=0; i<3; i++) - { - org[i] = -1.0 + shift*s; - spa[i] = s; - } -} - - -void iUniformGridFileLoader::ShiftDataBody(vtkDataSet *dataIn, double dx[3]) -{ - vtkStructuredPoints *data = vtkStructuredPoints::SafeDownCast(dataIn); - if(data==0 || !this->IsThereData(0)) return; - - int d, dn; - for(d=0; d<3; d++) - { - dn = round(dx[d]*mDataDims[d]) % mDataDims[d]; - if(this->IsDirectionPeriodic(d) && dn!=0) - { - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*mNumComponents; - float *buf = new float[mNumComponents*mDataDims[d]]; if(buf == 0) return; - if(data->GetPointData()!=0 && data->GetPointData()->GetScalars()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetScalars()->GetVoidPointer(0),buf); - } - if(data->GetPointData()!=0 && data->GetPointData()->GetVectors()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetVectors()->GetVoidPointer(0),buf); - } - if(data->GetPointData()!=0 && data->GetPointData()->GetTensors()!=0) - { - mHelper->ShiftData(mNumComponents,d,dn,mDataDims,(float *)data->GetPointData()->GetTensors()->GetVoidPointer(0),buf); - } - delete[] buf; - - double org[3]; - data->GetOrigin(org); - org[d] += 2.0*(dx[d]-float(dn)/mDataDims[d]); - data->SetOrigin(org); - } - else - { - double org[3]; - data->GetOrigin(org); - org[d] += 2.0*dx[d]; - data->SetOrigin(org); - } - } - - data->Modified(); -} - - -bool iUniformGridFileLoader::IsCompatible(iUniformGridFileLoader *other) const -{ - return (this->IsThereData() && other!=0 && other->IsThereData() && mVoxelLocation==other->mVoxelLocation && mFileDims[0]==other->mFileDims[0] && mFileDims[1]==other->mFileDims[1] && mFileDims[2]==other->mFileDims[2]); -} - - -// -// ******************************************************************** -// -// iUniformVectorsFileLoader class -// -// ******************************************************************** -// -iUniformVectorsFileLoader::iUniformVectorsFileLoader(iDataReader *r) : iUniformGridFileLoader(r,100,false) -{ -} - - -void iUniformVectorsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - nvar = 3; - ncomp = 3; -} - - -void iUniformVectorsFileLoader::AssignBinData(int, vtkIdType ntot, int com, float *d) -{ - vtkIdType l; - for(l=0; lGetStream(0)->Subject->GetLimits()->AddVar(0); - if(!this->GetStream(0)->Subject->GetFixedLimits()) - { - this->GetStream(0)->Subject->GetLimits()->SetMin(0,0.0f); - this->GetStream(0)->Subject->GetLimits()->SetMax(0,sqrt(mVarMax[0]*mVarMax[0]+mVarMax[1]*mVarMax[1]+mVarMax[2]*mVarMax[2])); - } -} - - -void iUniformVectorsFileLoader::AttachBuffer(vtkStructuredPoints *data) -{ - // - // Attach the actual data - // - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*3; - vtkFloatArray *array = vtkFloatArray::New(); IERROR_ASSERT(array); - array->SetNumberOfComponents(3); - array->SetArray(mBuffer,size,1); - array->SetName("Vectors"); - data->GetPointData()->SetVectors(array); - array->Delete(); -} - - -// -// ******************************************************************** -// -// iUniformTensorsFileLoader class -// -// ******************************************************************** -// -iUniformTensorsFileLoader::iUniformTensorsFileLoader(iDataReader *r) : iUniformGridFileLoader(r,200,false) -{ -} - - -void iUniformTensorsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - nvar = 9; - ncomp = 6; -} - - -void iUniformTensorsFileLoader::AssignBinData(int, vtkIdType ntot, int com, float *d) -{ - int noff1, noff2; - vtkIdType l; - - switch(com) - { - case 0: { noff1 = 0; noff2 = -1; break; } - case 1: { noff1 = 1; noff2 = 3; break; } - case 2: { noff1 = 2; noff2 = 6; break; } - case 3: { noff1 = 4; noff2 = -1; break; } - case 4: { noff1 = 5; noff2 = 7; break; } - case 5: { noff1 = 8; noff2 = -1; break; } - default: - { - noff1 = 0; noff2 = -1; - IERROR_LOW("Bug detected."); - } - } - - for(l=0; l 0) for(l=0; lGetStream(0)->Subject->GetLimits()->AddVar(0); - if(this->GetStream(0)->Subject->GetFixedLimits()) - { - this->GetStream(0)->Subject->GetLimits()->SetMin(0,0.0f); - this->GetStream(0)->Subject->GetLimits()->SetMax(0,sqrt(mVarMax[0]*mVarMax[0]+mVarMax[1]*mVarMax[1]+mVarMax[2]*mVarMax[2]+mVarMax[3]*mVarMax[3]+mVarMax[4]*mVarMax[4]+mVarMax[5]*mVarMax[5]+mVarMax[6]*mVarMax[6]+mVarMax[7]*mVarMax[7]+mVarMax[8]*mVarMax[8])); - } -} - - -void iUniformTensorsFileLoader::AttachBuffer(vtkStructuredPoints *data) -{ - // - // Attach the actual data - // - vtkIdType size = (vtkIdType)mDataDims[0]*mDataDims[1]*mDataDims[2]*9; - vtkFloatArray *array = vtkFloatArray::New(); IERROR_ASSERT(array); - array->SetNumberOfComponents(9); - array->SetArray(mBuffer,size,1); - array->SetName("Tensors"); - data->GetPointData()->SetTensors(array); - array->Delete(); -} - - -// -// ******************************************************************** -// -// iUniformScalarsFileLoader class -// -// ******************************************************************** -// -iUniformScalarsFileLoader::iUniformScalarsFileLoader(iDataReader *r, iUniformVectorsFileLoader *vs) : iUniformGridFileLoader(r,0,true) -{ - mVectorFieldLoader = vs; - - mCalculatorOutput = 0; -// mCalculatorExpression = ""; - - mHelper2 = new iUniformScalarsHelper(this); IERROR_ASSERT(mHelper2); -} - - -iUniformScalarsFileLoader::~iUniformScalarsFileLoader() -{ - delete mHelper2; -} - - -void iUniformScalarsFileLoader::SetIndicies(int &nvar, int &ncomp) -{ - // - // Try to set all the records from the file. DataLimits will either expand to accommodate - // all of them or limit the allowed number to the number of listed records. - // - this->GetStream(0)->Subject->GetLimits()->BlockNotifications(true); - this->GetStream(0)->Subject->GetLimits()->AssignVars(nvar); - this->GetStream(0)->Subject->GetLimits()->BlockNotifications(false); - ncomp = nvar = this->GetStream(0)->Subject->GetLimits()->GetNumVars(); -} - - -void iUniformScalarsFileLoader::AssignBinData(int nvar, vtkIdType ntot, int com, float *d) -{ - vtkIdType l; - for(l=0; lSetNumberOfComponents(mNumVars); - array->SetArray(mBuffer,size,1); - array->SetName("Scalars"); - data->GetPointData()->SetScalars(array); - array->Delete(); - - data->SetScalarTypeToFloat(); - data->SetNumberOfScalarComponents(mNumVars); -} - - -void iUniformScalarsFileLoader::SetArraysAndComponents() -{ - mNumComponents = mNumVars; - this->GetStream(0)->Subject->GetLimits()->AssignVars(mNumVars); - // - // Limits are set after the data are operated upon - // -} - - -void iUniformScalarsFileLoader::SetCalculatorOutput(int n) -{ - if(n>=0 && nGetStream(0)->Subject->GetLimits()->GetNumVars()) - { - mCalculatorOutput = n; - } -} - - -void iUniformScalarsFileLoader::SetCalculatorExpression(const iString &s) -{ - mCalculatorExpression = s; -} - - -void iUniformScalarsFileLoader::OperateOnData() -{ - int n; - float fMin = iMath::_LargeFloat, fMax = -iMath::_LargeFloat, f = 0.0; - - iDataLimits *slim = this->GetStream(0)->Subject->GetLimits(); - iDataLimits *vlim = mVectorFieldLoader->GetSubject(0)->GetLimits(); - slim->BlockNotifications(true); - int nvar = slim->GetNumVars(); - - // - // Do the array function first - // - if(mCalculatorOutput>=0 && mCalculatorOutputGetObserver()->Started(iProgressEventObserver::_Operating); - this->GetObserver()->SetProgress(0.0); - - bool doVector = false; - if(this->IsCompatible(mVectorFieldLoader)) doVector = true; - - mHelper2->OperateOnData1(nvar,mFileDims,mCalculatorExpression,doVector,0.0,1.0); - } - - this->GetObserver()->Started(iProgressEventObserver::_Formatting); - this->GetObserver()->SetProgress(0.0); - - // - // Format everything in parallel - // - mVarMin.Extend(nvar); - mVarMax.Extend(nvar); - mHelper2->OperateOnData2(nvar,mFileDims,mVarMin,mVarMax,mOverflow,0.0,1.0); - -#ifdef I_CHECK2 - // - // Format everything serially - // - vtkIdType lMin, lMax, size = (vtkIdType)mFileDims[0]*mFileDims[1]*mFileDims[2]; - for(n=0; n fMax) - { - lMax = l; - fMax = f; - } - if(f < fMin) - { - lMin = l; - fMin = f; - } - } - if(fabs(mVarMin[n]-fMin)>iMath::_FloatRes || fabs(mVarMax[n]-fMax)>iMath::_FloatRes) - { - IERROR_REPORT_BUG; - } - } -#endif - - this->GetObserver()->SetProgress(1.0); - this->GetObserver()->Finished(); - - // - // Correct limits in log stretching - // - if(!this->GetStream(0)->Subject->GetFixedLimits()) - { - for(n=0; nGetStretch(n) == 1) - { - fMin = 0.1*floor(10.0*fMin); - fMax = 0.1*floor(1+10.0*fMax); - } - slim->SetMin(n,fMin); - slim->SetMax(n,fMax); - } - } - - slim->BlockNotifications(false); -} - - -// -// Helper class -// -iUniformGridHelper::iUniformGridHelper(iUniformGridFileLoader *loader) : iParallelWorker(loader->GetViewModule()->GetParallelManager()) -{ - mLoader = loader; -} - - -void iUniformGridHelper::ShiftData(int numCom, int dim, int dn, int dataDims[3], float *data, float *buf) -{ - mNumCom = numCom; - mDims = dataDims; - mItmp2 = dn; - mItmp1 = dim; - mArr1 = data; - mArr2 = buf; - - this->ParallelExecute(1); -} - - -void iUniformGridHelper::ExpandUp(float *array, int nc, int oldDims[3], int newDims[3]) -{ - // - // Can we do this in parallel? - // - int i, j, k; - float *ptr; - - if(array==0 || nc<1 || oldDims[0]<1 || oldDims[1]<1 || oldDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::ExpandUp."); - return; - } - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]+1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for expanding data."); - return; - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Started(iProgressEventObserver::_Formatting); - } - - vtkIdType oldN12 = nc*oldDims[0]*oldDims[1]; - vtkIdType newN12 = nc*newDims[0]*newDims[1]; - vtkIdType size12 = oldN12*sizeof(float); - - if(newN12 > oldN12) - { - // - // Move plains - // - for(k=oldDims[2]-1; k>=1; k--) - { - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5*float(oldDims[2]-1-k)/oldDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - memmove(array+k*newN12,array+k*oldN12,size12); // will memcpy work? - } - } - - vtkIdType oldN1 = nc*oldDims[0]; - vtkIdType newN1 = nc*newDims[0]; - vtkIdType size1 = oldN1*sizeof(float); - - if(newN1 > oldN1) - { - // - // Move rows - // - for(k=0; kGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5+0.5*float(k)/oldDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - ptr = array + k*newN12; - for(j=oldDims[1]-1; j>=1; j--) - { - memmove(ptr+j*newN1,ptr+j*oldN1,size1); - } - } - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Finished(); - } -} - - -void iUniformGridHelper::CollapseDown(float *array, int nc, int oldDims[3], int newDims[3]) -{ - // - // Can we do this in parallel? - // - int i, j, k; - float *ptr; - - if(array==0 || nc<1 || newDims[0]<1 || newDims[1]<1 || newDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::CompressDown."); - return; - } - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]-1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for collapsing data."); - return; - } - - vtkIdType oldN12 = nc*oldDims[0]*oldDims[1]; - vtkIdType oldN1 = nc*oldDims[0]; - vtkIdType newN1 = nc*newDims[0]; - vtkIdType size1 = newN1*sizeof(float); - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Started(iProgressEventObserver::_Formatting); - } - - if(newN1 < oldN1) - { - // - // Move rows - // - for(k=0; kGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5*float(k)/newDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - - ptr = array + k*oldN12; - for(j=1; jGetObserver() != 0) - { - mLoader->GetObserver()->SetProgress(0.5+0.5*float(k)/newDims[2]); - if(mLoader->GetObserver()->IsAborted()) return; - } - memmove(array+k*newN12,array+k*oldN12,size12); // will memcpy work? - } - } - - if(mLoader->GetObserver() != 0) - { - mLoader->GetObserver()->Finished(); - } -} - - -void iUniformGridHelper::PadPeriodically(float *array, int nc, int oldDims[3], int newDims[3]) -{ - int i, j, k; - float *ptr; - vtkIdType size, offset; - - if(array==0 || nc<1 || oldDims[0]<1 || oldDims[1]<1 || oldDims[2]<1) - { - IERROR_FATAL("Invalid use of iUniformGridHelper::PadPeriodically."); - return; - } - - for(i=0; i<3; i++) if(oldDims[i]!=newDims[i] && oldDims[i]+1!=newDims[i]) - { - IERROR_FATAL("Incorrect dimensions for padding data."); - return; - } - - // - // Do x-direction - // - if(newDims[0] > oldDims[0]) - { - size = nc*sizeof(float); - offset = oldDims[0]*nc; - for(k=0; k oldDims[1]) - { - size = newDims[0]*nc*sizeof(float); - offset = oldDims[1]*newDims[0]*nc; - for(k=0; k oldDims[2]) - { - size = newDims[1]*newDims[0]*nc*sizeof(float); - offset = oldDims[2]*newDims[1]*newDims[0]*nc; - - memcpy(array+offset,array,size); - } - -#ifdef I_CHECK2 - bool ok = true; - int l, ijk1[3], ijk2[3]; - for(k=0; ok && k<3; k++) if(newDims[k] > oldDims[k]) - { - i = (k+1) % 3; - j = (k+2) % 3; - ijk1[k] = 0; - ijk2[k] = oldDims[k]; - - for(ijk1[j]=ijk2[j]=0; ok && ijk1[j]ExecuteShiftData(p); - return 0; - } - default: - { -#ifdef I_CHECK1 - IERROR_REPORT_BUG; -#endif - return 2; - } - } -} - - -// -// Shift an nc-component vertical array (treat the mesh array as nvar 1-component vertical arrays) -// -void iUniformGridHelper::ExecuteShiftData(iParallel::ProcessorInfo &p) -{ - int n, l1, l2, l, lold, add1; - int d1 = 0, d2 = 0; - - int d = mItmp1; - int dn = mItmp2; - - switch(d) - { - case 0: { d1 = 1; d2 = 2; break; } - case 1: { d1 = 0; d2 = 2; break; } - case 2: { d1 = 0; d2 = 1; break; } - } - - int ddim = mDims[d]; - vtkIdType off0 = 0, off1 = 0, add2; - - int kbeg, kend, kstp; - iParallel::SplitRange(p,mDims[d1],kbeg,kend,kstp); - - for(l1=kbeg; l1GetObserver() != 0) - { - if(this->IsMaster(p)) mLoader->GetObserver()->SetProgress((d+(float)(l1-kbeg)/(kend-kbeg))/3.0); - if(mLoader->GetObserver()->IsAborted()) return; - } - for(l2=0; l2= ddim) lold -= ddim; - - add1 = mNumCom*l; - add2 = off0 + off1*lold; - - for(n=0; nGetViewModule()->GetParallelManager()) -{ - mLoader = subject; - mObserver = subject->GetObserver(); -} - - -void iUniformScalarsHelper::OperateOnData1(int nvar, int dims[3], const iString &calculatorExpression, bool doVector, float ps, float dp) -{ - mNumVars = nvar; - mDims = dims; - mCalculatorExpression = calculatorExpression; - mDoVector = doVector; - - mProgStart = ps; - mProgStep = dp; - - iCalculator calc; - iCalculator::real_var var("Var",mNumVars,&calc); - iCalculator::real_var vec("Vec",3); - if(mDoVector) calc.AddVariable(&vec); - - if(!calc.Compile(mCalculatorExpression) || !calc.Link()) - { - IERROR_LOW(calc.GetErrorMessage()); - } - else - { - this->ParallelExecute(1); - } -} - - -void iUniformScalarsHelper::OperateOnData2(int nvar, int dims[3], float *fMin, float *fMax, bool &overflow, float ps, float dp) -{ - int i, n; - - mNumVars = nvar; - mDims = dims; - mNumProcs = this->GetManager()->GetNumberOfProcessors(); - mMin.Extend(mNumVars*mNumProcs); - mMax.Extend(mNumVars*mNumProcs); - - mProgStart = ps; - mProgStep = dp; - mOverflow = false; - - this->ParallelExecute(2); - - for(n=0; n mMin[n+nvar*i]) fMin[n] = mMin[n+nvar*i]; - if(fMax[n] < mMax[n+nvar*i]) fMax[n] = mMax[n+nvar*i]; - } - } - - overflow = mOverflow; -} - - -int iUniformScalarsHelper::ExecuteStep(int step, iParallel::ProcessorInfo &p) -{ - switch(step) - { - case 1: - { - this->ExecuteOperateOnData1(p); - return 0; - } - case 2: - { - if(mNumProcs != p.NumProcs) return 3; - this->ExecuteOperateOnData2(p); - return 0; - } - default: - { -#ifdef I_CHECK1 - IERROR_REPORT_BUG; -#endif - return 2; - } - } -} - - -// -// Operate on mesh data -// -void iUniformScalarsHelper::ExecuteOperateOnData1(iParallel::ProcessorInfo &p) -{ - float *arr1 = mLoader->GetDataPointer(); - float *arr2 = mLoader->mVectorFieldLoader->GetDataPointer(); - - if(arr1==0 || (mDoVector && arr2==0)) return; - - vtkIdType size = (vtkIdType)mDims[0]*mDims[1]*mDims[2]; - int nout = mLoader->GetCalculatorOutput(); - vtkIdType l, kbeg, kend, kstp; - iParallel::SplitRange(p,size,kbeg,kend,kstp); - - float progScale = mProgStep/kstp; - - // - // Create our calculator - // - iCalculator calc; - - iCalculator::real_ptr var(arr1+kbeg*mNumVars,"Var",mNumVars,&calc); - iCalculator::real_ptr vec(arr2==0?arr1:arr2+kbeg*3,"Vec",3); - if(mDoVector) - { - calc.AddVariable(&vec); - } - - if(!calc.Compile(mCalculatorExpression) || !calc.Link()) return; - - const float *output = calc.GetResultData(); - - for(l=kbeg; lIsMaster(p)) mObserver->SetProgress(mProgStart+progScale*(l-kbeg)); - if(mObserver->IsAborted()) return; - } - if(!calc.Execute()) break; - arr1[nout+mNumVars*l] = *output; - ++var; - ++vec; - } -} - - -void iUniformScalarsHelper::ExecuteOperateOnData2(iParallel::ProcessorInfo &p) -{ - float fMin, fMax; - vtkIdType size = (vtkIdType)mDims[0]*mDims[1]*mDims[2]; - vtkIdType kbeg, kend, kstp; - iParallel::SplitRange(p,size,kbeg,kend,kstp); - - // - // Format everything - // - iDataLimits *lim = mLoader->GetSubject(0)->GetLimits(); - - vtkIdType l, larr; - int n; - - float *arr1 = mLoader->GetDataPointer(); - if(arr1 == 0) return; - - float progScale = mProgStep/(mNumVars*kstp); - - for(n=0; nIsMaster(p)) mObserver->SetProgress(mProgStart+progScale*(larr-kbeg+n*kstp)); - if(mObserver->IsAborted()) return; - } - l = n + mNumVars*larr; - if(arr1[l] < -iMath::_LargeFloat) - { - mOverflow = true; - arr1[l] = -iMath::_LargeFloat; - } - if(arr1[l] > iMath::_LargeFloat) - { - mOverflow = true; - arr1[l] = iMath::_LargeFloat; - } - if(arr1[l] > fMax) fMax = arr1[l]; - if(arr1[l] < fMin) fMin = arr1[l]; - } - - if(mNumProcs == p.NumProcs) - { - mMin[n+mNumVars*p.ThisProc] = fMin; - mMax[n+mNumVars*p.ThisProc] = fMax; - } - } -} - diff -Nru ifrit-3.3.4/core/iabstractextension.cpp ifrit-3.4.2/core/iabstractextension.cpp --- ifrit-3.3.4/core/iabstractextension.cpp 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/iabstractextension.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iabstractextension.h ifrit-3.4.2/core/iabstractextension.h --- ifrit-3.3.4/core/iabstractextension.h 2011-01-27 17:51:03.000000000 +0000 +++ ifrit-3.4.2/core/iabstractextension.h 2013-07-11 01:23:16.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iactor.cpp ifrit-3.4.2/core/iactor.cpp --- ifrit-3.3.4/core/iactor.cpp 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/iactor.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iactor.h ifrit-3.4.2/core/iactor.h --- ifrit-3.3.4/core/iactor.h 2011-01-27 17:51:03.000000000 +0000 +++ ifrit-3.4.2/core/iactor.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iactorcollection.cpp ifrit-3.4.2/core/iactorcollection.cpp --- ifrit-3.3.4/core/iactorcollection.cpp 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/iactorcollection.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iactorcollection.h ifrit-3.4.2/core/iactorcollection.h --- ifrit-3.3.4/core/iactorcollection.h 2011-01-27 17:51:04.000000000 +0000 +++ ifrit-3.4.2/core/iactorcollection.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ianimator.cpp ifrit-3.4.2/core/ianimator.cpp --- ifrit-3.3.4/core/ianimator.cpp 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/ianimator.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -48,7 +48,6 @@ #include "iviewmodule.h" #include "iviewobject.h" #include "iviewobjectfamily.h" -#include "iwriter.h" #include #include @@ -58,9 +57,6 @@ #include #include -#include -#include -#include using namespace iParameter; @@ -82,40 +78,24 @@ IOBJECT_DEFINE_TYPE(iAnimator,Animator,a,iObjectType::_Helper); -IOBJECT_DEFINE_KEY(iAnimator,CameraPathClosed,cpc,Bool,1); -IOBJECT_DEFINE_KEY(iAnimator,CameraPathDemo,cpd,Bool,1); -IOBJECT_DEFINE_KEY(iAnimator,CameraPathX,cpx,Float,0); -IOBJECT_DEFINE_KEY(iAnimator,CameraPathY,cpy,Float,0); -IOBJECT_DEFINE_KEY(iAnimator,CameraPathZ,cpz,Float,0); IOBJECT_DEFINE_KEY(iAnimator,Phi,dp,Float,1); IOBJECT_DEFINE_KEY(iAnimator,Roll,dr,Float,1); IOBJECT_DEFINE_KEY(iAnimator,Theta,dt,Float,1); IOBJECT_DEFINE_KEY(iAnimator,Zoom,dz,Float,1); -IOBJECT_DEFINE_KEY(iAnimator,FocalPathEnabled,fpe,Bool,1); -IOBJECT_DEFINE_KEY(iAnimator,FocalPathToPoint,fpp,Bool,1); -IOBJECT_DEFINE_KEY(iAnimator,FocalPathX,fpx,Float,0); -IOBJECT_DEFINE_KEY(iAnimator,FocalPathY,fpy,Float,0); -IOBJECT_DEFINE_KEY(iAnimator,FocalPathZ,fpz,Float,0); IOBJECT_DEFINE_KEY(iAnimator,FlybySpeed,fs,Float,1); -IOBJECT_DEFINE_KEY(iAnimator,InheritSettings,is,Bool,1); IOBJECT_DEFINE_KEY(iAnimator,LoadScriptFile,ls,String,1); IOBJECT_DEFINE_KEY(iAnimator,LogoFile,lf,String,1); +IOBJECT_DEFINE_KEY(iAnimator,LogoLocation,ll,Int,1); IOBJECT_DEFINE_KEY(iAnimator,LogoOpacity,lo,Float,1); -IOBJECT_DEFINE_KEY(iAnimator,LogoPosition,lp,Int,1); IOBJECT_DEFINE_KEY(iAnimator,NumberOfBlendedFrames,nb,Int,1); IOBJECT_DEFINE_KEY(iAnimator,NumberOfFrames,nf,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,NumberOfCameraPathHandles,nph,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,NumberOfCameraPathSteps,nps,Int,1); IOBJECT_DEFINE_KEY(iAnimator,NumberOfTransitionFrames,nt,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,PositionOnPath,pop,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,RestoreCamera,rc,Bool,1); IOBJECT_DEFINE_KEY(iAnimator,Style,s,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,ScriptFileName,sfn,String,1); -IOBJECT_DEFINE_KEY(iAnimator,StopOnPath,sop,Bool,1); +IOBJECT_DEFINE_KEY(iAnimator,ScriptFile,sf,String,1); IOBJECT_DEFINE_KEY(iAnimator,NumberOfTitlePageBlendedFrames,tbf,Int,1); IOBJECT_DEFINE_KEY(iAnimator,TitlePageFile,tf,String,1); IOBJECT_DEFINE_KEY(iAnimator,NumberOfTitlePageFrames,tnf,Int,1); -IOBJECT_DEFINE_KEY(iAnimator,UseScript,us,Bool,1); + IOBJECT_DEFINE_KEY(iAnimator,CrossSectionSpeed,xs,Float,1); IOBJECT_DEFINE_KEY(iAnimator,DebugFlag,-df,Int,1); @@ -141,12 +121,10 @@ iAnimator::iAnimator(iViewModule *vm) : iObject("Animator"), mViewModule(vm) { - mStarted = mStartedRender = mUseScript = mIsPlayingDemo = false; - mInheritSettings = true; - mRestoreCamera = true; + mStarted = mStartedRender = mUsingScript = false; mDebugFlag = 0; -// scriptFileName = ""; (this is automatic with iString) +// scriptFile = ""; (this is automatic with iString) mNewRec = false; mCurRec = mPrevRec = -1; @@ -162,28 +140,18 @@ mState.slideSpeed = 0.0; mState.nBlendedFrames = 0; mState.nTransitionFrames = 0; -// mState.titlePageFile = ""; - mState.titlePageNumFrames = 0; - mState.titlePageNumBlendedFrames = 0; -// mState.logoFile = ""; - mState.logoOpacity = 0.5; - mState.logoPosition = 0; - mState.stopOnPath = false; - mState.posOnPath = 0; - mNumPathSteps = 200; + mTitlePageNumFrames = 0; + mTitlePageNumBlendedFrames = 0; + mLogoOpacity = 0.5; + mLogoLocation = 0; mRandStep = 0.03; mSeed = 12345; - vtkMath::RandomSeed(mSeed); - - mDoingTitlePage = false; mAnimatorScript = iAnimatorScript::New(this); IERROR_ASSERT(mAnimatorScript); mAnimatorObserver = iAnimatorEventObserver::New(this->GetViewModule()); IERROR_ASSERT(mAnimatorObserver); - mCameraPath = iCameraPath::New(this->GetViewModule()); IERROR_ASSERT(mCameraPath); - mLeader = 0; } @@ -196,7 +164,6 @@ mAnimatorObserver->Delete(); mAnimatorScript->Delete(); while(mBlenderBase.Size() > 0) delete mBlenderBase.RemoveLast(); - mCameraPath->Delete(); } @@ -216,8 +183,6 @@ // void iAnimator::Start() { - static iString nullScript = "render -1"; - this->GetErrorStatus()->Clear(); if(mStarted) @@ -233,15 +198,27 @@ // Are we using a script? // this->SaveState(); - if(mUseScript && !mInheritSettings) this->ResetState(); - - if(!mUseScript) + if(mUsingScript) + { + mState.mode = 0; + mState.nframes = 1; + mState.dphi = 0.0; + mState.dtheta = 0.0; + mState.dscale = 1.0; + mState.droll = 0.0; + mState.flybySpeed = 0.01; + mState.slideSpeed = 0.0; + mState.nBlendedFrames = 0; + mState.nTransitionFrames = 0; + + this->ClearCache(); + } + else { - mScriptText = mAnimatorScript->GetText(); - mAnimatorScript->SetText(nullScript); + mAnimatorScript->SetText("render -1"); } - this->GetViewModule()->GetWriter()->Start(); + this->GetViewModule()->StartAnimation(); mAnimatorScript->StartExecute(); mStarted = true; @@ -283,23 +260,24 @@ return; } - this->GetViewModule()->GetWriter()->Finish(); + this->GetViewModule()->FinishAnimation(); mAnimatorScript->StopExecute(); - if(!mUseScript) - { - mAnimatorScript->SetText(mScriptText); - } // - // Restore the original view + // Reset to initial state // - this->Reset(); + mStartedRender = false; + this->GetViewModule()->JustifyLabelLeft(false); + // // Restore the original state after execution of a script - must do it after reset() // so that projection is Set properly in case it was changed in a script before the // first render // - this->RestoreState(); + this->RestoreState(true); + + if(!mUsingScript) mAnimatorScript->SetText(""); + // // Activate Progress Dialog // @@ -350,16 +328,6 @@ // // Internal functions // -void iAnimator::Reset() -{ - mStartedRender = false; - mDoingTitlePage = false; - vtkMath::RandomSeed(mSeed); - this->GetViewModule()->JustifyLabelLeft(false); - this->ClearCache(); -} - - void iAnimator::SetDebugFlag(int s) { mDebugFlag = s; @@ -385,6 +353,8 @@ mState.ifColorBars = this->GetViewModule()->IsColorBarsVisible(); mState.ifTimeLabel = this->GetViewModule()->IsLabelVisible(); + if(DATAREADER != 0) mState.currec = this->GetViewModule()->GetReader()->GetRecordNumber(); + mState.cameraProjection = CAM->GetParallelProjection(); CAM->GetPosition(mState.cameraPosition); CAM->GetFocalPoint(mState.cameraFocalPoint); @@ -392,13 +362,13 @@ mState.cameraParallelScale = CAM->GetParallelScale(); CAM->GetClippingRange(mState.cameraClippingRange); - if(DATAREADER != 0) mState.currec = this->GetViewModule()->GetReader()->GetRecordNumber(); mState2 = mState; + this->ClearCache(); } -void iAnimator::RestoreState() +void iAnimator::RestoreState(bool with_camera) { mState = mState2; @@ -412,7 +382,7 @@ this->GetViewModule()->ShowColorBars(mState.ifColorBars); this->GetViewModule()->ShowLabel(mState.ifTimeLabel); - if(mRestoreCamera) + if(with_camera) { CAM->SetParallelProjection(mState.cameraProjection); CAM->SetPosition(mState.cameraPosition); @@ -420,30 +390,6 @@ CAM->SetViewUp(mState.cameraViewUp); CAM->SetParallelScale(mState.cameraParallelScale); } - this->ClearCache(); -} - - -void iAnimator::ResetState() -{ - mState.mode = 0; - mState.nframes = 1; - mState.dphi = 0.0; - mState.dtheta = 0.0; - mState.dscale = 1.0; - mState.droll = 0.0; - mState.flybySpeed = 0.01; - mState.slideSpeed = 0.0; - mState.nBlendedFrames = 0; - mState.nTransitionFrames = 0; - mState.titlePageFile.Clear(); - mState.titlePageNumFrames = 0; - mState.titlePageNumBlendedFrames = 0; - mState.logoFile.Clear(); - mState.logoOpacity = 0.5; - mState.logoPosition = 0; - mState.stopOnPath = false; - mState.posOnPath = 0; this->ClearCache(); } @@ -451,11 +397,12 @@ void iAnimator::CopyState(iAnimator *anim) { + // + // Copy state but not camera + // anim->SaveState(); mState2 = anim->mState; - mRestoreCamera = false; // we do not want to reset cameras of other vm - this->RestoreState(); - mRestoreCamera = anim->mRestoreCamera; + this->RestoreState(false); this->ClearCache(); } @@ -463,23 +410,130 @@ void iAnimator::SetStyle(int ma) { - if(ma>=0 && ma<=4) + if(ma>=0 && ma<=3) { mState.mode = ma; - mCameraPath->SetEnabled(ma == 4); - this->Reset(); this->ClearCache(); } } +void iAnimator::SetNumberOfFrames(int na) +{ + if(na > 0) + { + mState.nframes = na; + this->ClearCache(); + } +} + + +void iAnimator::SetPhi(float va) +{ + mState.dphi = va; + this->ClearCache(); +} + + +void iAnimator::SetTheta(float va) +{ + mState.dtheta = va; + this->ClearCache(); +} + + +void iAnimator::SetZoom(float va) +{ + mState.dscale = va; + this->ClearCache(); +} + + +void iAnimator::SetRoll(float va) +{ + mState.droll = va; + this->ClearCache(); +} + + +void iAnimator::SetCrossSectionSpeed(float va) +{ + mState.slideSpeed = va; + this->ClearCache(); +} + + +void iAnimator::SetFlybySpeed(float va) +{ + mState.flybySpeed = va; + this->ClearCache(); +} + + +void iAnimator::SetNumberOfBlendedFrames(int na) +{ + if(na >= 0) + { + mState.nBlendedFrames = na; + this->ClearCache(); + } +} + + +void iAnimator::SetNumberOfTransitionFrames(int na) +{ + if(na >= 0) + { + mState.nTransitionFrames = na; + this->ClearCache(); + } +} + + +void iAnimator::SetNumberOfTitlePageFrames(int n) +{ + if(n >= 0) + { + mTitlePageNumFrames = n; + this->ClearCache(); + } +} + + +void iAnimator::SetNumberOfTitlePageBlendedFrames(int n) +{ + if(n >= 0) + { + mTitlePageNumBlendedFrames = n; + this->ClearCache(); + } +} + + +void iAnimator::SetLogoLocation(int n) +{ + if(n>0 && n<5) + { + mLogoLocation = n; + this->ClearCache(); + } +} + + +void iAnimator::SetLogoOpacity(float v) +{ + mLogoOpacity = v; + this->ClearCache(); +} + + bool iAnimator::SetLogoFile(const iString &s) { this->ClearCache(); bool ok = mLogoImage.LoadFromFile(s); - if(ok) mState.logoFile = s; else + if(ok) mLogoFile = s; else { - mState.logoFile.Clear(); + mLogoFile.Clear(); mLogoImage.Clear(); } return ok; @@ -490,46 +544,53 @@ { this->ClearCache(); bool ok = mTitlePageImage.LoadFromFile(s); - if(ok) mState.titlePageFile = s; else + if(ok) mTitlePageFile = s; else { - mState.titlePageFile.Clear(); + mTitlePageFile.Clear(); mTitlePageImage.Clear(); } return ok; } -bool iAnimator::LoadScriptFile(const iString &name) +bool iAnimator::SetScriptFile(const iString &name) { - iString fname(name); - iDirectory::ExpandFileName(fname,this->GetViewModule()->GetControlModule()->GetShell()->GetEnvironment(Environment::Script)); + iString fname(name), text; - iFile f(fname); - if(!f.Open(iFile::_Read,iFile::_Text)) + mUsingScript = false; + if(!name.IsEmpty()) { - this->GetErrorStatus()->Set("Animation script file is not found."); - return false; - } + iDirectory::ExpandFileName(fname,this->GetViewModule()->GetControlModule()->GetShell()->GetEnvironment(Environment::Script)); - iString st, tmp; - while(f.ReadLine(tmp)) st += tmp + "\n"; - if(st.IsEmpty()) - { - this->GetErrorStatus()->Set("Animation script file is empty or unreadable."); - return false; - } + iFile f(fname); + if(!f.Open(iFile::_Read,iFile::_Text)) + { + this->GetErrorStatus()->Set("Animation script file is not found."); + return false; + } - f.Close(); + iString st, tmp; + while(f.ReadLine(tmp)) text += tmp + "\n"; + if(text.IsEmpty()) + { + this->GetErrorStatus()->Set("Animation script file is empty or unreadable."); + f.Close(); + return false; + } + + f.Close(); + mUsingScript = true; + } - mAnimatorScript->SetText(st); - mUseScript = true; - this->SetScriptFileName(fname); + mAnimatorScript->SetText(text); + mScriptFile = fname; + this->ClearCache(); return true; } -bool iAnimator::RenderImages(bool dumpImage) +bool iAnimator::Frame(bool dumpImage) { static float Pi = 3.1415927; double xc[3], x0[3]; @@ -549,6 +610,8 @@ } this->GetViewModule()->JustifyLabelLeft(true); + vtkMath::RandomSeed(mSeed); + if(mState.mode == 2) { wData.dphl0 = mState.dphi; @@ -585,21 +648,8 @@ wData.dt = wData.dt0; } - if(mState.mode == 4) - { - mCameraPath->SetEnabled(false); - } - - if(mState.titlePageFile.IsEmpty() || mDebugFlag!=0) - { - mCurFrame = mTotFrame = 0; - mDoingTitlePage = false; - } - else - { - mCurFrame = mTotFrame = -mState.titlePageNumFrames; - mDoingTitlePage = true; - } + mCurFrame = mTotFrame = 0; + mPrevRec = -1; mCurRec = DATAREADER->GetRecordNumber(); mStartedRender = true; @@ -619,7 +669,7 @@ if(this->GetErrorStatus()->Level()==10) { this->GetErrorStatus()->Clear(); - if(mUseScript) + if(mUsingScript) { this->GetErrorStatus()->Set("Not enough data files to complete the script.",-1); } @@ -635,258 +685,128 @@ if(this->GetErrorStatus()->IsError()) { - if(mState.mode == 4) - { - mCameraPath->SetEnabled(true); - } return false; } mCurFrame++; mTotFrame++; - if(mTotFrame > 0) + if(fabs(mState.slideSpeed)>1.0e-30 && XSECTION!=0) { - if(fabs(mState.slideSpeed)>1.0e-30 && XSECTION!=0) + double p = XSECTION->GetLocation(); + p = p + mState.slideSpeed; + XSECTION->SetLocation(p); + if(XSECTION->GetOverTheEdgeFlag()) mState.slideSpeed = -mState.slideSpeed; + } + // + // Add transformations for rotate & tumble + // + if(mState.mode==1 || mState.mode==2) + { + CAM->Azimuth(-mState.dphi); + CAM->Elevation(-mState.dtheta); + CAM->Zoom(mState.dscale); + CAM->Roll(mState.droll); + CAM->OrthogonalizeViewUp(); + + if(mState.mode == 2) { - double p = XSECTION->GetLocation(); - p = p + mState.slideSpeed; - XSECTION->SetLocation(p); - if(XSECTION->GetOverTheEdgeFlag()) mState.slideSpeed = -mState.slideSpeed; - } - // - // Add transformations for rotate & tumble - // - if(mState.mode==1 || mState.mode==2) - { - CAM->Azimuth(-mState.dphi); - CAM->Elevation(-mState.dtheta); - CAM->Zoom(mState.dscale); - CAM->Roll(mState.droll); - CAM->OrthogonalizeViewUp(); - - if(mState.mode == 2) + wData.r = wData.r + mRandStep; + float cr = cos(wData.r*wData.ramp); + float sr = sin(wData.r*wData.ramp); + mState.dphi = wData.dphl0*cr + wData.dthl0*sr; + mState.dtheta = wData.dthl0*cr - wData.dphl0*sr; + if(wData.r > 1.0) { - wData.r = wData.r + mRandStep; - float cr = cos(wData.r*wData.ramp); - float sr = sin(wData.r*wData.ramp); - mState.dphi = wData.dphl0*cr + wData.dthl0*sr; - mState.dtheta = wData.dthl0*cr - wData.dphl0*sr; - if(wData.r > 1.0) - { - wData.r = 0.0; - wData.ramp = RAN_N; - wData.dphl0 = mState.dphi; - wData.dthl0 = mState.dtheta; - } + wData.r = 0.0; + wData.ramp = RAN_N; + wData.dphl0 = mState.dphi; + wData.dthl0 = mState.dtheta; } } - // - // Add transformations for flyby - // - if(mState.mode == 3) + } + // + // Add transformations for flyby + // + if(mState.mode == 3) + { + for(i=0; i<3; i++) { - for(i=0; i<3; i++) - { - xc[i] = wData.xc1[i] + (wData.xc2[i]-wData.xc1[i])*wData.t; - x0[i] = wData.x[i]; - v0[i] = wData.v[i]; - } - - CAM->SetFocalPoint(xc); - - wData.dt *= 2; - float d0, d1, cot, sot; - do - { - wData.dt *= 0.5; + xc[i] = wData.xc1[i] + (wData.xc2[i]-wData.xc1[i])*wData.t; + x0[i] = wData.x[i]; + v0[i] = wData.v[i]; + } - for(i=0; i<3; i++) - { - r0[i] = x0[i] - xc[i]; - vA[i] = r0[i]; - vB[i] = v0[i]; - } + CAM->SetFocalPoint(xc); - cot = cos(wData.dt); - sot = sin(wData.dt); - for(i=0; i<3; i++) r1[i] = vA[i]*cot + vB[i]*sot - r0[i]; + wData.dt *= 2; + float d0, d1, cot, sot; + do + { + wData.dt *= 0.5; - d0 = d1 = 0.0; - for(i=0; i<3; i++) - { - d0 = d0 + r0[i]*r0[i]; - d1 = d1 + r1[i]*r1[i]; - } - d1 = sqrt(d1/d0); - } - while(d1>mState.flybySpeed && wData.dt>0.001*wData.dt0); - - if(d1 < 0.2*mState.flybySpeed) wData.dt = 1.5*wData.dt; - for(i=0; i<3; i++) { - wData.v[i] = vB[i]*cot-vA[i]*sot; - wData.x[i] = r0[i] + r1[i] + xc[i]; + r0[i] = x0[i] - xc[i]; + vA[i] = r0[i]; + vB[i] = v0[i]; } - - CAM->SetPosition(wData.x); - CAM->OrthogonalizeViewUp(); - wData.t = wData.t + wData.dt; - - if(wData.t > 1.0) + + cot = cos(wData.dt); + sot = sin(wData.dt); + for(i=0; i<3; i++) r1[i] = vA[i]*cot + vB[i]*sot - r0[i]; + + d0 = d1 = 0.0; + for(i=0; i<3; i++) { - wData.t = 0.0; - for(i=0; i<3; i++) - { - wData.xc1[i] = wData.xc2[i]; - wData.xc2[i] = 0.5*RAN_U; - } + d0 = d0 + r0[i]*r0[i]; + d1 = d1 + r1[i]*r1[i]; } + d1 = sqrt(d1/d0); } + while(d1>mState.flybySpeed && wData.dt>0.001*wData.dt0); - // - // Camera path - // - if(mState.mode == 4) + if(d1 < 0.2*mState.flybySpeed) wData.dt = 1.5*wData.dt; + + for(i=0; i<3; i++) { - // - // Are we done? - // - if(mState.posOnPath == mNumPathSteps) - { - if(this->GetCameraPathClosed()) - { - mState.posOnPath = 0; - } - else - { - this->Reset(); - mCameraPath->SetEnabled(true); - return false; - } - } - // - // Position the camera - // - this->PositionCameraOnThePath(); - // - // Update step counter if we are moving - // - if(!mState.stopOnPath) mState.posOnPath++; - } - - this->GetViewModule()->Render(); - } - // - // Image data holder - // - iStereoImageArray images, tmparr; - iImage tmp; - // - // Transition effects - // - bool doTransitionFrames = dumpImage && mTotFrame>0 && mPrevRec>0 && mCurFrame<=mState.nTransitionFrames && mState.nTransitionFrames>0 && mDebugFlag==0; - if(doTransitionFrames) - { - // - // Objects for transition effects (blending with previous record) - // - this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->CreateImages(images); - if(this->GetErrorStatus()->NoError()) + wData.v[i] = vB[i]*cot-vA[i]*sot; + wData.x[i] = r0[i] + r1[i] + xc[i]; + } + + CAM->SetPosition(wData.x); + CAM->OrthogonalizeViewUp(); + wData.t = wData.t + wData.dt; + + if(wData.t > 1.0) { - this->GetErrorStatus()->Monitor(DATAREADER->GetErrorStatus(),true); - DATAREADER->LoadRecord(mPrevRec,0,false); - if(this->GetErrorStatus()->NoError()) + wData.t = 0.0; + for(i=0; i<3; i++) { - this->GetViewModule()->UpdateLabel(); - this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->CreateImages(tmparr); - if(this->GetErrorStatus()->NoError()) - { - float ops = (float)mCurFrame/mState.nTransitionFrames; - for(i=0; iGetErrorStatus()->NoError()) - { - this->GetErrorStatus()->Monitor(DATAREADER->GetErrorStatus(),true); - DATAREADER->LoadRecord(mCurRec,0,false); - } - else return false; } // - // Blending of images + // Image data holder // - bool doBlendedFrames = dumpImage && mTotFrame >0 && mState.nBlendedFrames>0 && mDebugFlag==0; - if(doBlendedFrames) - { - if(images.Size() == 0) - { - this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->CreateImages(images); - } - if(this->GetErrorStatus()->NoError()) - { - int k; - // - // Update the image list - // - while(mBlenderBase.Size() < mState.nBlendedFrames) - { - iStereoImageArray *ptmparr = new iStereoImageArray; IERROR_ASSERT(ptmparr); - ptmparr->Copy(images); - mBlenderBase.Add(ptmparr); - } - while(mBlenderBase.Size() > mState.nBlendedFrames) - { - delete mBlenderBase.RemoveLast(); - } - - delete mBlenderBase[0]; - for(k=0; kCopy(*mBlenderBase[k+1]); - mBlenderBase.Last()->Copy(images); + iStereoImageArray images; - // - // Make sure that all the arrays are of the same size - // - for(k=0; kSize() > images.Size()) mBlenderBase[k]->RemoveLast(); - while(mBlenderBase[k]->Size() < images.Size()) mBlenderBase[k]->Add(images[mBlenderBase[k]->Size()]); - } + // + // Create the primary image set + // + this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); + this->GetViewModule()->CreateImages(images); + if(this->GetErrorStatus()->IsError()) return false; - // - // Blend the arrays - // - int n = 1; - float ops; - images.Copy(*mBlenderBase[0]); - for(k=1; kUpdate() when vtkRenderWindow changes its size (it does not invoke an event). @@ -894,351 +814,183 @@ this->GetViewModule()->GetControlModule()->GetImageComposer()->Update(); tmp.Scale(this->GetViewModule()->GetFullImageWidth(),this->GetViewModule()->GetFullImageHeight()); - if(mTotFrame <= 0) + iStereoImageArray tmpset; + tmpset.Copy(images); + + int n; + for(n=0; nDumpImages(tmpset); + if(this->GetErrorStatus()->IsError()) return false; } - else if(mState.titlePageNumBlendedFrames > 0) + + for(n=0; nGetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->CreateImages(images); - } - // // Dissolve it; image already contains the correct image // - if(this->GetErrorStatus()->NoError()) - { - for(i=0; iDumpImages(tmpset); + if(this->GetErrorStatus()->IsError()) return false; } - if(mTotFrame > mState.titlePageNumBlendedFrames) mDoingTitlePage = false; } // - // Logo + // Transition effects // - if(dumpImage && mDebugFlag==0 && !mState.logoFile.IsEmpty()) + bool doTransitionFrames = dumpImage && mTotFrame>0 && mPrevRec>0 && mCurFrame<=mState.nTransitionFrames && mState.nTransitionFrames>0 && mDebugFlag==0; + if(doTransitionFrames) { + iStereoImageArray tmpset; // - // Create the image to place a logo on, if needed + // Objects for transition effects (blending with previous record) // - if(images.Size() == 0) - { - this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->CreateImages(images); - } - if(this->GetErrorStatus()->NoError()) // we do have the image - { - // - // If the logo is more than 20% of the image, scale it down. - // Use tmp as a temp storage - // - tmp = mLogoImage; - if(tmp.Width()>images[0].Width()/5 || tmp.Height()>images[0].Height()/5) - { - tmp.Scale(images[0].Width()/5,images[0].Height()/5); - } - - if(tmp.Width()>=2 && tmp.Height()>=2) - { - // - // tmp is now the proper logo image - // - int ioff, joff; - // - // Where do we place the logo? - // - ioff = tmp.Width()/5; - joff = tmp.Height()/5; - switch(mState.logoPosition) - { - case 1: - { - // upper right corner - ioff = images[0].Width() - tmp.Width() - ioff; - joff = images[0].Height() - tmp.Height() - joff; - break; - } - case 2: - { - // lower left right corner - break; - } - case 3: - { - // lower right corner - ioff = images[0].Width() - tmp.Width() - ioff; - break; - } - default: - { - // upper left corner - the default choice - joff = images[0].Height() - tmp.Height() - joff; - break; - } - } - for(i=0; iGetErrorStatus()->Monitor(mFollowers[i]->GetErrorStatus(),true,"Follower Animator from window #"+iString::FromNumber(1+mFollowers[i]->GetViewModule()->GetWindowNumber())); - if(!mFollowers[i]->RenderImages(false)) break; - } + this->GetErrorStatus()->Monitor(DATAREADER->GetErrorStatus(),true); + DATAREADER->LoadRecord(mPrevRec,0,false); + if(this->GetErrorStatus()->IsError()) return false; - if(mDebugFlag==0 && dumpImage) - { + this->GetViewModule()->UpdateLabel(); this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); - this->GetViewModule()->DumpImages(images,ImageType::AnimationFrame); - } + this->GetViewModule()->CreateImages(tmpset); + if(this->GetErrorStatus()->IsError()) return false; - return this->GetErrorStatus()->NoError(); -} + float ops = (float)mCurFrame/mState.nTransitionFrames; + this->GetErrorStatus()->Monitor(DATAREADER->GetErrorStatus(),true); + DATAREADER->LoadRecord(mCurRec,0,false); + if(this->GetErrorStatus()->IsError()) return false; + } -void iAnimator::PositionCameraOnThePath() -{ - double x1[3], x2[3], dx12[3], xc[3]; - int i, i1, i2, np; - double d, dl; - - vtkPoints *pts1 = mCameraPath->GetCameraPathPoints(); - vtkPoints *pts2 = mCameraPath->GetFocalPathPoints(); - np = pts1->GetNumberOfPoints(); - - int pathStep = mState.posOnPath; - - if(pathStep<0 || pathStep>=mNumPathSteps) return; - - dl = double(pathStep*(np-1))/(mNumPathSteps-1); // position on the path from 0 to np-1 - i1 = (int)floor(dl); - if(i1 == np-1) + // + // Blending of images + // + bool doBlendedFrames = dumpImage && mTotFrame >0 && mState.nBlendedFrames>0 && mDebugFlag==0; + if(doBlendedFrames) { + int k; // - // Last interval frame + // Update the image list // - i1 = np - 2; - } - - pts1->GetPoint(i1,x1); - i2 = i1 + 1; - while(i2 < np) - { - pts1->GetPoint(i2,x2); - for(i=0; i<3; i++) dx12[i] = x2[i] - x1[i]; - if(vtkMath::Norm(dx12) > 0) break; - i2++; - } - if(i2 == np) i2--; - - d = (dl-i1)/(i2-i1); - for(i=0; i<3; i++) xc[i] = x1[i] + d*(x2[i]-x1[i]); - CAM->SetPosition(xc); - - if(pts2 != 0) - { - pts2->GetPoint(i1,x1); - pts2->GetPoint(i2,x2); - for(i=0; i<3; i++) xc[i] = x1[i] + d*(x2[i]-x1[i]); - CAM->SetFocalPoint(xc); - } - else - { - double dx1[3], dx2[3], x[3]; - vtkMath::Normalize(dx12); - - if(i1 > 0) + while(mBlenderBase.Size() < mState.nBlendedFrames) { - pts1->GetPoint(i1-1,x); - for(i=0; i<3; i++) dx1[i] = x1[i] - x[i]; - vtkMath::Normalize(dx1); - for(i=0; i<3; i++) dx1[i] = 0.5*(dx1[i]+dx12[i]); + iStereoImageArray *ptmparr = new iStereoImageArray; IERROR_ASSERT(ptmparr); + ptmparr->Copy(images); + mBlenderBase.Add(ptmparr); } - else + while(mBlenderBase.Size() > mState.nBlendedFrames) { - for(i=0; i<3; i++) dx1[i] = dx12[i]; + delete mBlenderBase.RemoveLast(); } - if(i2 < np-1) + delete mBlenderBase[0]; + for(k=0; kCopy(*mBlenderBase[k+1]); + mBlenderBase.Last()->Copy(images); + + // + // Make sure that all the arrays are of the same size + // + for(k=0; kGetPoint(i2+1,x); - for(i=0; i<3; i++) dx2[i] = x[i] - x2[i]; - vtkMath::Normalize(dx2); - for(i=0; i<3; i++) dx2[i] = 0.5*(dx2[i]+dx12[i]); + while(mBlenderBase[k]->Size() > images.Size()) mBlenderBase[k]->RemoveLast(); + while(mBlenderBase[k]->Size() < images.Size()) mBlenderBase[k]->Add(images[mBlenderBase[k]->Size()]); } - else + + // + // Blend the arrays + // + int n = 1; + float ops; + images.Copy(*mBlenderBase[0]); + for(k=1; kGetDistance(); - for(i=0; i<3; i++) x[i] = xc[i] + dx12[i]*fd; - CAM->SetFocalPoint(x); } - CAM->OrthogonalizeViewUp(); - - mAnimatorObserver->Execute(0,0UL,0); -} -// -// Camera path functions -// -int iAnimator::GetNumberOfCameraPathHandles() const -{ - return mCameraPath->GetNumberOfHandles(); -} - - -bool iAnimator::GetCameraPathClosed() const -{ - return mCameraPath->GetClosed(); -} - - -bool iAnimator::GetFocalPathEnabled() const -{ - return mCameraPath->GetFocalPathEnabled(); -} - - -bool iAnimator::GetFocalPathToPoint() const -{ - return mCameraPath->GetFocalPathToPoint(); -} - - -void iAnimator::SetNumberOfCameraPathHandles(int v) -{ - if(v > 1) - { - mCameraPath->SetNumberOfHandles(v); - this->ClearCache(); - } -} - - -void iAnimator::SetNumberOfCameraPathSteps(int n) -{ - if(n >= mCameraPath->GetNumberOfHandles()-1) + + for(i=0; iClearCache(); + this->GetErrorStatus()->Monitor(mFollowers[i]->GetErrorStatus(),true,"Follower Animator from window #"+iString::FromNumber(1+mFollowers[i]->GetViewModule()->GetWindowNumber())); + if(!mFollowers[i]->Frame(false)) break; } -} - - -void iAnimator::SetCameraPathClosed(bool v) -{ - mCameraPath->SetClosed(v); - this->ClearCache(); -} - - -void iAnimator::SetFocalPathEnabled(bool s) -{ - mCameraPath->SetFocalPathEnabled(s); - this->ClearCache(); -} - - -void iAnimator::SetFocalPathToPoint(bool s) -{ - mCameraPath->SetFocalPathToPoint(s); - this->ClearCache(); -} - -void iAnimator::SetCameraPathColor(iColor &c) -{ - mCameraPath->SetLineColor(c); - this->ClearCache(); -} - - -bool iAnimator::IsCameraPathValid() const -{ - vtkPoints *pts1 = mCameraPath->GetCameraPathPoints(); - vtkPoints *pts2 = mCameraPath->GetFocalPathPoints(); - if(pts2 == 0) return true; - - int i, n = pts1->GetNumberOfPoints(); - for(i=0; iGetPoint(i),pts2->GetPoint(i)) < 1.0e-8) return false; + this->DumpImages(images); } - return true; -} - -void iAnimator::StopCameraPathDemo() -{ - mIsPlayingDemo = false; + return this->GetErrorStatus()->NoError(); } -void iAnimator::PlayCameraPathDemo() +// +// Dump an image array, optionally adding a logo +// +void iAnimator::DumpImages(iStereoImageArray &images) { - if(mState.mode == 4) + if(images.Size()>0 && mDebugFlag==0 && !mLogoImage.IsEmpty()) { - int pos = mState.posOnPath; - float t; - double camPosition[3], camFocalPoint[3], camViewUp[3]; - // - // Save the camera parameters + // If the logo is more than 20% of the image, scale it down. + // Use tmp as a temp storage // - CAM->GetPosition(camPosition); - CAM->GetFocalPoint(camFocalPoint); - CAM->GetViewUp(camViewUp); - - // - // Place in starting position - // - mCameraPath->SetHandleOpacity(0.5); + iImage tmp = mLogoImage; + if(tmp.Width()>images[0].Width()/5 || tmp.Height()>images[0].Height()/5) + { + tmp.Scale(images[0].Width()/5,images[0].Height()/5); + } - // - // Fly along the main path - // - mIsPlayingDemo = true; - for(; mIsPlayingDemo && mState.posOnPath=2 && tmp.Height()>=2) { - this->PositionCameraOnThePath(); - this->GetViewModule()->Render(); // - // Measure the render time + // tmp is now the proper logo image + // + int i, ioff, joff; // - this->GetViewModule()->Render(); - t = this->GetViewModule()->GetRenderer()->GetLastRenderTimeInSeconds(); - if(t < 0.1) iSystem::Sleep(round(500.0*(0.1-t))); - this->ClearCache(); + // Where do we place the logo? + // + ioff = tmp.Width()/5; + joff = tmp.Height()/5; + switch(mLogoLocation) + { + case 1: + { + // upper right corner + ioff = images[0].Width() - tmp.Width() - ioff; + joff = images[0].Height() - tmp.Height() - joff; + break; + } + case 2: + { + // lower left right corner + break; + } + case 3: + { + // lower right corner + ioff = images[0].Width() - tmp.Width() - ioff; + break; + } + default: + { + // upper left corner - the default choice + joff = images[0].Height() - tmp.Height() - joff; + break; + } + } + for(i=0; iSetHandleOpacity(1.0); - mState.posOnPath = pos; - PositionCameraOnThePath(); - - // - // Restore the camera parameters - // - CAM->SetPosition(camPosition); - CAM->SetFocalPoint(camFocalPoint); - CAM->SetViewUp(camViewUp); - - this->GetViewModule()->Render(); } + + this->GetErrorStatus()->Monitor(this->GetViewModule()->GetErrorStatus(),true); + this->GetViewModule()->DumpImages(images,ImageType::AnimationFrame); } @@ -1250,13 +1002,7 @@ this->PackValue(s,KeyDebugFlag(),mDebugFlag); this->PackValue(s,KeyDebugging(),mDebugFlag!=0); - this->PackValue(s,KeyUseScript(),mUseScript); - this->PackValue(s,KeyScriptFileName(),mScriptFileName); - this->PackValue(s,KeyFocalPathEnabled(),this->GetFocalPathEnabled()); - this->PackValue(s,KeyFocalPathToPoint(),this->GetFocalPathToPoint()); - this->PackValue(s,KeyCameraPathClosed(),this->GetCameraPathClosed()); - this->PackValue(s,KeyRestoreCamera(),mRestoreCamera); - this->PackValue(s,KeyInheritSettings(),mInheritSettings); + this->PackValue(s,KeyScriptFile(),mScriptFile); this->PackValue(s,KeyStyle(),mState.mode); this->PackValue(s,KeyNumberOfFrames(),mState.nframes); @@ -1270,54 +1016,20 @@ this->PackValue(s,KeyCrossSectionSpeed(),mState.slideSpeed); this->PackValue(s,KeyFlybySpeed(),mState.flybySpeed); - this->PackValue(s,KeyTitlePageFile(),mState.titlePageFile); - this->PackValue(s,KeyNumberOfTitlePageFrames(),mState.titlePageNumFrames); - this->PackValue(s,KeyNumberOfTitlePageBlendedFrames(),mState.titlePageNumBlendedFrames); - this->PackValue(s,KeyLogoFile(),mState.logoFile); - this->PackValue(s,KeyLogoOpacity(),mState.logoOpacity); - this->PackValue(s,KeyLogoPosition(),mState.logoPosition); - - this->PackValue(s,KeyPositionOnPath(),mState.posOnPath); - this->PackValue(s,KeyStopOnPath(),mState.stopOnPath); - this->PackValue(s,KeyNumberOfCameraPathHandles(),this->GetNumberOfCameraPathHandles()); - this->PackValue(s,KeyNumberOfCameraPathSteps(),mNumPathSteps); - - int n = mCameraPath->GetNumberOfHandles(); - - float *x1 = new float[n]; IERROR_ASSERT(x1); - float *x2 = new float[n]; IERROR_ASSERT(x2); - float *x3 = new float[n]; IERROR_ASSERT(x3); - - mCameraPath->GetCameraPathHandlePositions(x1,x2,x3); - this->PackValue(s,KeyCameraPathX(),x1,n); - this->PackValue(s,KeyCameraPathY(),x2,n); - this->PackValue(s,KeyCameraPathZ(),x3,n); - - if(this->GetFocalPathEnabled()) - { - mCameraPath->GetFocalPathHandlePositions(x1,x2,x3); - this->PackValue(s,KeyFocalPathX(),x1,n); - this->PackValue(s,KeyFocalPathY(),x2,n); - this->PackValue(s,KeyFocalPathZ(),x3,n); - } - - delete [] x1; - delete [] x2; - delete [] x3; + this->PackValue(s,KeyTitlePageFile(),mTitlePageFile); + this->PackValue(s,KeyNumberOfTitlePageFrames(),mTitlePageNumFrames); + this->PackValue(s,KeyNumberOfTitlePageBlendedFrames(),mTitlePageNumBlendedFrames); + this->PackValue(s,KeyLogoFile(),mLogoFile); + this->PackValue(s,KeyLogoOpacity(),mLogoOpacity); + this->PackValue(s,KeyLogoLocation(),mLogoLocation); } void iAnimator::UnPackStateBody(const iString &s) { - int i; bool b; float f; iString ss; + int i; float f; iString ss; if(this->UnPackValue(s,KeyDebugFlag(),i)) this->SetDebugFlag(i); - if(this->UnPackValue(s,KeyUseScript(),b)) this->SetUseScript(b); - if(this->UnPackValue(s,KeyFocalPathEnabled(),b)) this->SetFocalPathEnabled(b); - if(this->UnPackValue(s,KeyFocalPathToPoint(),b)) this->SetFocalPathToPoint(b); - if(this->UnPackValue(s,KeyCameraPathClosed(),b)) this->SetCameraPathClosed(b); - if(this->UnPackValue(s,KeyRestoreCamera(),b)) this->SetRestoreCamera(b); - if(this->UnPackValue(s,KeyInheritSettings(),b)) this->SetInheritSettings(b); if(this->UnPackValue(s,KeyNumberOfFrames(),i)) this->SetNumberOfFrames(i); if(this->UnPackValue(s,KeyNumberOfBlendedFrames(),i)) this->SetNumberOfBlendedFrames(i); @@ -1330,63 +1042,13 @@ if(this->UnPackValue(s,KeyCrossSectionSpeed(),f)) this->SetCrossSectionSpeed(f); if(this->UnPackValue(s,KeyFlybySpeed(),f)) this->SetFlybySpeed(f); + if(this->UnPackValue(s,KeyScriptFile(),ss)) this->SetScriptFile(ss); if(this->UnPackValue(s,KeyTitlePageFile(),ss)) this->SetTitlePageFile(ss); if(this->UnPackValue(s,KeyNumberOfTitlePageFrames(),i)) this->SetNumberOfTitlePageFrames(i); if(this->UnPackValue(s,KeyNumberOfTitlePageBlendedFrames(),i)) this->SetNumberOfTitlePageBlendedFrames(i); if(this->UnPackValue(s,KeyLogoFile(),ss)) this->SetLogoFile(ss); if(this->UnPackValue(s,KeyLogoOpacity(),f)) this->SetLogoOpacity(f); - if(this->UnPackValue(s,KeyLogoPosition(),i)) this->SetLogoPosition(i); - - if(this->UnPackValue(s,KeyPositionOnPath(),i)) this->SetPositionOnPath(i); - if(this->UnPackValue(s,KeyStopOnPath(),b)) this->SetStopOnPath(b); - if(this->UnPackValue(s,KeyNumberOfCameraPathHandles(),i)) this->SetNumberOfCameraPathHandles(i); - if(this->UnPackValue(s,KeyNumberOfCameraPathSteps(),i)) this->SetNumberOfCameraPathSteps(i); - - int n = mCameraPath->GetNumberOfHandles(); - float *x1 = new float[n]; IERROR_ASSERT(x1); - float *x2 = new float[n]; IERROR_ASSERT(x2); - float *x3 = new float[n]; IERROR_ASSERT(x3); - - mCameraPath->GetCameraPathHandlePositions(x1,x2,x3); - if(this->UnPackValue(s,KeyCameraPathX(),x1,n)) - { - mCameraPath->SetCameraPathHandlePositions(0,x1); - this->ClearCache(); - } - if(this->UnPackValue(s,KeyCameraPathY(),x2,n)) - { - mCameraPath->SetCameraPathHandlePositions(1,x2); - this->ClearCache(); - } - if(this->UnPackValue(s,KeyCameraPathZ(),x3,n)) - { - mCameraPath->SetCameraPathHandlePositions(2,x3); - this->ClearCache(); - } - - if(this->GetFocalPathEnabled()) - { - mCameraPath->GetFocalPathHandlePositions(x1,x2,x3); - if(this->UnPackValue(s,KeyCameraPathX(),x1,n)) - { - mCameraPath->SetFocalPathHandlePositions(0,x1); - this->ClearCache(); - } - if(this->UnPackValue(s,KeyCameraPathY(),x2,n)) - { - mCameraPath->SetFocalPathHandlePositions(1,x2); - this->ClearCache(); - } - if(this->UnPackValue(s,KeyCameraPathZ(),x3,n)) - { - mCameraPath->SetFocalPathHandlePositions(2,x3); - this->ClearCache(); - } - } - - delete [] x1; - delete [] x2; - delete [] x3; + if(this->UnPackValue(s,KeyLogoLocation(),i)) this->SetLogoLocation(i); if(this->UnPackValue(s,KeyStyle(),i)) this->SetStyle(i); @@ -1395,14 +1057,8 @@ // iObject::ReportMissingKeys(false); //action keys are not part of the states - if(this->UnPackValue(s,KeyLoadScriptFile(),ss)) this->LoadScriptFile(ss); - - if(this->UnPackValue(s,KeyCameraPathDemo(),b)) - { - if(b) this->PlayCameraPathDemo(); else this->StopCameraPathDemo(); - } + if(this->UnPackValue(s,KeyLoadScriptFile(),ss)) this->SetScriptFile(ss); iObject::ReportMissingKeys(true); } - diff -Nru ifrit-3.3.4/core/ianimator.h ifrit-3.4.2/core/ianimator.h --- ifrit-3.3.4/core/ianimator.h 2011-01-27 17:51:04.000000000 +0000 +++ ifrit-3.4.2/core/ianimator.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -39,7 +39,6 @@ class iAnimatorEventObserver; class iAnimatorScript; -class iCameraPath; class iStereoImageArray; class vtkImageData; @@ -69,14 +68,6 @@ double cameraViewUp[3]; double cameraParallelScale; double cameraClippingRange[2]; - iString titlePageFile; - int titlePageNumBlendedFrames; - int titlePageNumFrames; - iString logoFile; - float logoOpacity; - int logoPosition; - bool stopOnPath; - int posOnPath; }; @@ -129,80 +120,40 @@ //virtual void SetNumberOfTransitionFrames(int na); //inline int GetNumberOfTransitionFrames() const { return mState.nTransitionFrames; } - IOBJECT_DECLARE_GETSET(NumberOfTitlePageFrames,mState.titlePageNumFrames,int); - //virtual void SetNumberOfTitlePageFrames(int n); - //inline int GetNumberOfTitlePageFrames() const { return mState.titlePageNumFrames; } - - IOBJECT_DECLARE_GETSET(NumberOfTitlePageBlendedFrames,mState.titlePageNumBlendedFrames,int); - //virtual void SetNumberOfTitlePageBlendedFrames(int n); - //inline int GetNumberOfTitlePageBlendedFrames() const { return mState.titlePageNumBlendedFrames; } - - IOBJECT_DECLARE_GETSET(LogoPosition,mState.logoPosition,int); - //virtual void SetLogoPosition(int n); - //inline int GetLogoPosition() const { return mState.logoPosition; } - - IOBJECT_DECLARE_GETSET(StopOnPath,mState.stopOnPath,bool); - //virtual void SetStopOnPath(bool n); - //inline bool GetStopOnPath() const { return mState.stopOnPath; } - - IOBJECT_DECLARE_GETSET(PositionOnPath,mState.posOnPath,int); - //virtual void SetPositionOnPath(int n); - //inline int GetPositionOnPath() const { return mState.posOnPath; } - - IOBJECT_DECLARE_GETSET(LogoOpacity,mState.logoOpacity,float); - //virtual void SetLogoOpacity(float v); - //inline float GetLogoOpacity() const { return mState.logoOpacity; } - - IOBJECT_DECLARE_GETSET1(UseScript,bool); - //virtual void SetUseScript(bool s); - //inline bool GetUseScript() const { return mUseScript; } - - IOBJECT_DECLARE_GETSET1(RestoreCamera,bool); - //virtual void SetRestoreCamera(bool s); - //inline bool GetRestoreCamera() const { return mRestoreCamera; } - - IOBJECT_DECLARE_GETSET1(InheritSettings,bool); - //virtual void SetInheritSettings(bool s); - //inline bool GetInheritSettings() const { return mInheritSettings; } - - IOBJECT_DECLARE_GETSET1(ScriptFileName,const iString&); - //virtual void SetScriptFileName(const iString &s); - //inline const String& GetScriptFileName() const { return mScriptFileName; } - static const iObjectKey& KeyLoadScriptFile(); - bool LoadScriptFile(const iString &fname); - IOBJECT_DECLARE_GETSET1(DebugFlag,int); //virtual void SetDebugFlag(int s); //inline int GetDebugFlag() const { retun mDebugFlag; } static const iObjectKey& KeyDebugging(); - IOBJECT_DECLARE_GETSET(NumberOfCameraPathSteps,mNumPathSteps,int); - //virtual void SetNumberOfCameraPathSteps(int n); - //inline int GetNumberOfCameraPathSteps() const { return mNumPathSteps; } - - IOBJECT_DECLARE_GETSET2(NumberOfCameraPathHandles,int); - //virtual void SetNumberOfCameraPathHandles(int n); - //int GetNumberOfCameraPathHandles() const; - - IOBJECT_DECLARE_GETSET2(CameraPathClosed,bool); - //virtual void SetCameraPathClosed(bool s); - //bool GetCameraPathClosed() const; - - IOBJECT_DECLARE_GETSET2(FocalPathEnabled,bool); - //virtual void SetFocalPathEnabled(bool s); - //bool GetFocalPathEnabled() const; + bool SetScriptFile(const iString &fname); + IOBJECT_DECLARE_GET1(ScriptFile,const iString&); + //virtual void SetScriptFileName(const iString &s); + //inline const String& GetScriptFile() const { return mScriptFile; } + static const iObjectKey& KeyLoadScriptFile(); + + bool SetTitlePageFile(const iString &fname); + IOBJECT_DECLARE_GET1(TitlePageFile,const iString&); + //inline const iString& GetTitlePageFile() const { return mTitlePageFile; } + + bool SetLogoFile(const iString &fname); + IOBJECT_DECLARE_GET1(LogoFile,const iString&); + //inline const iString& GetLogoFile() const { return mLogoFile; } + + IOBJECT_DECLARE_GETSET(NumberOfTitlePageFrames,mTitlePageNumFrames,int); + //virtual void SetNumberOfTitlePageFrames(int n); + //inline int GetNumberOfTitlePageFrames() const { return mTitlePageNumFrames; } - IOBJECT_DECLARE_GETSET2(FocalPathToPoint,bool); - //virtual void SetFocalPathToPoint(bool s); - //bool GetFocalPathToPoint() const; - - bool SetTitlePageFile(const iString &s); - IOBJECT_DECLARE_GET(TitlePageFile,mState.titlePageFile,const iString&); - //inline const iString& GetTitlePageFile() const { return mState.titlePageFile; } - - bool SetLogoFile(const iString &s); - IOBJECT_DECLARE_GET(LogoFile,mState.logoFile,const iString&); - //inline const iString& GetLogoFile() const { return mState.logoFile; } + IOBJECT_DECLARE_GETSET(NumberOfTitlePageBlendedFrames,mTitlePageNumBlendedFrames,int); + //virtual void SetNumberOfTitlePageBlendedFrames(int n); + //inline int GetNumberOfTitlePageBlendedFrames() const { return mTitlePageNumBlendedFrames; } + + IOBJECT_DECLARE_GETSET1(LogoLocation,int); + //virtual void SetLogoLocation(int n); + //inline int GetLogoLocation() const { return mLogoLocation; } + + IOBJECT_DECLARE_GETSET1(LogoOpacity,float); + //virtual void SetLogoOpacity(float v); + //inline float GetLogoOpacity() const { return mLogoOpacity; } inline const iImage& GetTitlePageImage() const { return mTitlePageImage; } static const iObjectKey& KeyTitlePageImage(); @@ -213,13 +164,7 @@ inline float GetCrossSectionSpeed() const { return (float)fabs(mState.slideSpeed); } static const iObjectKey& KeyCrossSectionSpeed(); - static const iObjectKey& KeyCameraPathX(); - static const iObjectKey& KeyCameraPathY(); - static const iObjectKey& KeyCameraPathZ(); - static const iObjectKey& KeyFocalPathX(); - static const iObjectKey& KeyFocalPathY(); - static const iObjectKey& KeyFocalPathZ(); - static const iObjectKey& KeyCameraPathDemo(); + inline bool UsingScript() const { return mUsingScript; } // // Animator controls @@ -238,14 +183,6 @@ inline void GetInfo(bool &nr, int &cr, int &cf) const { nr = mNewRec; cr = mCurRec; cf = mCurFrame; } virtual void CopyState(iAnimator *other); - // - // Camera path functions - // - void SetCameraPathColor(iColor &c); - bool IsCameraPathValid() const; - void PlayCameraPathDemo(); - void StopCameraPathDemo(); - protected: virtual ~iAnimator(); @@ -257,39 +194,38 @@ iAnimator(iViewModule *vm); - void PositionCameraOnThePath(); void SetLeader(iAnimator *l); - bool RenderImages(bool dumpImage = true); - void Reset(); + bool Frame(bool dumpImage = true); + void DumpImages(iStereoImageArray &images); + void ResetCurrentFile(); - void ResetState(); void SaveState(); - void RestoreState(); + void RestoreState(bool with_camera); - bool mStarted, mStartedRender, mUseScript, mRestoreCamera, mInheritSettings, mIsPlayingDemo; + bool mStarted, mStartedRender, mUsingScript; unsigned long mSeed; int mDebugFlag; - iString mScriptFileName, mScriptText; + iString mScriptFile; iAnimatorState mState; iAnimatorState mState2; float mRandStep; bool mNewRec; - int mPrevRec, mCurRec, mTotFrame, mCurFrame, mNumPathSteps; + int mPrevRec, mCurRec, mTotFrame, mCurFrame; iArray mBlenderBase; + iString mTitlePageFile, mLogoFile; iImage mTitlePageImage, mLogoImage; - bool mDoingTitlePage; + int mTitlePageNumBlendedFrames, mTitlePageNumFrames, mLogoLocation; + float mLogoOpacity; iAnimatorScript *mAnimatorScript; iAnimatorEventObserver *mAnimatorObserver; - iCameraPath *mCameraPath; - iSearchableArray mFollowers; iAnimator *mLeader; @@ -305,160 +241,5 @@ } wData; }; - -inline void iAnimator::SetNumberOfFrames(int na) -{ - if(na > 0) - { - mState.nframes = na; - this->ClearCache(); - } -} - - -inline void iAnimator::SetPhi(float va) -{ - mState.dphi = va; - this->ClearCache(); -} - - -inline void iAnimator::SetTheta(float va) -{ - mState.dtheta = va; - this->ClearCache(); -} - - -inline void iAnimator::SetZoom(float va) -{ - mState.dscale = va; - this->ClearCache(); -} - - -inline void iAnimator::SetRoll(float va) -{ - mState.droll = va; - this->ClearCache(); -} - - -inline void iAnimator::SetCrossSectionSpeed(float va) -{ - mState.slideSpeed = va; - this->ClearCache(); -} - - -inline void iAnimator::SetFlybySpeed(float va) -{ - mState.flybySpeed = va; - this->ClearCache(); -} - - -inline void iAnimator::SetNumberOfBlendedFrames(int na) -{ - if(na >= 0) - { - mState.nBlendedFrames = na; - this->ClearCache(); - } -} - - -inline void iAnimator::SetNumberOfTransitionFrames(int na) -{ - if(na >= 0) - { - mState.nTransitionFrames = na; - this->ClearCache(); - } -} - - -inline void iAnimator::SetNumberOfTitlePageFrames(int n) -{ - if(n >= 0) - { - mState.titlePageNumFrames = n; - this->ClearCache(); - } -} - - -inline void iAnimator::SetNumberOfTitlePageBlendedFrames(int n) -{ - if(n >= 0) - { - mState.titlePageNumBlendedFrames = n; - this->ClearCache(); - } -} - - -inline void iAnimator::SetLogoPosition(int n) -{ - if(n>0 && n<5) - { - mState.logoPosition = n; - this->ClearCache(); - } -} - - -inline void iAnimator::SetLogoOpacity(float v) -{ - mState.logoOpacity = v; - this->ClearCache(); -} - - -inline void iAnimator::SetStopOnPath(bool s) -{ - mState.stopOnPath = s; - this->ClearCache(); -} - - -inline void iAnimator::SetPositionOnPath(int s) -{ - if(s>=0 && sPositionCameraOnThePath(); - this->ClearCache(); - } -} - - -inline void iAnimator::SetUseScript(bool s) -{ - mUseScript = s; - this->ClearCache(); -} - - -inline void iAnimator::SetRestoreCamera(bool s) -{ - mRestoreCamera = s; - this->ClearCache(); -} - - -inline void iAnimator::SetInheritSettings(bool s) -{ - mInheritSettings = s; - this->ClearCache(); -} - - -inline void iAnimator::SetScriptFileName(const iString &s) -{ - mScriptFileName = s; - this->ClearCache(); -} - #endif // IANIMATOR_H diff -Nru ifrit-3.3.4/core/ianimatorscript.cpp ifrit-3.4.2/core/ianimatorscript.cpp --- ifrit-3.3.4/core/ianimatorscript.cpp 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/ianimatorscript.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -87,7 +87,7 @@ DEFINE_WORKER_ABS(Animator,SetStyle,int); DEFINE_WORKER_ABS(Animator,SetNumberOfTitlePageFrames,int); DEFINE_WORKER_ABS(Animator,SetNumberOfTitlePageBlendedFrames,int); - DEFINE_WORKER_ABS(Animator,SetLogoPosition,int); + DEFINE_WORKER_ABS(Animator,SetLogoLocation,int); DEFINE_WORKER_ABS(Camera,SetParallelScale,double); DEFINE_WORKER_ABS(Camera,SetParallelProjection,bool); DEFINE_WORKER_ABS(Visual,ShowLabel,bool); @@ -247,6 +247,7 @@ this->CreateAliasWord("upper-right-corner","urcorner"); this->CreateAliasWord("lower-left-corner","llcorner"); this->CreateAliasWord("lower-right-corner","lrcorner"); + this->CreateAliasWord("logo-position","logo-location"); #endif // @@ -281,9 +282,7 @@ this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("render-all",RenderAll); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("render-set",RenderSet); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("load",Load); - - this->AddPrototype< iScriptKit::SimpleStatement >("reset",Reset); - + this->AddPrototype< iScriptKit::FunctionCallStatement >("execute control-script",ExecuteControlScript); this->AddPrototype< iScriptKit::FunctionCallStatement >("embed control-script",EmbedControlScript); @@ -318,7 +317,7 @@ this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("title-page-number-of-frames",AnimatorSetNumberOfTitlePageFrames); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("title-page-number-of-blended-frames",AnimatorSetNumberOfTitlePageBlendedFrames); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("logo-opacity",AnimatorSetLogoOpacity); - this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("logo-position",AnimatorSetLogoPosition); + this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("logo-location",AnimatorSetLogoLocation); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("surface",SurfaceShow); this->AddPrototype< iScriptKit::FunctionCallAssignmentStatement >("cross-section",CrossSectionShow); @@ -377,18 +376,6 @@ // -// Reset Animator settings -// -bool iAnimatorScript::Reset(iScript *self) -{ - curAnimator->ResetState(); - curAnimator->Reset(); - curVisual->GetRenderTool()->GetCamera()->Reset(); - return true; -} - - -// // Render scene // bool iAnimatorScript::Render(iScript *self, short, int n) @@ -401,7 +388,7 @@ self->GetErrorStatus()->Monitor(curAnimator->GetErrorStatus(),true); for(i=0; iCheckAbort(i,n,1) && self->GetErrorStatus()->NoError(); i++) { - if(!curAnimator->RenderImages()) self->GetErrorStatus()->Set("Animation finished.",-1); + if(!curAnimator->Frame()) self->GetErrorStatus()->Set("Animation finished.",-1); } curScript->SetInRender(false); @@ -424,12 +411,12 @@ // // Force other animators to continue, even if they are done // - curControl->GetViewModule(k)->GetAnimator()->RenderImages(false); + curControl->GetViewModule(k)->GetAnimator()->Frame(false); } if(self->GetErrorStatus()->NoError()) { self->GetErrorStatus()->Monitor(curAnimator->GetErrorStatus(),true); - if(!curAnimator->RenderImages()) self->GetErrorStatus()->Set("Animation finished.",-1); + if(!curAnimator->Frame()) self->GetErrorStatus()->Set("Animation finished.",-1); } } @@ -455,12 +442,12 @@ for(i=0; self->GetErrorStatus()->NoError() && !self->CheckAbort(i,num,1) && i0 && v[i]<=curControl->GetNumberOfViewModules() && v[i]!=1+curControl->GetCurrentViewModuleIndex()) { self->GetErrorStatus()->Monitor(curControl->GetViewModule(v[i]-1)->GetAnimator()->GetErrorStatus(),true); - curControl->GetViewModule(v[i]-1)->GetAnimator()->RenderImages(false); + curControl->GetViewModule(v[i]-1)->GetAnimator()->Frame(false); } for(i=0; self->GetErrorStatus()->NoError() && !self->CheckAbort(i,num,1) && iGetCurrentViewModuleIndex()) { self->GetErrorStatus()->Monitor(curAnimator->GetErrorStatus(),true); - if(!curAnimator->RenderImages()) self->GetErrorStatus()->Set("Animation finished.",-1); + if(!curAnimator->Frame()) self->GetErrorStatus()->Set("Animation finished.",-1); break; } diff -Nru ifrit-3.3.4/core/ianimatorscript.h ifrit-3.4.2/core/ianimatorscript.h --- ifrit-3.3.4/core/ianimatorscript.h 2011-01-27 17:51:04.000000000 +0000 +++ ifrit-3.4.2/core/ianimatorscript.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ianimatorscriptmacro.h ifrit-3.4.2/core/ianimatorscriptmacro.h --- ifrit-3.3.4/core/ianimatorscriptmacro.h 2011-01-27 17:51:04.000000000 +0000 +++ ifrit-3.4.2/core/ianimatorscriptmacro.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iappendpolydatafilter.cpp ifrit-3.4.2/core/iappendpolydatafilter.cpp --- ifrit-3.3.4/core/iappendpolydatafilter.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/iappendpolydatafilter.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iappendpolydatafilter.h ifrit-3.4.2/core/iappendpolydatafilter.h --- ifrit-3.3.4/core/iappendpolydatafilter.h 2011-01-27 17:51:05.000000000 +0000 +++ ifrit-3.4.2/core/iappendpolydatafilter.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iarray.h ifrit-3.4.2/core/iarray.h --- ifrit-3.3.4/core/iarray.h 2011-01-27 17:51:05.000000000 +0000 +++ ifrit-3.4.2/core/iarray.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iarraytemplate.h ifrit-3.4.2/core/iarraytemplate.h --- ifrit-3.3.4/core/iarraytemplate.h 2011-01-27 17:51:05.000000000 +0000 +++ ifrit-3.4.2/core/iarraytemplate.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iartifactcorrector.cpp ifrit-3.4.2/core/iartifactcorrector.cpp --- ifrit-3.3.4/core/iartifactcorrector.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/iartifactcorrector.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iartifactcorrector.h ifrit-3.4.2/core/iartifactcorrector.h --- ifrit-3.3.4/core/iartifactcorrector.h 2011-01-27 17:51:05.000000000 +0000 +++ ifrit-3.4.2/core/iartifactcorrector.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iaxis.cpp ifrit-3.4.2/core/iaxis.cpp --- ifrit-3.3.4/core/iaxis.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/iaxis.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iaxis.h ifrit-3.4.2/core/iaxis.h --- ifrit-3.3.4/core/iaxis.h 2011-01-27 17:51:05.000000000 +0000 +++ ifrit-3.4.2/core/iaxis.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibasicdatasubjects.cpp ifrit-3.4.2/core/ibasicdatasubjects.cpp --- ifrit-3.3.4/core/ibasicdatasubjects.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/ibasicdatasubjects.cpp 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -40,7 +40,7 @@ // // ******************************************************************** // -IFIELDDATASUBJECT_DEFINE_TYPE(iUniformScalarsDataSubject,1,"Uniform Scalars","us","basic,field,scalars","IFRIT_SCALAR_FIELD_DATA_DIR"); +IFIELDDATASUBJECT_DEFINE_TYPE(iUniformScalarsDataSubject,1,"Uniform Scalars","us",0,"basic,field,scalars","IFRIT_SCALAR_FIELD_DATA_DIR"); // // Inherited keys // @@ -88,7 +88,7 @@ // // ******************************************************************** // -IFIELDDATASUBJECT_DEFINE_TYPE(iUniformVectorsDataSubject,2,"Uniform Vectors","uv","basic,field","IFRIT_VECTOR_FIELD_DATA_DIR"); +IFIELDDATASUBJECT_DEFINE_TYPE(iUniformVectorsDataSubject,2,"Uniform Vectors","uv",1,"basic,field","IFRIT_VECTOR_FIELD_DATA_DIR"); // // Inherited keys // @@ -108,7 +108,7 @@ // // ******************************************************************** // -IFIELDDATASUBJECT_DEFINE_TYPE(iUniformTensorsDataSubject,3,"Uniform Tensors","ut","basic,field","IFRIT_TENSOR_FIELD_DATA_DIR"); +IFIELDDATASUBJECT_DEFINE_TYPE(iUniformTensorsDataSubject,3,"Uniform Tensors","ut",2,"basic,field","IFRIT_TENSOR_FIELD_DATA_DIR"); // // Inherited keys // diff -Nru ifrit-3.3.4/core/ibasicdatasubjects.h ifrit-3.4.2/core/ibasicdatasubjects.h --- ifrit-3.3.4/core/ibasicdatasubjects.h 2011-01-27 17:51:06.000000000 +0000 +++ ifrit-3.4.2/core/ibasicdatasubjects.h 2013-07-11 01:23:17.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibasicparticlesfileloader.cpp ifrit-3.4.2/core/ibasicparticlesfileloader.cpp --- ifrit-3.3.4/core/ibasicparticlesfileloader.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/ibasicparticlesfileloader.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibasicparticlesfileloader.h ifrit-3.4.2/core/ibasicparticlesfileloader.h --- ifrit-3.3.4/core/ibasicparticlesfileloader.h 2011-01-27 17:51:06.000000000 +0000 +++ ifrit-3.4.2/core/ibasicparticlesfileloader.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibasicscript.cpp ifrit-3.4.2/core/ibasicscript.cpp --- ifrit-3.3.4/core/ibasicscript.cpp 2011-01-27 17:51:37.000000000 +0000 +++ ifrit-3.4.2/core/ibasicscript.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibasicscript.h ifrit-3.4.2/core/ibasicscript.h --- ifrit-3.3.4/core/ibasicscript.h 2011-01-27 17:51:06.000000000 +0000 +++ ifrit-3.4.2/core/ibasicscript.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibitmaptextsubject.cpp ifrit-3.4.2/core/ibitmaptextsubject.cpp --- ifrit-3.3.4/core/ibitmaptextsubject.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/ibitmaptextsubject.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibitmaptextsubject.h ifrit-3.4.2/core/ibitmaptextsubject.h --- ifrit-3.3.4/core/ibitmaptextsubject.h 2011-01-27 17:51:06.000000000 +0000 +++ ifrit-3.4.2/core/ibitmaptextsubject.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundeddisksource.cpp ifrit-3.4.2/core/iboundeddisksource.cpp --- ifrit-3.3.4/core/iboundeddisksource.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/iboundeddisksource.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundeddisksource.h ifrit-3.4.2/core/iboundeddisksource.h --- ifrit-3.3.4/core/iboundeddisksource.h 2011-01-27 17:51:06.000000000 +0000 +++ ifrit-3.4.2/core/iboundeddisksource.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedplanesource.cpp ifrit-3.4.2/core/iboundedplanesource.cpp --- ifrit-3.3.4/core/iboundedplanesource.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/iboundedplanesource.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedplanesource.h ifrit-3.4.2/core/iboundedplanesource.h --- ifrit-3.3.4/core/iboundedplanesource.h 2011-01-27 17:51:07.000000000 +0000 +++ ifrit-3.4.2/core/iboundedplanesource.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedpolydatasource.cpp ifrit-3.4.2/core/iboundedpolydatasource.cpp --- ifrit-3.3.4/core/iboundedpolydatasource.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/iboundedpolydatasource.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedpolydatasource.h ifrit-3.4.2/core/iboundedpolydatasource.h --- ifrit-3.3.4/core/iboundedpolydatasource.h 2011-01-27 17:51:07.000000000 +0000 +++ ifrit-3.4.2/core/iboundedpolydatasource.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedspheresource.cpp ifrit-3.4.2/core/iboundedspheresource.cpp --- ifrit-3.3.4/core/iboundedspheresource.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/iboundedspheresource.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iboundedspheresource.h ifrit-3.4.2/core/iboundedspheresource.h --- ifrit-3.3.4/core/iboundedspheresource.h 2011-01-27 17:51:07.000000000 +0000 +++ ifrit-3.4.2/core/iboundedspheresource.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibuffer.h ifrit-3.4.2/core/ibuffer.h --- ifrit-3.3.4/core/ibuffer.h 2011-01-27 17:51:07.000000000 +0000 +++ ifrit-3.4.2/core/ibuffer.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ibuffertemplate.h ifrit-3.4.2/core/ibuffertemplate.h --- ifrit-3.3.4/core/ibuffertemplate.h 2011-01-27 17:51:07.000000000 +0000 +++ ifrit-3.4.2/core/ibuffertemplate.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icalculator.h ifrit-3.4.2/core/icalculator.h --- ifrit-3.3.4/core/icalculator.h 2011-01-27 17:51:08.000000000 +0000 +++ ifrit-3.4.2/core/icalculator.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -55,7 +55,7 @@ typedef iCalculatorKit::ptr real_ptr; typedef iCalculatorKit::ptr bool_ptr; - iCalculator(const iCalculatorBase *driver = 0); + iCalculator(); inline const result_t* GetResult() { return static_cast(this->Result()); } diff -Nru ifrit-3.3.4/core/icalculatorbase.cpp ifrit-3.4.2/core/icalculatorbase.cpp --- ifrit-3.3.4/core/icalculatorbase.cpp 2011-01-27 17:51:38.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorbase.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -43,14 +43,12 @@ using namespace iCalculatorKit; -iCalculatorBase::iCalculatorBase(const iCalculatorBase *driver) : mVariables(driver==0 ? mVariableData : driver->mVariables) +iCalculatorBase::iCalculatorBase() { mParser = 0; mErrorPosition = -1; - mTrapFPE = (driver == 0) ? false : driver->GetTrapFPE(); - - mAllowUndeterministicCalls = false; + mTrapFPE = false; mResult = 0; mStatus = 0; @@ -95,19 +93,6 @@ } -void iCalculatorBase::CopyVariables(const iCalculatorBase *other) -{ - if(other != 0) - { - int i; - for(i=0; imVariables.Size(); i++) - { - mVariableData.Add(other->mVariables[i]); // this insures the correct name scope resolution - } - } -} - - void iCalculatorBase::SetTrapFPE(bool s) { if(mTrapFPE != s) @@ -122,7 +107,7 @@ { if(var!=0 && !var->Name().IsEmpty()) { - mVariableData.Add(var); + mVariables.Add(var); } } @@ -132,11 +117,11 @@ if(!name.IsEmpty()) { int i; - for(i=mVariableData.MaxIndex(); i>=0; i--) // variables are always looped over in the reverse order to insure proper name resolution + for(i=mVariables.MaxIndex(); i>=0; i--) // variables are always looped over in the reverse order to insure proper name resolution { - if(mVariableData[i]->Name() == name) + if(mVariables[i]->Name() == name) { - mVariableData.Remove(i); + mVariables.Remove(i); return; // remove one at a time } } @@ -456,6 +441,31 @@ } +// +// This is for extending (used in scripts) +// +const Variable* iCalculatorBase::FindExternalVariable(const iString &) const +{ + return 0; +} + + +const Variable* iCalculatorBase::FindVariable(const iString &name) const +{ + int i; + + for(i=mVariables.MaxIndex(); i>=0; i--) // variables are always looped over in the reverse order to insure proper name resolution + { + if(mVariables[i]->Name() == name) return mVariables[i]; + } + + // + // If we don't own this variable, check external variables (used if we are used inside a script) + // + return this->FindExternalVariable(name); +} + + bool iCalculatorBase::Link() { if(mStatus < 1) @@ -473,11 +483,7 @@ const Variable *var; for(id=0; idSelf() == 0) { - var = 0; - for(i=mVariables.MaxIndex(); var==0 && i>=0; i--) // variables are always looped over in the reverse order to insure proper name resolution - { - if(mVariables[i]->Name() == mDataStack[id]->Name()) var = mVariables[i]; - } + var = this->FindVariable(mDataStack[id]->Name()); if(var == 0) { this->SetError("Link error: variable {"+mDataStack[id]->Name()+"} has not been defined.",-1); @@ -575,8 +581,6 @@ return false; } - if(mStatus==3 && !mAllowUndeterministicCalls && mVariables.Size()==0) return true; // the expression has not been changed, we dot not permit non-deterministic calls (like rand()), and we have no variables, so the result can not change - // // Create the run-time stack. // diff -Nru ifrit-3.3.4/core/icalculatorbase.h ifrit-3.4.2/core/icalculatorbase.h --- ifrit-3.3.4/core/icalculatorbase.h 2011-01-27 17:51:08.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorbase.h 2013-07-11 01:23:18.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -48,7 +48,7 @@ public: - iCalculatorBase(const iCalculatorBase *driver = 0); + iCalculatorBase(); virtual ~iCalculatorBase(); // @@ -77,11 +77,6 @@ inline const iString& ListUsedVariables() const { return mUsedVars; } // - // Useful for script work; has no effect if the driver argument was specified in the constructor - // - void CopyVariables(const iCalculatorBase *other); - - // // Floating-point exceptions // void SetTrapFPE(bool s); @@ -140,12 +135,12 @@ virtual iCalculatorKit::Variable* CreateLiteral(const iString &str) const = 0; virtual iCalculatorKit::Function* CreateFunction(const iString &str, int loc) const = 0; + virtual const iCalculatorKit::Variable* FindExternalVariable(const iString &name) const; + #ifdef I_DEBUG virtual void PrintStack(int iptr, int narg, int jmax, iCalculatorKit::Variable** stack) = 0; #endif - bool mAllowUndeterministicCalls; - private: void ReportRunTimeError(int ierr, const iCalculatorKit::Function *caller); @@ -153,6 +148,8 @@ bool CompileToken(int &index); bool CheckFunction(int index, int &stackptr); + const iCalculatorKit::Variable* FindVariable(const iString &name) const; + int mErrorPosition; iString mErrorMessage; @@ -167,10 +164,8 @@ iBuffer mBuffer, mSavedBuffer; // pre-allocated buffers to avoid memory allocation during execution - iArray mVariableData; - + iArray mVariables; iArray mLiterals; - const iArray &mVariables; }; #endif // ICALCULATORBASE_H diff -Nru ifrit-3.3.4/core/icalculatorkit.cpp ifrit-3.4.2/core/icalculatorkit.cpp --- ifrit-3.3.4/core/icalculatorkit.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorkit.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icalculatorkit.h ifrit-3.4.2/core/icalculatorkit.h --- ifrit-3.3.4/core/icalculatorkit.h 2011-01-27 17:51:08.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorkit.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icalculatorparser.cpp ifrit-3.4.2/core/icalculatorparser.cpp --- ifrit-3.3.4/core/icalculatorparser.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorparser.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icalculatorparser.h ifrit-3.4.2/core/icalculatorparser.h --- ifrit-3.3.4/core/icalculatorparser.h 2011-01-27 17:51:08.000000000 +0000 +++ ifrit-3.4.2/core/icalculatorparser.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icalculatortemplate.h ifrit-3.4.2/core/icalculatortemplate.h --- ifrit-3.3.4/core/icalculatortemplate.h 2011-01-27 17:51:08.000000000 +0000 +++ ifrit-3.4.2/core/icalculatortemplate.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -986,7 +986,7 @@ // ********************************************************************** // template -iCalculator::iCalculator(const iCalculatorBase *driver) : iCalculatorBase(driver) +iCalculator::iCalculator() : iCalculatorBase() { } diff -Nru ifrit-3.3.4/core/icamera.cpp ifrit-3.4.2/core/icamera.cpp --- ifrit-3.3.4/core/icamera.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icamera.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icamera.h ifrit-3.4.2/core/icamera.h --- ifrit-3.3.4/core/icamera.h 2011-01-27 17:51:09.000000000 +0000 +++ ifrit-3.4.2/core/icamera.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icameraorthoactor.cpp ifrit-3.4.2/core/icameraorthoactor.cpp --- ifrit-3.3.4/core/icameraorthoactor.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icameraorthoactor.cpp 2013-07-11 01:23:33.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icameraorthoactor.h ifrit-3.4.2/core/icameraorthoactor.h --- ifrit-3.3.4/core/icameraorthoactor.h 2011-01-27 17:51:09.000000000 +0000 +++ ifrit-3.4.2/core/icameraorthoactor.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icamerapath.cpp ifrit-3.4.2/core/icamerapath.cpp --- ifrit-3.3.4/core/icamerapath.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icamerapath.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icamerapath.h ifrit-3.4.2/core/icamerapath.h --- ifrit-3.3.4/core/icamerapath.h 2011-01-27 17:51:09.000000000 +0000 +++ ifrit-3.4.2/core/icamerapath.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icaption.cpp ifrit-3.4.2/core/icaption.cpp --- ifrit-3.3.4/core/icaption.cpp 2011-01-27 17:51:39.000000000 +0000 +++ ifrit-3.4.2/core/icaption.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icaption.h ifrit-3.4.2/core/icaption.h --- ifrit-3.3.4/core/icaption.h 2011-01-27 17:51:09.000000000 +0000 +++ ifrit-3.4.2/core/icaption.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icaptioninteractorstyle.cpp ifrit-3.4.2/core/icaptioninteractorstyle.cpp --- ifrit-3.3.4/core/icaptioninteractorstyle.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/icaptioninteractorstyle.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icaptioninteractorstyle.h ifrit-3.4.2/core/icaptioninteractorstyle.h --- ifrit-3.3.4/core/icaptioninteractorstyle.h 2011-01-27 17:51:09.000000000 +0000 +++ ifrit-3.4.2/core/icaptioninteractorstyle.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iclipplane.cpp ifrit-3.4.2/core/iclipplane.cpp --- ifrit-3.3.4/core/iclipplane.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/iclipplane.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iclipplane.h ifrit-3.4.2/core/iclipplane.h --- ifrit-3.3.4/core/iclipplane.h 2011-01-27 17:51:10.000000000 +0000 +++ ifrit-3.4.2/core/iclipplane.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icolor.cpp ifrit-3.4.2/core/icolor.cpp --- ifrit-3.3.4/core/icolor.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/icolor.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icolor.h ifrit-3.4.2/core/icolor.h --- ifrit-3.3.4/core/icolor.h 2011-01-27 17:51:10.000000000 +0000 +++ ifrit-3.4.2/core/icolor.h 2013-07-11 01:23:19.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icolorbars.cpp ifrit-3.4.2/core/icolorbars.cpp --- ifrit-3.3.4/core/icolorbars.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/icolorbars.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icolorbars.h ifrit-3.4.2/core/icolorbars.h --- ifrit-3.3.4/core/icolorbars.h 2011-01-27 17:51:10.000000000 +0000 +++ ifrit-3.4.2/core/icolorbars.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommandinterpreter.cpp ifrit-3.4.2/core/icommandinterpreter.cpp --- ifrit-3.3.4/core/icommandinterpreter.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/icommandinterpreter.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommandinterpreter.h ifrit-3.4.2/core/icommandinterpreter.h --- ifrit-3.3.4/core/icommandinterpreter.h 2011-01-27 17:51:10.000000000 +0000 +++ ifrit-3.4.2/core/icommandinterpreter.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommondatadistributors.cpp ifrit-3.4.2/core/icommondatadistributors.cpp --- ifrit-3.3.4/core/icommondatadistributors.cpp 2011-01-27 17:51:40.000000000 +0000 +++ ifrit-3.4.2/core/icommondatadistributors.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommondatadistributors.h ifrit-3.4.2/core/icommondatadistributors.h --- ifrit-3.3.4/core/icommondatadistributors.h 2011-01-27 17:51:10.000000000 +0000 +++ ifrit-3.4.2/core/icommondatadistributors.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommoneventobservers.cpp ifrit-3.4.2/core/icommoneventobservers.cpp --- ifrit-3.3.4/core/icommoneventobservers.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icommoneventobservers.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icommoneventobservers.h ifrit-3.4.2/core/icommoneventobservers.h --- ifrit-3.3.4/core/icommoneventobservers.h 2011-01-27 17:51:11.000000000 +0000 +++ ifrit-3.4.2/core/icommoneventobservers.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iconsole.cpp ifrit-3.4.2/core/iconsole.cpp --- ifrit-3.3.4/core/iconsole.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/iconsole.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iconsole.h ifrit-3.4.2/core/iconsole.h --- ifrit-3.3.4/core/iconsole.h 2011-01-27 17:51:11.000000000 +0000 +++ ifrit-3.4.2/core/iconsole.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icontourfilter.cpp ifrit-3.4.2/core/icontourfilter.cpp --- ifrit-3.3.4/core/icontourfilter.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icontourfilter.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icontourfilter.h ifrit-3.4.2/core/icontourfilter.h --- ifrit-3.3.4/core/icontourfilter.h 2011-01-27 17:51:11.000000000 +0000 +++ ifrit-3.4.2/core/icontourfilter.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icontrolmodule.cpp ifrit-3.4.2/core/icontrolmodule.cpp --- ifrit-3.3.4/core/icontrolmodule.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icontrolmodule.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -609,7 +609,7 @@ { this->GetErrorStatus()->Monitor(object->GetErrorStatus()); object->UnPackState(command); - mExecuteOk = object->UnPackedSomething(); + mExecuteOk = object->UnPackedSomething() && this->GetErrorStatus()->NoError(); if(renOption == RenderOption::Auto) renOption = RenderOption::One; if(ptype->IsMatch(iDataReader::Type()) || ptype->IsMatch(iDataSubject::Type())) diff -Nru ifrit-3.3.4/core/icontrolmodule.h ifrit-3.4.2/core/icontrolmodule.h --- ifrit-3.3.4/core/icontrolmodule.h 2011-01-27 17:51:11.000000000 +0000 +++ ifrit-3.4.2/core/icontrolmodule.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icontrolscript.cpp ifrit-3.4.2/core/icontrolscript.cpp --- ifrit-3.3.4/core/icontrolscript.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icontrolscript.cpp 2013-07-11 01:23:34.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -145,7 +145,7 @@ const iObjectType *tmp = iObjectTypeRegistry::FindType(arg); if(tmp != 0) { - curControl->Show(*tmp,true,curRender); + curControl->Show(*tmp,true,true); return true; } else @@ -390,7 +390,7 @@ } -iScriptKit::Calculator* iControlScript::CreateCalculator() +iScriptKit::Calculator* iControlScript::CreateCalculatorBody() { return new Calculator(this); } @@ -691,7 +691,8 @@ // if(w.EndsWith(iObjectKey::PrefixSeparator())) { - const iObjectType *type = iObjectTypeRegistry::FindType(w.Part(0,w.Length()-iObjectKey::PrefixSeparator().Length())); + w = w.Part(0,w.Length()-iObjectKey::PrefixSeparator().Length()); + const iObjectType *type = iObjectTypeRegistry::FindType(w); if(type != 0) { int i, lmax = 0; @@ -824,7 +825,6 @@ f.Close(); curVisual->GetAnimator()->GetScript()->SetText(st); - curVisual->GetAnimator()->SetUseScript(true); } if(arg == all) @@ -872,7 +872,6 @@ self->GetErrorStatus()->Monitor(curVisual->GetAnimator()->GetErrorStatus()); curVisual->GetAnimator()->GetScript()->SetText(v); - curVisual->GetAnimator()->SetUseScript(true); curScript->mAllowChildAccess = true; curVisual->GetAnimator()->Animate(); curScript->mAllowChildAccess = false; @@ -1126,7 +1125,7 @@ // "Format:
" " print <query>
" - "This command prints the value of <query>, which can be a script expression or a property in the form <object-name>:<property-name>. Use list objects to get the list of all available objects and list properties <object-name> to get the list of all available properties for a given object <object-name>.
", + "This command prints the value of <query>, which can be a script expression, a property in the form <object-name>:<property-name>, or the whole object <object-name>: (the semi-colon at the end is required, to separate an object from a regular variable). Use list objects to get the list of all available objects and list properties <object-name> to get the list of all available properties for a given object <object-name>.
", // "Format:
" " create <object-name>
" diff -Nru ifrit-3.3.4/core/icontrolscript.h ifrit-3.4.2/core/icontrolscript.h --- ifrit-3.3.4/core/icontrolscript.h 2011-01-27 17:51:11.000000000 +0000 +++ ifrit-3.4.2/core/icontrolscript.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -75,7 +75,7 @@ // // Factory method: replace the calculator with the one that understands key values // - virtual iScriptKit::Calculator* CreateCalculator(); + virtual iScriptKit::Calculator* CreateCalculatorBody(); // // Convert keys into calculator variables diff -Nru ifrit-3.3.4/core/icrosssectionpipeline.cpp ifrit-3.4.2/core/icrosssectionpipeline.cpp --- ifrit-3.3.4/core/icrosssectionpipeline.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icrosssectionpipeline.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icrosssectionpipeline.h ifrit-3.4.2/core/icrosssectionpipeline.h --- ifrit-3.3.4/core/icrosssectionpipeline.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/icrosssectionpipeline.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icrosssectionviewsubject.cpp ifrit-3.4.2/core/icrosssectionviewsubject.cpp --- ifrit-3.3.4/core/icrosssectionviewsubject.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icrosssectionviewsubject.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -377,7 +377,7 @@ { de->SetActiveDataType(this->GetDataType()); de->SetInputComponent(this->GetVar()); - const iDataExplorer::Info &di = de->GetInfo(true,0); + const iDataExplorer::Info &di = de->GetInfo(true); if(n == 0) { if(di.CellMin >= 0) this->SetPosition(*di.PosMin); diff -Nru ifrit-3.3.4/core/icrosssectionviewsubject.h ifrit-3.4.2/core/icrosssectionviewsubject.h --- ifrit-3.3.4/core/icrosssectionviewsubject.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/icrosssectionviewsubject.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icubeaxesactor.cpp ifrit-3.4.2/core/icubeaxesactor.cpp --- ifrit-3.3.4/core/icubeaxesactor.cpp 2011-01-27 17:51:41.000000000 +0000 +++ ifrit-3.4.2/core/icubeaxesactor.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/icubeaxesactor.h ifrit-3.4.2/core/icubeaxesactor.h --- ifrit-3.3.4/core/icubeaxesactor.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/icubeaxesactor.h 2013-07-11 01:23:20.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idata.cpp ifrit-3.4.2/core/idata.cpp --- ifrit-3.3.4/core/idata.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idata.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -65,7 +65,7 @@ // // DataType class // -iDataType::iDataType(int id, const iString& tname, const iString& sname, const iString &keywords, const iString &env) : mId(id), mTextName(tname), mShortName(sname), mKeywords(keywords) +iDataType::iDataType(int id, const iString& tname, const iString& sname, int rank, const iString &keywords, const iString &env) : mId(id), mTextName(tname), mShortName(sname), mRank(rank), mKeywords(keywords) { int i, n; @@ -286,7 +286,7 @@ // const iDataType& iDataType::Null() { - static const iDataType tmp(0,"Null","","",""); + static const iDataType tmp(0,"Null","",0,"",""); return tmp; } diff -Nru ifrit-3.3.4/core/idata.h ifrit-3.4.2/core/idata.h --- ifrit-3.3.4/core/idata.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/idata.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -55,7 +55,7 @@ static const iDataType& Null(); - iDataType(int id, const iString& tname, const iString& sname, const iString &keywords, const iString &environment = ""); + iDataType(int id, const iString& tname, const iString& sname, int rank, const iString &keywords, const iString &environment = ""); ~iDataType(); bool operator==(const iDataType &type) const; @@ -68,6 +68,8 @@ inline const iString& GetTextName() const { return mTextName; } inline const iString& GetShortName() const { return mShortName; } + inline int GetRank() const { return mRank; } + iString GetEnvironment(iShell *shell) const; inline bool IsOfType(const iString &name) const { return name==mName || name==mShortName; } @@ -79,7 +81,7 @@ private: - const int mId; + const int mId, mRank; const iString mTextName, mShortName, mKeywords; iString mName, mEnv; diff -Nru ifrit-3.3.4/core/idataconsumer.cpp ifrit-3.4.2/core/idataconsumer.cpp --- ifrit-3.3.4/core/idataconsumer.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idataconsumer.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idataconsumer.h ifrit-3.4.2/core/idataconsumer.h --- ifrit-3.3.4/core/idataconsumer.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/idataconsumer.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idataexplorer.cpp ifrit-3.4.2/core/idataexplorer.cpp --- ifrit-3.3.4/core/idataexplorer.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idataexplorer.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -30,7 +30,6 @@ #include "idata.h" -#include "idatahelper.h" #include "idatalimits.h" #include "idatareader.h" #include "idatasubject.h" @@ -106,7 +105,7 @@ } -const iDataExplorer::Info& iDataExplorer::GetInfo(bool rangeonly, int rank) +const iDataExplorer::Info& iDataExplorer::GetInfo(bool rangeonly, float start, float length) { if(mHistogramMaker == 0) { @@ -117,10 +116,10 @@ if(this->IsThereData()) { - iDataHelper h(this->GetData()); - mHistogramMaker->SetDataRank((rank == -1) ? h.GetDataRank() : rank); + mHistogramMaker->SetDataRank(this->GetDataType().GetRank()); mHistogramMaker->SetInput(this->GetData(),mComponent); mHistogramMaker->SetStretch(mStretch); + mHistogramMaker->SetProgressRange(start,length); mHistogramMaker->GetInput()->Update(); if(mHistogramMaker->GetInput()->GetMTime() > mMTime) { diff -Nru ifrit-3.3.4/core/idataexplorer.h ifrit-3.4.2/core/idataexplorer.h --- ifrit-3.3.4/core/idataexplorer.h 2011-01-27 17:51:12.000000000 +0000 +++ ifrit-3.4.2/core/idataexplorer.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -66,7 +66,7 @@ // // using a struct, only one Update is needed to bring everything up to date // - const Info& GetInfo(bool rangeonly = false, int rank = -1); + const Info& GetInfo(bool rangeonly = false, float start = 0.0, float length = 1.0); void SetStretch(int v); void SetInputComponent(int c); diff -Nru ifrit-3.3.4/core/idataformatter.cpp ifrit-3.4.2/core/idataformatter.cpp --- ifrit-3.3.4/core/idataformatter.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idataformatter.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -85,7 +85,7 @@ } -void iDataFormatter::FormatScalarData(iDataLimits *lim, int n, float *v, bool useClass) +void iDataFormatter::FormatScalarData(iDataLimits *lim, int n, float *v, bool useRank) { int i; iString s1, s2; @@ -94,14 +94,14 @@ float vlog; int maxLen = 0; - for(i=0; iGetClass(i)>=0) + for(i=0; iGetRank(i)==0) { s2 = iString::FromNumber(v[i],"%.3e"); if(maxLen < s2.Length()) maxLen = s2.Length(); } while(mFormatHelper.Length() < maxLen) mFormatHelper += " "; - for(i=0; iGetClass(i)>=0) + for(i=0; iGetRank(i)==0) { vlog = float(log10(1.0e-30+fabs(v[i]))); s2 = iString::FromNumber(v[i],"%.3e"); diff -Nru ifrit-3.3.4/core/idataformatter.h ifrit-3.4.2/core/idataformatter.h --- ifrit-3.3.4/core/idataformatter.h 2011-01-27 17:51:13.000000000 +0000 +++ ifrit-3.4.2/core/idataformatter.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -57,7 +57,7 @@ void AddOneLine(const iString &name, const iString &data, const iString &unit); void ClearReport(); - void FormatScalarData(iDataLimits *lim, int n, float *v, bool useClass = false); + void FormatScalarData(iDataLimits *lim, int n, float *v, bool useRank = false); void FormatVectorData(iDataLimits *lim, int ivar, float *v, float *div = 0, float *vort = 0); void FormatTensorData(iDataLimits *lim, int ivar, float *v, bool compressed = false); diff -Nru ifrit-3.3.4/core/idatahandler.cpp ifrit-3.4.2/core/idatahandler.cpp --- ifrit-3.3.4/core/idatahandler.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idatahandler.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatahandler.h ifrit-3.4.2/core/idatahandler.h --- ifrit-3.3.4/core/idatahandler.h 2011-01-27 17:51:13.000000000 +0000 +++ ifrit-3.4.2/core/idatahandler.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatahelper.cpp ifrit-3.4.2/core/idatahelper.cpp --- ifrit-3.3.4/core/idatahelper.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idatahelper.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatahelper.h ifrit-3.4.2/core/idatahelper.h --- ifrit-3.3.4/core/idatahelper.h 2011-01-27 17:51:13.000000000 +0000 +++ ifrit-3.4.2/core/idatahelper.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatalimits.cpp ifrit-3.4.2/core/idatalimits.cpp --- ifrit-3.3.4/core/idatalimits.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idatalimits.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -134,7 +134,7 @@ tmp.Min = 0.1f; tmp.Max = 10.0f; tmp.FixedStretch = false; - tmp.Class = 0; + tmp.Rank = 0; this->Initialize(tmp); mListedVars.Add(tmp); } diff -Nru ifrit-3.3.4/core/idatalimits.h ifrit-3.4.2/core/idatalimits.h --- ifrit-3.3.4/core/idatalimits.h 2011-01-27 17:51:13.000000000 +0000 +++ ifrit-3.4.2/core/idatalimits.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -62,7 +62,7 @@ const iString& GetName(int n) const; const iString& GetUnit(int n) const; bool GetFixedStretch(int n) const; - int GetClass(int n) const; + int GetRank(int n) const; const iString& GetNameForClass(int n) const; // GetClassName conflicts with something under VC++ void SetMax(int n, float v); @@ -113,7 +113,7 @@ bool Included, FixedStretch; float Min, Max; float LowerLimit, UpperLimit; - int Stretch, Class; + int Stretch, Rank; iString Name, Unit, ClassName; bool IsAtMin, IsAtMax; }; @@ -203,9 +203,9 @@ } -inline int iDataLimits::GetClass(int n) const +inline int iDataLimits::GetRank(int n) const { - if(n>=0 && nClass; else return this->Invalid(-1); + if(n>=0 && nRank; else return this->Invalid(-1); } diff -Nru ifrit-3.3.4/core/idatareader.cpp ifrit-3.4.2/core/idatareader.cpp --- ifrit-3.3.4/core/idatareader.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idatareader.cpp 2013-07-11 01:23:35.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatareader.h ifrit-3.4.2/core/idatareader.h --- ifrit-3.3.4/core/idatareader.h 2011-01-27 17:51:13.000000000 +0000 +++ ifrit-3.4.2/core/idatareader.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatastretch.cpp ifrit-3.4.2/core/idatastretch.cpp --- ifrit-3.3.4/core/idatastretch.cpp 2011-01-27 17:51:42.000000000 +0000 +++ ifrit-3.4.2/core/idatastretch.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatastretch.h ifrit-3.4.2/core/idatastretch.h --- ifrit-3.3.4/core/idatastretch.h 2011-01-27 17:51:14.000000000 +0000 +++ ifrit-3.4.2/core/idatastretch.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatasubject.cpp ifrit-3.4.2/core/idatasubject.cpp --- ifrit-3.3.4/core/idatasubject.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/idatasubject.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idatasubject.h ifrit-3.4.2/core/idatasubject.h --- ifrit-3.3.4/core/idatasubject.h 2011-01-27 17:51:14.000000000 +0000 +++ ifrit-3.4.2/core/idatasubject.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -148,10 +148,10 @@ virtual const iObjectType& GetObjectType() const; \ virtual const iDataType& GetDataType() const -#define IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_keywords_,_environment_) \ +#define IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_rank_,_keywords_,_environment_) \ const iDataType& _object_::DataType() \ { \ - static const iDataType tmp(_id_,_fname_,_sname_,_keywords_,_environment_); \ + static const iDataType tmp(_id_,_fname_,_sname_,_rank_,_keywords_,_environment_); \ return tmp; \ } \ const iObjectType& _object_::Type() \ @@ -188,8 +188,8 @@ IDATASUBJECT_DECLARE_INHERITED_MEMBERS; \ } -#define IDATASUBJECT_DEFINE_CLASS(_prefix_,_name_,_fname_,_sname_,_keywords_,_environment_) \ -IDATASUBJECT_DEFINE_TYPE(_prefix_##_name_##DataSubject,_prefix_##Extension::SubjectId(),_fname_,_sname_,_keywords_,_environment_); \ +#define IDATASUBJECT_DEFINE_CLASS(_prefix_,_name_,_fname_,_sname_,_rank_,_keywords_,_environment_) \ +IDATASUBJECT_DEFINE_TYPE(_prefix_##_name_##DataSubject,_prefix_##Extension::SubjectId(),_fname_,_sname_,_rank_,_keywords_,_environment_); \ IDATASUBJECT_DEFINE_INHERITED_KEYS(_prefix_##_name_##DataSubject); \ _prefix_##_name_##DataSubject::_prefix_##_name_##DataSubject(iFileLoader *fl) : iDataSubject(fl,_prefix_##_name_##DataSubject::Type().FullName()){} diff -Nru ifrit-3.3.4/core/idirectory.cpp ifrit-3.4.2/core/idirectory.cpp --- ifrit-3.3.4/core/idirectory.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/idirectory.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/idirectory.h ifrit-3.4.2/core/idirectory.h --- ifrit-3.3.4/core/idirectory.h 2011-01-27 17:51:14.000000000 +0000 +++ ifrit-3.4.2/core/idirectory.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ierror.h ifrit-3.4.2/core/ierror.h --- ifrit-3.3.4/core/ierror.h 2011-01-27 17:51:14.000000000 +0000 +++ ifrit-3.4.2/core/ierror.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ierrorstatus.cpp ifrit-3.4.2/core/ierrorstatus.cpp --- ifrit-3.3.4/core/ierrorstatus.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/ierrorstatus.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ierrorstatus.h ifrit-3.4.2/core/ierrorstatus.h --- ifrit-3.3.4/core/ierrorstatus.h 2011-01-27 17:51:14.000000000 +0000 +++ ifrit-3.4.2/core/ierrorstatus.h 2013-07-11 01:23:21.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ieventobserver.cpp ifrit-3.4.2/core/ieventobserver.cpp --- ifrit-3.3.4/core/ieventobserver.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/ieventobserver.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ieventobserver.h ifrit-3.4.2/core/ieventobserver.h --- ifrit-3.3.4/core/ieventobserver.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/ieventobserver.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iextendableobject.cpp ifrit-3.4.2/core/iextendableobject.cpp --- ifrit-3.3.4/core/iextendableobject.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/iextendableobject.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iextendableobject.h ifrit-3.4.2/core/iextendableobject.h --- ifrit-3.3.4/core/iextendableobject.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/iextendableobject.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifamily.h ifrit-3.4.2/core/ifamily.h --- ifrit-3.3.4/core/ifamily.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/ifamily.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifamilytemplate.h ifrit-3.4.2/core/ifamilytemplate.h --- ifrit-3.3.4/core/ifamilytemplate.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/ifamilytemplate.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifielddatasubject.cpp ifrit-3.4.2/core/ifielddatasubject.cpp --- ifrit-3.3.4/core/ifielddatasubject.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/ifielddatasubject.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifielddatasubject.h ifrit-3.4.2/core/ifielddatasubject.h --- ifrit-3.3.4/core/ifielddatasubject.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/ifielddatasubject.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -74,8 +74,8 @@ #define IFIELDDATASUBJECT_DECLARE_INHERITED_KEYS \ IDATASUBJECT_DECLARE_INHERITED_KEYS -#define IFIELDDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_keywords_,_environment_) \ - IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_keywords_,_environment_) +#define IFIELDDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_rank_,_keywords_,_environment_) \ + IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_rank_,_keywords_,_environment_) #define IFIELDDATASUBJECT_DEFINE_INHERITED_KEYS(_type_) \ IDATASUBJECT_DEFINE_INHERITED_KEYS(_type_) @@ -90,8 +90,8 @@ IFIELDDATASUBJECT_DECLARE_INHERITED_MEMBERS; \ } -#define IFIELDDATASUBJECT_DEFINE_CLASS(_prefix_,_name_,_fname_,_sname_,_keywords_,_environment_) \ -IFIELDDATASUBJECT_DEFINE_TYPE(_prefix_##_name_##DataSubject,_prefix_##Extension::SubjectId(),_fname_,_sname_,_keywords_,_environment_); \ +#define IFIELDDATASUBJECT_DEFINE_CLASS(_prefix_,_name_,_fname_,_sname_,_rank_,_keywords_,_environment_) \ +IFIELDDATASUBJECT_DEFINE_TYPE(_prefix_##_name_##DataSubject,_prefix_##Extension::SubjectId(),_fname_,_sname_,_rank_,_keywords_,_environment_); \ IFIELDDATASUBJECT_DEFINE_INHERITED_KEYS(_prefix_##_name_##DataSubject); \ _prefix_##_name_##DataSubject::_prefix_##_name_##DataSubject(iFieldFileLoader *fl) : iFieldDataSubject(fl,_prefix_##_name_##DataSubject::Type().FullName()){} diff -Nru ifrit-3.3.4/core/ifieldfileloader.cpp ifrit-3.4.2/core/ifieldfileloader.cpp --- ifrit-3.3.4/core/ifieldfileloader.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/ifieldfileloader.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifieldfileloader.h ifrit-3.4.2/core/ifieldfileloader.h --- ifrit-3.3.4/core/ifieldfileloader.h 2011-01-27 17:51:15.000000000 +0000 +++ ifrit-3.4.2/core/ifieldfileloader.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifieldviewsubject.cpp ifrit-3.4.2/core/ifieldviewsubject.cpp --- ifrit-3.3.4/core/ifieldviewsubject.cpp 2011-01-27 17:51:43.000000000 +0000 +++ ifrit-3.4.2/core/ifieldviewsubject.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifieldviewsubject.h ifrit-3.4.2/core/ifieldviewsubject.h --- ifrit-3.3.4/core/ifieldviewsubject.h 2011-01-27 17:51:16.000000000 +0000 +++ ifrit-3.4.2/core/ifieldviewsubject.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifile.cpp ifrit-3.4.2/core/ifile.cpp --- ifrit-3.3.4/core/ifile.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/ifile.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -66,15 +66,15 @@ { mName = n; mStream = new fstream(); IERROR_ASSERT(mStream); - mMaxMarker = 100; + mMaxMarker = 0; mNumMarker = 0; - mMarker = new iFilePosition[mMaxMarker]; IERROR_ASSERT(mMarker); + mMarker = 0; } iFile::~iFile() { delete mStream; - delete mMarker; + if(mMarker != 0) delete mMarker; } @@ -232,11 +232,11 @@ { mMaxMarker += 100; iFilePosition *tmp = new iFilePosition[mMaxMarker]; IERROR_ASSERT(tmp); - for(int i=0; itellg(); diff -Nru ifrit-3.3.4/core/ifile.h ifrit-3.4.2/core/ifile.h --- ifrit-3.3.4/core/ifile.h 2011-01-27 17:51:16.000000000 +0000 +++ ifrit-3.4.2/core/ifile.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -95,6 +95,8 @@ static bool IsReadable(const iString &name); static bool IsWritable(const iString &name); + inline const iString& GetName() const { return mName; } + private: fstream *mStream; diff -Nru ifrit-3.3.4/core/ifileloader.cpp ifrit-3.4.2/core/ifileloader.cpp --- ifrit-3.3.4/core/ifileloader.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/ifileloader.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifileloader.h ifrit-3.4.2/core/ifileloader.h --- ifrit-3.3.4/core/ifileloader.h 2011-01-27 17:51:16.000000000 +0000 +++ ifrit-3.4.2/core/ifileloader.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iflipnormalsfilter.cpp ifrit-3.4.2/core/iflipnormalsfilter.cpp --- ifrit-3.3.4/core/iflipnormalsfilter.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/iflipnormalsfilter.cpp 2013-07-11 01:23:36.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iflipnormalsfilter.h ifrit-3.4.2/core/iflipnormalsfilter.h --- ifrit-3.3.4/core/iflipnormalsfilter.h 2011-01-27 17:51:16.000000000 +0000 +++ ifrit-3.4.2/core/iflipnormalsfilter.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iframedtextactor.cpp ifrit-3.4.2/core/iframedtextactor.cpp --- ifrit-3.3.4/core/iframedtextactor.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/iframedtextactor.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iframedtextactor.h ifrit-3.4.2/core/iframedtextactor.h --- ifrit-3.3.4/core/iframedtextactor.h 2011-01-27 17:51:16.000000000 +0000 +++ ifrit-3.4.2/core/iframedtextactor.h 2013-07-11 01:23:22.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifunctionmapping.cpp ifrit-3.4.2/core/ifunctionmapping.cpp --- ifrit-3.3.4/core/ifunctionmapping.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/ifunctionmapping.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ifunctionmapping.h ifrit-3.4.2/core/ifunctionmapping.h --- ifrit-3.3.4/core/ifunctionmapping.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/ifunctionmapping.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/igenericfilter.h ifrit-3.4.2/core/igenericfilter.h --- ifrit-3.3.4/core/igenericfilter.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/igenericfilter.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/igenericfiltertemplate.h ifrit-3.4.2/core/igenericfiltertemplate.h --- ifrit-3.3.4/core/igenericfiltertemplate.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/igenericfiltertemplate.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/igenericprop.h ifrit-3.4.2/core/igenericprop.h --- ifrit-3.3.4/core/igenericprop.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/igenericprop.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/igenericproptemplate.h ifrit-3.4.2/core/igenericproptemplate.h --- ifrit-3.3.4/core/igenericproptemplate.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/igenericproptemplate.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ihistogram.cpp ifrit-3.4.2/core/ihistogram.cpp --- ifrit-3.3.4/core/ihistogram.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/ihistogram.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ihistogram.h ifrit-3.4.2/core/ihistogram.h --- ifrit-3.3.4/core/ihistogram.h 2011-01-27 17:51:17.000000000 +0000 +++ ifrit-3.4.2/core/ihistogram.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ihistogrammaker.cpp ifrit-3.4.2/core/ihistogrammaker.cpp --- ifrit-3.3.4/core/ihistogrammaker.cpp 2011-01-27 17:51:44.000000000 +0000 +++ ifrit-3.4.2/core/ihistogrammaker.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -61,13 +61,16 @@ mNumProcs = mNumBins = 0; - mDataRank = 0U; + mDataRank = 0; mFullResolution = mSupportsFullResolution = false; mRanges = 0; mValues = 0; mComponent = -1; + mProgressStart = 0.0; + mProgressLength = 1.0; + mAttached = true; this->SetNumberOfInputConnections(0,1); @@ -80,7 +83,7 @@ iHistogramMaker::~iHistogramMaker() { - if(mAttached) mHisto->Delete();; + if(mAttached) mHisto->Delete(); if(mRanges != 0) { delete [] mRanges; @@ -131,9 +134,9 @@ } -void iHistogramMaker::SetDataRank(unsigned int r) +void iHistogramMaker::SetDataRank(int r) { - if(r<=2U && r!=mDataRank) + if(r>=0 && r<=2 && r!=mDataRank) { mDataRank = r; this->Modified(); @@ -172,6 +175,14 @@ } +void iHistogramMaker::SetProgressRange(float start, float length) +{ + if(start>=0.0 && start<1.0) mProgressStart = start; + if(length > 0.0) mProgressLength = length; + + if(mProgressStart+mProgressLength > 1.0) mProgressLength = 1.0 - mProgressStart; + +} void iHistogramMaker::Update() { // @@ -190,11 +201,6 @@ // if(this->GetInput()->GetMTime()>mComputeRangeTime || this->GetMTime()>mComputeRangeTime) { - // - // Must recompute - // - mComputeRangeTime.Modified(); - // // Recompute the limits // @@ -251,6 +257,11 @@ if(mHisto->mValMin < 0) mHisto->mValMin *= 1.001; else mHisto->mValMin *= 0.999; if(mHisto->mValMax < 0) mHisto->mValMax *= 0.999; else mHisto->mValMax *= 1.001; } + + // + // Update the time + // + mComputeRangeTime.Modified(); } return true; @@ -313,11 +324,6 @@ } // - // Must recompute - // - mComputeTime.Modified(); - - // // Check if we need to re-create the helper data // if(mNumProcs!=this->GetManager()->GetNumberOfProcessors() || nBins!=mNumBins) @@ -367,6 +373,11 @@ mHisto->SetData(mNumBins,tmp); delete [] tmp; + // + // Update the time + // + mComputeTime.Modified(); + return mHisto; } @@ -419,7 +430,7 @@ { if(mFullResolution && this->IsMaster(p)) { - double p = double(l-lbeg)/(lend-lbeg); + double p = mProgressStart + 0.2*mProgressLength*double(l-lbeg)/(lend-lbeg); this->InvokeEvent(vtkCommand::ProgressEvent,&p); } if(this->GetAbortExecute()) break; @@ -466,7 +477,7 @@ { if(mFullResolution && this->IsMaster(p)) { - double p = double(l-lbeg)/(lend-lbeg); + double p = mProgressStart + 0.2*mProgressLength + 0.8*mProgressLength*double(l-lbeg)/(lend-lbeg); this->InvokeEvent(vtkCommand::ProgressEvent,&p); } if(this->GetAbortExecute()) break; @@ -549,17 +560,17 @@ switch(mDataRank) { - case 0U: + case 0: { if(input->GetPointData()->GetScalars() == 0) return false; break; } - case 1U: + case 1: { if(input->GetPointData()->GetVectors() == 0) return false; break; } - case 2U: + case 2: { if(input->GetPointData()->GetTensors() == 0) return false; break; @@ -582,7 +593,7 @@ wDataPtr = 0; switch(mDataRank) { - case 0U: + case 0: { if(input->GetPointData()->GetScalars() == 0) return false; // @@ -595,7 +606,7 @@ if(mComponent<0 || mComponent>=wNumCom) return false; break; } - case 1U: + case 1: { if(input->GetPointData()->GetVectors() == 0) return false; // @@ -608,7 +619,7 @@ if(mComponent!=0 || wNumCom!=3) return false; break; } - case 2U: + case 2: { if(input->GetPointData()->GetTensors() == 0) return false; // diff -Nru ifrit-3.3.4/core/ihistogrammaker.h ifrit-3.4.2/core/ihistogrammaker.h --- ifrit-3.3.4/core/ihistogrammaker.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/ihistogrammaker.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -70,10 +70,12 @@ virtual void SetInputComponent(int c); virtual vtkDataSet* GetInput(); + void SetProgressRange(float start, float length); + void AttachHistogram(bool s); - void SetDataRank(unsigned int r); - inline unsigned int GetDataRank() const { return mDataRank; } + void SetDataRank(int r); + inline int GetDataRank() const { return mDataRank; } void Update(); @@ -112,7 +114,8 @@ bool mAttached, mFullResolution, mSupportsFullResolution; iHistogram *mHisto; int mNumProcs, mNumBins; - unsigned int mDataRank; + int mDataRank; + float mProgressStart, mProgressLength; // // MTime for the last calculation of the histogram - need to keep track of it diff -Nru ifrit-3.3.4/core/iidentityfilter.cpp ifrit-3.4.2/core/iidentityfilter.cpp --- ifrit-3.3.4/core/iidentityfilter.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/iidentityfilter.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iidentityfilter.h ifrit-3.4.2/core/iidentityfilter.h --- ifrit-3.3.4/core/iidentityfilter.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/iidentityfilter.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimage.cpp ifrit-3.4.2/core/iimage.cpp --- ifrit-3.3.4/core/iimage.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/iimage.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimage.h ifrit-3.4.2/core/iimage.h --- ifrit-3.3.4/core/iimage.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/iimage.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimagecomposer.cpp ifrit-3.4.2/core/iimagecomposer.cpp --- ifrit-3.3.4/core/iimagecomposer.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/iimagecomposer.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimagecomposer.h ifrit-3.4.2/core/iimagecomposer.h --- ifrit-3.3.4/core/iimagecomposer.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/iimagecomposer.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimagecomposerwindows.cpp ifrit-3.4.2/core/iimagecomposerwindows.cpp --- ifrit-3.3.4/core/iimagecomposerwindows.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/iimagecomposerwindows.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iimagecomposerwindows.h ifrit-3.4.2/core/iimagecomposerwindows.h --- ifrit-3.3.4/core/iimagecomposerwindows.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/iimagecomposerwindows.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ikeyboardinteractorstyle.cpp ifrit-3.4.2/core/ikeyboardinteractorstyle.cpp --- ifrit-3.3.4/core/ikeyboardinteractorstyle.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/ikeyboardinteractorstyle.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ikeyboardinteractorstyle.h ifrit-3.4.2/core/ikeyboardinteractorstyle.h --- ifrit-3.3.4/core/ikeyboardinteractorstyle.h 2011-01-27 17:51:18.000000000 +0000 +++ ifrit-3.4.2/core/ikeyboardinteractorstyle.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilegend.cpp ifrit-3.4.2/core/ilegend.cpp --- ifrit-3.3.4/core/ilegend.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/ilegend.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilegend.h ifrit-3.4.2/core/ilegend.h --- ifrit-3.3.4/core/ilegend.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/ilegend.h 2013-07-11 01:23:23.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilightkit.cpp ifrit-3.4.2/core/ilightkit.cpp --- ifrit-3.3.4/core/ilightkit.cpp 2011-01-27 17:51:45.000000000 +0000 +++ ifrit-3.4.2/core/ilightkit.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilightkit.h ifrit-3.4.2/core/ilightkit.h --- ifrit-3.3.4/core/ilightkit.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/ilightkit.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilinetobandfilter.cpp ifrit-3.4.2/core/ilinetobandfilter.cpp --- ifrit-3.3.4/core/ilinetobandfilter.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/ilinetobandfilter.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilinetobandfilter.h ifrit-3.4.2/core/ilinetobandfilter.h --- ifrit-3.3.4/core/ilinetobandfilter.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/ilinetobandfilter.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilinetotubefilter.cpp ifrit-3.4.2/core/ilinetotubefilter.cpp --- ifrit-3.3.4/core/ilinetotubefilter.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/ilinetotubefilter.cpp 2013-07-11 01:23:37.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilinetotubefilter.h ifrit-3.4.2/core/ilinetotubefilter.h --- ifrit-3.3.4/core/ilinetotubefilter.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/ilinetotubefilter.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilookuptable.cpp ifrit-3.4.2/core/ilookuptable.cpp --- ifrit-3.3.4/core/ilookuptable.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/ilookuptable.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ilookuptable.h ifrit-3.4.2/core/ilookuptable.h --- ifrit-3.3.4/core/ilookuptable.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/ilookuptable.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imagnifier.cpp ifrit-3.4.2/core/imagnifier.cpp --- ifrit-3.3.4/core/imagnifier.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/imagnifier.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imagnifier.h ifrit-3.4.2/core/imagnifier.h --- ifrit-3.3.4/core/imagnifier.h 2011-01-27 17:51:19.000000000 +0000 +++ ifrit-3.4.2/core/imagnifier.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imarker.cpp ifrit-3.4.2/core/imarker.cpp --- ifrit-3.3.4/core/imarker.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/imarker.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imarker.h ifrit-3.4.2/core/imarker.h --- ifrit-3.3.4/core/imarker.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imarker.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imarkerfamily.cpp ifrit-3.4.2/core/imarkerfamily.cpp --- ifrit-3.3.4/core/imarkerfamily.cpp 2011-01-27 17:51:46.000000000 +0000 +++ ifrit-3.4.2/core/imarkerfamily.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imarkerfamily.h ifrit-3.4.2/core/imarkerfamily.h --- ifrit-3.3.4/core/imarkerfamily.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imarkerfamily.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imath.cpp ifrit-3.4.2/core/imath.cpp --- ifrit-3.3.4/core/imath.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/imath.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imath.h ifrit-3.4.2/core/imath.h --- ifrit-3.3.4/core/imath.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imath.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imeasuringbox.cpp ifrit-3.4.2/core/imeasuringbox.cpp --- ifrit-3.3.4/core/imeasuringbox.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/imeasuringbox.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imeasuringbox.h ifrit-3.4.2/core/imeasuringbox.h --- ifrit-3.3.4/core/imeasuringbox.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imeasuringbox.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imergedatafilter.cpp ifrit-3.4.2/core/imergedatafilter.cpp --- ifrit-3.3.4/core/imergedatafilter.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/imergedatafilter.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imergedatafilter.h ifrit-3.4.2/core/imergedatafilter.h --- ifrit-3.3.4/core/imergedatafilter.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imergedatafilter.h 2013-07-11 01:23:24.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imultitypedataconsumer.cpp ifrit-3.4.2/core/imultitypedataconsumer.cpp --- ifrit-3.3.4/core/imultitypedataconsumer.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/imultitypedataconsumer.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/imultitypedataconsumer.h ifrit-3.4.2/core/imultitypedataconsumer.h --- ifrit-3.3.4/core/imultitypedataconsumer.h 2011-01-27 17:51:20.000000000 +0000 +++ ifrit-3.4.2/core/imultitypedataconsumer.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iobject.cpp ifrit-3.4.2/core/iobject.cpp --- ifrit-3.3.4/core/iobject.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/iobject.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -996,7 +996,10 @@ { v[i] = (tmp.Section(key.FieldSeparator(),i+1-i1,i+1-i1).ToInt(ok) != 0); } - if(ok) memcpy(val+i1,v+i1,(i2-i1)*sizeof(bool)); else IERROR_LOW("Invalid key value."); + if(ok) memcpy(val+i1,v+i1,(i2-i1)*sizeof(bool)); else + { + IERROR_LOW("Invalid key value."); + } delete [] v; } else ok = false; diff -Nru ifrit-3.3.4/core/iobject.h ifrit-3.4.2/core/iobject.h --- ifrit-3.3.4/core/iobject.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/iobject.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -399,6 +399,14 @@ if(opengl) return *ogl; else return *__p##_object_##_fkey_##Double; \ } +#define IOBJECT_DEFINE_EXTRINSIC_DISTANCE_KEY(_owner_,_object_,_prefix_,_fkey_,_skey_) \ + static const iObjectKey *__p##_object_##_fkey_##Double = iObjectKeyRegistry::CreateKey(_owner_::Type(),#_prefix_"-"#_fkey_,#_skey_,iObjectKey::_Double,1); \ + const iObjectKey& _object_::Key##_fkey_(bool opengl) \ + { \ + static const iObjectKey *ogl = iObjectKeyRegistry::CreateKey(_owner_::Type(),#_prefix_"-"#_fkey_"GL","-"#_skey_,iObjectKey::_Double,1,0,__p##_object_##_fkey_##Double); \ + if(opengl) return *ogl; else return *__p##_object_##_fkey_##Double; \ + } + #define IOBJECT_DEFINE_INHERITED_DISTANCE_KEY(_parent_,_object_,_fkey_,_skey_) \ static const iObjectKey *__p##_object_##_fkey_##Double = iObjectKeyRegistry::CreateKey(_object_::Type(),#_fkey_,#_skey_,iObjectKey::_Double,1,&_parent_::Type()); \ const iObjectKey& _object_::Key##_fkey_(bool opengl) \ @@ -415,6 +423,14 @@ if(opengl) return *ogl; else return *__p##_object_##_fkey_##Double; \ } +#define IOBJECT_DEFINE_EXTRINSIC_POSITION_KEY(_owner_,_object_,_prefix_,_fkey_,_skey_) \ + static const iObjectKey *__p##_object_##_fkey_##Double = iObjectKeyRegistry::CreateKey(_owner_::Type(),#_prefix_"-"#_fkey_,#_skey_,iObjectKey::_Double,3); \ + const iObjectKey& _object_::Key##_fkey_(bool opengl) \ + { \ + static const iObjectKey *ogl = iObjectKeyRegistry::CreateKey(_owner_::Type(),#_prefix_"-"#_fkey_"GL","-"#_skey_,iObjectKey::_Double,3,0,__p##_object_##_fkey_##Double); \ + if(opengl) return *ogl; else return *__p##_object_##_fkey_##Double; \ + } + #define IOBJECT_DEFINE_INHERITED_POSITION_KEY(_parent_,_object_,_fkey_,_skey_) \ static const iObjectKey *__p##_object_##_fkey_##Double = iObjectKeyRegistry::CreateKey(_object_::Type(),#_fkey_,#_skey_,iObjectKey::_Double,3,&_parent_::Type()); \ const iObjectKey& _object_::Key##_fkey_(bool opengl) \ diff -Nru ifrit-3.3.4/core/iobjectfactory.cpp ifrit-3.4.2/core/iobjectfactory.cpp --- ifrit-3.3.4/core/iobjectfactory.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/iobjectfactory.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iobjectfactory.h ifrit-3.4.2/core/iobjectfactory.h --- ifrit-3.3.4/core/iobjectfactory.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/iobjectfactory.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iobjecthelp.cpp ifrit-3.4.2/core/iobjecthelp.cpp --- ifrit-3.3.4/core/iobjecthelp.cpp 2011-01-27 17:51:47.000000000 +0000 +++ ifrit-3.4.2/core/iobjecthelp.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iobjecthelp.h ifrit-3.4.2/core/iobjecthelp.h --- ifrit-3.3.4/core/iobjecthelp.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/iobjecthelp.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioptimizepolydatafilter.cpp ifrit-3.4.2/core/ioptimizepolydatafilter.cpp --- ifrit-3.3.4/core/ioptimizepolydatafilter.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/ioptimizepolydatafilter.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioptimizepolydatafilter.h ifrit-3.4.2/core/ioptimizepolydatafilter.h --- ifrit-3.3.4/core/ioptimizepolydatafilter.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/ioptimizepolydatafilter.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iorthopolygonplanefilter.cpp ifrit-3.4.2/core/iorthopolygonplanefilter.cpp --- ifrit-3.3.4/core/iorthopolygonplanefilter.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/iorthopolygonplanefilter.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iorthopolygonplanefilter.h ifrit-3.4.2/core/iorthopolygonplanefilter.h --- ifrit-3.3.4/core/iorthopolygonplanefilter.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/iorthopolygonplanefilter.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iorthoslicer.cpp ifrit-3.4.2/core/iorthoslicer.cpp --- ifrit-3.3.4/core/iorthoslicer.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/iorthoslicer.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -175,32 +175,36 @@ // int ijk[3], ijk1[3], ijk2[3]; float ht = (mPos[mDir]-orgIn[mDir])/spaIn[mDir]; //Normalized height - if(input->GetVoxelLocation() == VoxelLocation::Center) ht -= 0.5; - ijk[mDir] = int(ht); //Grid Point below - if(ht < ijk[mDir]) ijk[mDir]--; - float ss1, ss2 = (ht-ijk[mDir]); //interpolation factor // - // Add a little bit of a cushion + // Must do that for parallel work // - if(ijk[mDir]==-1 && ss2>0.99) + if(ht<-0.01 || ht>numCellsIn[mDir]+0.01) { - ijk[mDir] = 0; - ss2 = 0.0; + return; } + + if(input->GetVoxelLocation() == VoxelLocation::Center) ht -= 0.5; + + // + // Add a little bit of a cushion + // + if(ht < 0.01) ht = 0.01; + if(ht > numCellsIn[mDir]-0.01) ht = numCellsIn[mDir] - 0.01; + + ijk1[mDir] = ijk2[mDir] = int(ht); //Grid Point below + if(ijk2[mDir] < dimsIn[mDir]-1) ijk2[mDir]++; - if(ijk[mDir]==numCellsIn[mDir] && ss2<0.01) +#ifdef I_CHECK1 + if(ijk1[mDir]<0 || ijk2[mDir]>=dimsIn[mDir]) { - ijk[mDir] = numCellsIn[mDir] - 1; - ss2 = 1.0; + IERROR_REPORT_BUG; } - ss1 = 1.0 - ss2; +#endif + + float ss2 = ht - ijk1[mDir]; + float ss1 = 1.0 - ss2; - // - // Must do that for parallel work - // - if(ijk[mDir]<0 || ijk[mDir]>=numCellsIn[mDir]) return; - output->SetDimensions(dimsOut); output->SetOrigin(orgOut); output->SetSpacing(spaOut); @@ -214,9 +218,6 @@ wScalarPtrIn += mCurVar; vtkIdType loffOut, loffIn1, loffIn2; - - ijk1[mDir] = ijk[mDir]; - ijk2[mDir] = ijk[mDir] + 1; for(ijk[v]=0; ijk[v]UpdateProgress((float)ijk[v]/dimsOut[v]); diff -Nru ifrit-3.3.4/core/iorthoslicer.h ifrit-3.4.2/core/iorthoslicer.h --- ifrit-3.3.4/core/iorthoslicer.h 2011-01-27 17:51:21.000000000 +0000 +++ ifrit-3.4.2/core/iorthoslicer.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iorthotextureplanefilter.cpp ifrit-3.4.2/core/iorthotextureplanefilter.cpp --- ifrit-3.3.4/core/iorthotextureplanefilter.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/iorthotextureplanefilter.cpp 2013-07-11 01:23:38.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -148,7 +148,7 @@ // if(mOffX==0 && mOffY==0) { - float tc[2]; + float tc[2], pad; static vtkIdType pts[4]={0,1,2,3}; int dimU, dimV; @@ -156,11 +156,13 @@ { dimU = mGlobalDims[u] - 1; dimV = mGlobalDims[v] - 1; + pad = 0.0; } else { - dimU = mGlobalDims[u]; - dimV = mGlobalDims[v]; + dimU = mGlobalDims[u] - 1; + dimV = mGlobalDims[v] - 1; + pad = 0.5; } // // We'll create the building blocks of polydata including data attributes. @@ -191,8 +193,8 @@ // // LL point // - x1[u] = mGlobalOrg[u]; - x1[v] = mGlobalOrg[v]; + x1[u] = mGlobalOrg[u] - pad*spa[u]; + x1[v] = mGlobalOrg[v] - pad*spa[v]; points->SetPoint(0,x1); tc[0] = 0.0; tc[1] = 0.0; @@ -200,8 +202,8 @@ // // LR point // - x1[u] = mGlobalOrg[u] + spa[u]*dimU; - x1[v] = mGlobalOrg[v]; + x1[u] = mGlobalOrg[u] - pad*spa[u] + spa[u]*dimU; + x1[v] = mGlobalOrg[v] - pad*spa[v]; points->SetPoint(1,x1); tc[0] = float(dimU)/dimsTexture[0]; tc[1] = 0.0; @@ -209,8 +211,8 @@ // // UR point // - x1[u] = mGlobalOrg[u] + spa[u]*dimU; - x1[v] = mGlobalOrg[v] + spa[v]*dimV; + x1[u] = mGlobalOrg[u] - pad*spa[u] + spa[u]*dimU; + x1[v] = mGlobalOrg[v] - pad*spa[v] + spa[v]*dimV; points->SetPoint(2,x1); tc[0] = float(dimU)/dimsTexture[0]; tc[1] = float(dimV)/dimsTexture[1]; @@ -218,8 +220,8 @@ // // UL point // - x1[u] = mGlobalOrg[u]; - x1[v] = mGlobalOrg[v] + spa[v]*dimV; + x1[u] = mGlobalOrg[u] - pad*spa[u]; + x1[v] = mGlobalOrg[v] - pad*spa[v] + spa[v]*dimV; points->SetPoint(3,x1); tc[0] = 0.0; tc[1] = float(dimV)/dimsTexture[1]; diff -Nru ifrit-3.3.4/core/iorthotextureplanefilter.h ifrit-3.4.2/core/iorthotextureplanefilter.h --- ifrit-3.3.4/core/iorthotextureplanefilter.h 2011-01-27 17:51:22.000000000 +0000 +++ ifrit-3.4.2/core/iorthotextureplanefilter.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioutputchannel.cpp ifrit-3.4.2/core/ioutputchannel.cpp --- ifrit-3.3.4/core/ioutputchannel.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/ioutputchannel.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioutputchannel.h ifrit-3.4.2/core/ioutputchannel.h --- ifrit-3.3.4/core/ioutputchannel.h 2011-01-27 17:51:22.000000000 +0000 +++ ifrit-3.4.2/core/ioutputchannel.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioverlayhelper.cpp ifrit-3.4.2/core/ioverlayhelper.cpp --- ifrit-3.3.4/core/ioverlayhelper.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/ioverlayhelper.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ioverlayhelper.h ifrit-3.4.2/core/ioverlayhelper.h --- ifrit-3.3.4/core/ioverlayhelper.h 2011-01-27 17:51:22.000000000 +0000 +++ ifrit-3.4.2/core/ioverlayhelper.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipalette.cpp ifrit-3.4.2/core/ipalette.cpp --- ifrit-3.3.4/core/ipalette.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/ipalette.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipalette.h ifrit-3.4.2/core/ipalette.h --- ifrit-3.3.4/core/ipalette.h 2011-01-27 17:51:22.000000000 +0000 +++ ifrit-3.4.2/core/ipalette.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipaletteset.cpp ifrit-3.4.2/core/ipaletteset.cpp --- ifrit-3.3.4/core/ipaletteset.cpp 2011-01-27 17:51:48.000000000 +0000 +++ ifrit-3.4.2/core/ipaletteset.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipaletteset.h ifrit-3.4.2/core/ipaletteset.h --- ifrit-3.3.4/core/ipaletteset.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/ipaletteset.h 2013-07-11 01:23:25.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallel.cpp ifrit-3.4.2/core/iparallel.cpp --- ifrit-3.3.4/core/iparallel.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparallel.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallel.h ifrit-3.4.2/core/iparallel.h --- ifrit-3.3.4/core/iparallel.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparallel.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallelmanager.cpp ifrit-3.4.2/core/iparallelmanager.cpp --- ifrit-3.3.4/core/iparallelmanager.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparallelmanager.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallelmanager.h ifrit-3.4.2/core/iparallelmanager.h --- ifrit-3.3.4/core/iparallelmanager.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparallelmanager.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallelworker.cpp ifrit-3.4.2/core/iparallelworker.cpp --- ifrit-3.3.4/core/iparallelworker.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparallelworker.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparallelworker.h ifrit-3.4.2/core/iparallelworker.h --- ifrit-3.3.4/core/iparallelworker.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparallelworker.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticleconnector.cpp ifrit-3.4.2/core/iparticleconnector.cpp --- ifrit-3.3.4/core/iparticleconnector.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparticleconnector.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticleconnector.h ifrit-3.4.2/core/iparticleconnector.h --- ifrit-3.3.4/core/iparticleconnector.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparticleconnector.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledataconverter.cpp ifrit-3.4.2/core/iparticledataconverter.cpp --- ifrit-3.3.4/core/iparticledataconverter.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparticledataconverter.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledataconverter.h ifrit-3.4.2/core/iparticledataconverter.h --- ifrit-3.3.4/core/iparticledataconverter.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparticledataconverter.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledatasubject.cpp ifrit-3.4.2/core/iparticledatasubject.cpp --- ifrit-3.3.4/core/iparticledatasubject.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparticledatasubject.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledatasubject.h ifrit-3.4.2/core/iparticledatasubject.h --- ifrit-3.3.4/core/iparticledatasubject.h 2011-01-27 17:51:23.000000000 +0000 +++ ifrit-3.4.2/core/iparticledatasubject.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -92,7 +92,7 @@ static const iObjectKey& KeyDensityAttribute() #define IPARTICLEDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_keywords_,_environment_) \ - IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,_keywords_,_environment_) + IDATASUBJECT_DEFINE_TYPE(_object_,_id_,_fname_,_sname_,0,_keywords_,_environment_) #define IPARTICLEDATASUBJECT_DEFINE_INHERITED_KEYS(_type_) \ IDATASUBJECT_DEFINE_INHERITED_KEYS(_type_); \ diff -Nru ifrit-3.3.4/core/iparticledensityestimator.cpp ifrit-3.4.2/core/iparticledensityestimator.cpp --- ifrit-3.3.4/core/iparticledensityestimator.cpp 2011-01-27 17:51:49.000000000 +0000 +++ ifrit-3.4.2/core/iparticledensityestimator.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledensityestimator.h ifrit-3.4.2/core/iparticledensityestimator.h --- ifrit-3.3.4/core/iparticledensityestimator.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticledensityestimator.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledownsampleiterator.cpp ifrit-3.4.2/core/iparticledownsampleiterator.cpp --- ifrit-3.3.4/core/iparticledownsampleiterator.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticledownsampleiterator.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticledownsampleiterator.h ifrit-3.4.2/core/iparticledownsampleiterator.h --- ifrit-3.3.4/core/iparticledownsampleiterator.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticledownsampleiterator.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlefileloader.cpp ifrit-3.4.2/core/iparticlefileloader.cpp --- ifrit-3.3.4/core/iparticlefileloader.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticlefileloader.cpp 2013-07-11 01:23:39.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlefileloader.h ifrit-3.4.2/core/iparticlefileloader.h --- ifrit-3.3.4/core/iparticlefileloader.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticlefileloader.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlegroup.cpp ifrit-3.4.2/core/iparticlegroup.cpp --- ifrit-3.3.4/core/iparticlegroup.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticlegroup.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlegroup.h ifrit-3.4.2/core/iparticlegroup.h --- ifrit-3.3.4/core/iparticlegroup.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticlegroup.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlegrouppipeline.cpp ifrit-3.4.2/core/iparticlegrouppipeline.cpp --- ifrit-3.3.4/core/iparticlegrouppipeline.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticlegrouppipeline.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlegrouppipeline.h ifrit-3.4.2/core/iparticlegrouppipeline.h --- ifrit-3.3.4/core/iparticlegrouppipeline.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticlegrouppipeline.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticleprobefilter.cpp ifrit-3.4.2/core/iparticleprobefilter.cpp --- ifrit-3.3.4/core/iparticleprobefilter.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticleprobefilter.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticleprobefilter.h ifrit-3.4.2/core/iparticleprobefilter.h --- ifrit-3.3.4/core/iparticleprobefilter.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticleprobefilter.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlesplitter.cpp ifrit-3.4.2/core/iparticlesplitter.cpp --- ifrit-3.3.4/core/iparticlesplitter.cpp 2011-01-27 17:51:50.000000000 +0000 +++ ifrit-3.4.2/core/iparticlesplitter.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -106,22 +106,6 @@ #define SWAP(i1,i2) { SAVE(1,i1); MOVE(i1,i2); RESTORE(i2,1); } // -// Do our own quick sort for efficiency reason (based on a Java code by Denis Ahrens) -// - -template -void Sort(iParticleSplitter *me, vtkIdType n, int ncom, int attSort, T *Points, float *Atts, float* Nrms) -{ - T poi1[3]; - float nrm1[3]; - float *att1; att1 = new float[ncom]; IERROR_ASSERT(att1); - - SortWorker(me,0,n-1,ncom,attSort,Points,Atts,Nrms,poi1,att1,nrm1); - - delete [] att1; -} - -// // Recursive worker // template @@ -179,6 +163,22 @@ } } +// +// Do our own quick sort for efficiency reason (based on a Java code by Denis Ahrens) +// + +template +void Sort(iParticleSplitter *me, vtkIdType n, int ncom, int attSort, T *Points, float *Atts, float* Nrms) +{ + T poi1[3]; + float nrm1[3]; + float *att1; att1 = new float[ncom]; IERROR_ASSERT(att1); + + SortWorker(me,0,n-1,ncom,attSort,Points,Atts,Nrms,poi1,att1,nrm1); + + delete [] att1; +} + }; diff -Nru ifrit-3.3.4/core/iparticlesplitter.h ifrit-3.4.2/core/iparticlesplitter.h --- ifrit-3.3.4/core/iparticlesplitter.h 2011-01-27 17:51:24.000000000 +0000 +++ ifrit-3.4.2/core/iparticlesplitter.h 2013-07-11 01:23:26.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlesviewsubject.cpp ifrit-3.4.2/core/iparticlesviewsubject.cpp --- ifrit-3.3.4/core/iparticlesviewsubject.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/iparticlesviewsubject.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iparticlesviewsubject.h ifrit-3.4.2/core/iparticlesviewsubject.h --- ifrit-3.3.4/core/iparticlesviewsubject.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/iparticlesviewsubject.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipicker.cpp ifrit-3.4.2/core/ipicker.cpp --- ifrit-3.3.4/core/ipicker.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/ipicker.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipicker.h ifrit-3.4.2/core/ipicker.h --- ifrit-3.3.4/core/ipicker.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/ipicker.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipiecewisefunction.cpp ifrit-3.4.2/core/ipiecewisefunction.cpp --- ifrit-3.3.4/core/ipiecewisefunction.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/ipiecewisefunction.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipiecewisefunction.h ifrit-3.4.2/core/ipiecewisefunction.h --- ifrit-3.3.4/core/ipiecewisefunction.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/ipiecewisefunction.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipointer.cpp ifrit-3.4.2/core/ipointer.cpp --- ifrit-3.3.4/core/ipointer.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/ipointer.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipointer.h ifrit-3.4.2/core/ipointer.h --- ifrit-3.3.4/core/ipointer.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/ipointer.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipointermacro.h ifrit-3.4.2/core/ipointermacro.h --- ifrit-3.3.4/core/ipointermacro.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/ipointermacro.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipointglyph.cpp ifrit-3.4.2/core/ipointglyph.cpp --- ifrit-3.3.4/core/ipointglyph.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/ipointglyph.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipointglyph.h ifrit-3.4.2/core/ipointglyph.h --- ifrit-3.3.4/core/ipointglyph.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/ipointglyph.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iposition.cpp ifrit-3.4.2/core/iposition.cpp --- ifrit-3.3.4/core/iposition.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/iposition.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iposition.h ifrit-3.4.2/core/iposition.h --- ifrit-3.3.4/core/iposition.h 2011-01-27 17:51:25.000000000 +0000 +++ ifrit-3.4.2/core/iposition.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipostscriptwriter.cpp ifrit-3.4.2/core/ipostscriptwriter.cpp --- ifrit-3.3.4/core/ipostscriptwriter.cpp 2011-01-27 17:51:51.000000000 +0000 +++ ifrit-3.4.2/core/ipostscriptwriter.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ipostscriptwriter.h ifrit-3.4.2/core/ipostscriptwriter.h --- ifrit-3.3.4/core/ipostscriptwriter.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/ipostscriptwriter.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iprobefilter.cpp ifrit-3.4.2/core/iprobefilter.cpp --- ifrit-3.3.4/core/iprobefilter.cpp 2011-01-27 17:51:52.000000000 +0000 +++ ifrit-3.4.2/core/iprobefilter.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iprobefilter.h ifrit-3.4.2/core/iprobefilter.h --- ifrit-3.3.4/core/iprobefilter.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/iprobefilter.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irangecollection.cpp ifrit-3.4.2/core/irangecollection.cpp --- ifrit-3.3.4/core/irangecollection.cpp 2011-01-27 17:51:52.000000000 +0000 +++ ifrit-3.4.2/core/irangecollection.cpp 2013-07-11 01:23:40.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irangecollection.h ifrit-3.4.2/core/irangecollection.h --- ifrit-3.3.4/core/irangecollection.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/irangecollection.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irangemapping.cpp ifrit-3.4.2/core/irangemapping.cpp --- ifrit-3.3.4/core/irangemapping.cpp 2011-01-27 17:51:52.000000000 +0000 +++ ifrit-3.4.2/core/irangemapping.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irangemapping.h ifrit-3.4.2/core/irangemapping.h --- ifrit-3.3.4/core/irangemapping.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/irangemapping.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireducepolydatafilter.cpp ifrit-3.4.2/core/ireducepolydatafilter.cpp --- ifrit-3.3.4/core/ireducepolydatafilter.cpp 2011-01-27 17:51:52.000000000 +0000 +++ ifrit-3.4.2/core/ireducepolydatafilter.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireducepolydatafilter.h ifrit-3.4.2/core/ireducepolydatafilter.h --- ifrit-3.3.4/core/ireducepolydatafilter.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/ireducepolydatafilter.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireducepolydatafilter2.cpp ifrit-3.4.2/core/ireducepolydatafilter2.cpp --- ifrit-3.3.4/core/ireducepolydatafilter2.cpp 2011-01-27 17:51:52.000000000 +0000 +++ ifrit-3.4.2/core/ireducepolydatafilter2.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireducepolydatafilter2.h ifrit-3.4.2/core/ireducepolydatafilter2.h --- ifrit-3.3.4/core/ireducepolydatafilter2.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/ireducepolydatafilter2.h 2013-07-11 01:23:27.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irendertool.cpp ifrit-3.4.2/core/irendertool.cpp --- ifrit-3.3.4/core/irendertool.cpp 2011-01-27 17:51:53.000000000 +0000 +++ ifrit-3.4.2/core/irendertool.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -426,6 +426,10 @@ mMainRen->SetRenderWindow(0); mMainWin->RemoveRenderer(mMainRen); + mMainWin->RemoveRenderer(mMainBkg->GetRenderer()); + + mMainBkg->Delete(); + mDualBkg->Delete(); mDualRen->Delete(); diff -Nru ifrit-3.3.4/core/irendertool.h ifrit-3.4.2/core/irendertool.h --- ifrit-3.3.4/core/irendertool.h 2011-01-27 17:51:26.000000000 +0000 +++ ifrit-3.4.2/core/irendertool.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/irendertoolbackground.cpp ifrit-3.4.2/core/irendertoolbackground.cpp --- ifrit-3.3.4/core/irendertoolbackground.cpp 2011-01-27 17:51:53.000000000 +0000 +++ ifrit-3.4.2/core/irendertoolbackground.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -209,7 +209,6 @@ mRenderer->Delete(); mActor->Delete(); - mMapper->Delete(); } diff -Nru ifrit-3.3.4/core/irendertoolbackground.h ifrit-3.4.2/core/irendertoolbackground.h --- ifrit-3.3.4/core/irendertoolbackground.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/irendertoolbackground.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedactor.cpp ifrit-3.4.2/core/ireplicatedactor.cpp --- ifrit-3.3.4/core/ireplicatedactor.cpp 2011-01-27 17:51:53.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedactor.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedactor.h ifrit-3.4.2/core/ireplicatedactor.h --- ifrit-3.3.4/core/ireplicatedactor.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedactor.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedelement.cpp ifrit-3.4.2/core/ireplicatedelement.cpp --- ifrit-3.3.4/core/ireplicatedelement.cpp 2011-01-27 17:51:53.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedelement.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedelement.h ifrit-3.4.2/core/ireplicatedelement.h --- ifrit-3.3.4/core/ireplicatedelement.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedelement.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedgriddata.cpp ifrit-3.4.2/core/ireplicatedgriddata.cpp --- ifrit-3.3.4/core/ireplicatedgriddata.cpp 2011-01-27 17:51:53.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedgriddata.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedgriddata.h ifrit-3.4.2/core/ireplicatedgriddata.h --- ifrit-3.3.4/core/ireplicatedgriddata.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedgriddata.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedpolydata.cpp ifrit-3.4.2/core/ireplicatedpolydata.cpp --- ifrit-3.3.4/core/ireplicatedpolydata.cpp 2011-01-27 17:51:54.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedpolydata.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedpolydata.h ifrit-3.4.2/core/ireplicatedpolydata.h --- ifrit-3.3.4/core/ireplicatedpolydata.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedpolydata.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedvolume.cpp ifrit-3.4.2/core/ireplicatedvolume.cpp --- ifrit-3.3.4/core/ireplicatedvolume.cpp 2011-01-27 17:51:54.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedvolume.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ireplicatedvolume.h ifrit-3.4.2/core/ireplicatedvolume.h --- ifrit-3.3.4/core/ireplicatedvolume.h 2011-01-27 17:51:27.000000000 +0000 +++ ifrit-3.4.2/core/ireplicatedvolume.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iresampleimagedatafilter.cpp ifrit-3.4.2/core/iresampleimagedatafilter.cpp --- ifrit-3.3.4/core/iresampleimagedatafilter.cpp 2011-01-27 17:51:54.000000000 +0000 +++ ifrit-3.4.2/core/iresampleimagedatafilter.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iresampleimagedatafilter.h ifrit-3.4.2/core/iresampleimagedatafilter.h --- ifrit-3.3.4/core/iresampleimagedatafilter.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iresampleimagedatafilter.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iruler.cpp ifrit-3.4.2/core/iruler.cpp --- ifrit-3.3.4/core/iruler.cpp 2011-01-27 17:51:54.000000000 +0000 +++ ifrit-3.4.2/core/iruler.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iruler.h ifrit-3.4.2/core/iruler.h --- ifrit-3.3.4/core/iruler.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iruler.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iscript.cpp ifrit-3.4.2/core/iscript.cpp --- ifrit-3.3.4/core/iscript.cpp 2011-01-27 17:51:54.000000000 +0000 +++ ifrit-3.4.2/core/iscript.cpp 2013-07-11 01:23:41.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -54,6 +54,8 @@ mBlock = mIsCompiled = false; + mErrorLine = mErrorPosition = -1; + //mText = ""; mThisEntry = mNextEntry = -1; @@ -133,6 +135,19 @@ iScriptKit::Calculator* iScript::CreateCalculator() { + int i; + + iScriptKit::Calculator* calc = this->CreateCalculatorBody(); IERROR_ASSERT(calc); + + for(i=0; iAddVariable(mConstants[i]->CalculatorValue()); + //for(i=0; iAddVariable(mVariables[i]->CalculatorValue()); + + return calc; +} + + +iScriptKit::Calculator* iScript::CreateCalculatorBody() +{ return new iScriptKit::Calculator(this); } @@ -287,6 +302,7 @@ // while(mVariables.Size() > 0) { + if(mCalculator != 0) mCalculator->RemoveVariable(mVariables.Last()->Name()); delete mVariables.RemoveLast(); } mIsCompiled = false; @@ -298,6 +314,7 @@ this->GetErrorStatus()->Set(message); mErrorPosition = pos; if(line == -1) line = this->GetThisLine(); + mErrorLine = line; } @@ -444,13 +461,8 @@ if(mCalculator == 0) { - mCalculator = this->CreateCalculator(); IERROR_ASSERT(mCalculator); - if(mParent!=0 && mParent->mAllowChildAccess) mCalculator->CopyVariables(mParent->mCalculator); // this ensures correct name resolution - - int i; - for(i=0; iAddVariable(mConstants[i]->CalculatorValue()); + mCalculator = this->CreateCalculator(); } - this->Reset(); int headLen = mHeadOfLineContinuationString.Length(); @@ -619,6 +631,7 @@ int ooo = 0; } #endif + //if(mCalculator != 0) mCalculator->AddVariable(value->CalculatorValue()); mVariables.Add(value); } } @@ -633,6 +646,7 @@ { if(mVariables[i]->Name() == name) { + if(mCalculator != 0) mCalculator->RemoveVariable(mVariables[i]->Name()); delete mVariables[i]; mVariables.Remove(i); return; // remove one at a time diff -Nru ifrit-3.3.4/core/iscript.h ifrit-3.4.2/core/iscript.h --- ifrit-3.3.4/core/iscript.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iscript.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -120,6 +120,7 @@ void QueryVariables(iArray &list) const; + inline int GetErrorLine() const { return mErrorLine; } inline int GetErrorPosition() const { return mErrorPosition; } // @@ -164,6 +165,8 @@ void AddConstant(iScriptKit::Value *value); + iScriptKit::Calculator* CreateCalculator(); + // // Prototypes // @@ -178,7 +181,7 @@ // Factory method: a calculator can be replaced by a child. It is non-const so that a child's // calculator can add new variables and constants. // - virtual iScriptKit::Calculator* CreateCalculator(); + virtual iScriptKit::Calculator* CreateCalculatorBody(); // // Overwrite this to create special non-algebraic variables @@ -227,7 +230,7 @@ void RemoveObserver(iScriptObserver *obs); bool mBlock, mIsCompiled; - int mErrorPosition; + int mErrorLine, mErrorPosition; iArray mAliasWords; iSearchableArray mDummyWords; diff -Nru ifrit-3.3.4/core/iscriptkit.cpp ifrit-3.4.2/core/iscriptkit.cpp --- ifrit-3.3.4/core/iscriptkit.cpp 2011-01-27 17:51:55.000000000 +0000 +++ ifrit-3.4.2/core/iscriptkit.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -50,7 +50,7 @@ // // Calculator // - Calculator::Calculator(iScript *script) : iCalculator(script==0?0:script->GetCalculator()), mScript(script) + Calculator::Calculator(iScript *script) : iCalculator(), mScript(script) { IERROR_ASSERT(mScript); this->SetTrapFPE(true); @@ -85,6 +85,13 @@ } + const iCalculatorKit::Variable* Calculator::FindExternalVariable(const iString &name) const + { + Value *var = mScript->FindVariable(name); + if(var != 0) return var->CalculatorValue(); else return 0; + } + + // // Base class for values (variables and parameters) // @@ -329,7 +336,7 @@ if(c!=0 && !c->GetErrorMessage().IsEmpty()) { int i = mArgument.FindIgnoringWhiteSpace(mOperand); - mScript->ReportError(c->GetErrorMessage(),mCommand.Length()+(i>-1?i+c->GetErrorPosition():0),-1); + mScript->ReportError(c->GetErrorMessage(),mCommand.Length()+(i>-1?i+c->GetErrorPosition():0),mLineInScript); } } diff -Nru ifrit-3.3.4/core/iscriptkit.h ifrit-3.4.2/core/iscriptkit.h --- ifrit-3.3.4/core/iscriptkit.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iscriptkit.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -57,6 +57,8 @@ Calculator(iScript *script); + virtual const iCalculatorKit::Variable* FindExternalVariable(const iString &name) const; + iScript *mScript; }; diff -Nru ifrit-3.3.4/core/iscriptkittemplate.h ifrit-3.4.2/core/iscriptkittemplate.h --- ifrit-3.3.4/core/iscriptkittemplate.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iscriptkittemplate.h 2013-07-11 01:23:28.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iserialpipeline.h ifrit-3.4.2/core/iserialpipeline.h --- ifrit-3.3.4/core/iserialpipeline.h 2011-01-27 17:51:28.000000000 +0000 +++ ifrit-3.4.2/core/iserialpipeline.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ishell.cpp ifrit-3.4.2/core/ishell.cpp --- ifrit-3.3.4/core/ishell.cpp 2011-01-27 17:51:55.000000000 +0000 +++ ifrit-3.4.2/core/ishell.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -42,6 +42,7 @@ #include "ishellfactory.h" #include "iversion.h" #include "iviewmodule.h" +#include "ivolumeviewsubject.h" #include #include @@ -145,6 +146,8 @@ this->AddCommandLineOption("b",true,"execute a control script from a file in the screenless mode"); this->AddCommandLineOption("np",true,"set the number of processors to use to "); this->AddCommandLineOption("test",false,"test performance and exit (must be the first and only option)"); + this->AddCommandLineOption("GPU",false,"try to use GPU even if VTK does not find it"); + this->AddCommandLineOption("no-GPU",false,"do not use GPU even if it is present on the system (useful for running IFrIT remotely)"); // // Set environment variables @@ -615,6 +618,16 @@ } } + if(o.Name == "GPU") + { + iVolumeViewSubject::SetGPUMode(1); + } + + if(o.Name == "no-GPU") + { + iVolumeViewSubject::SetGPUMode(-1); + } + return this->AnalyseOneExtendedCommandLineOption(o); } diff -Nru ifrit-3.3.4/core/ishell.h ifrit-3.4.2/core/ishell.h --- ifrit-3.3.4/core/ishell.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/ishell.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ishiftpolydatafilter.cpp ifrit-3.4.2/core/ishiftpolydatafilter.cpp --- ifrit-3.3.4/core/ishiftpolydatafilter.cpp 2011-01-27 17:51:55.000000000 +0000 +++ ifrit-3.4.2/core/ishiftpolydatafilter.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ishiftpolydatafilter.h ifrit-3.4.2/core/ishiftpolydatafilter.h --- ifrit-3.3.4/core/ishiftpolydatafilter.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/ishiftpolydatafilter.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ismoothpolydatafilter.cpp ifrit-3.4.2/core/ismoothpolydatafilter.cpp --- ifrit-3.3.4/core/ismoothpolydatafilter.cpp 2011-01-27 17:51:55.000000000 +0000 +++ ifrit-3.4.2/core/ismoothpolydatafilter.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ismoothpolydatafilter.h ifrit-3.4.2/core/ismoothpolydatafilter.h --- ifrit-3.3.4/core/ismoothpolydatafilter.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/ismoothpolydatafilter.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ismoothpolydatafilter2.cpp ifrit-3.4.2/core/ismoothpolydatafilter2.cpp --- ifrit-3.3.4/core/ismoothpolydatafilter2.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/ismoothpolydatafilter2.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ismoothpolydatafilter2.h ifrit-3.4.2/core/ismoothpolydatafilter2.h --- ifrit-3.3.4/core/ismoothpolydatafilter2.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/ismoothpolydatafilter2.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isolidobjectsource.cpp ifrit-3.4.2/core/isolidobjectsource.cpp --- ifrit-3.3.4/core/isolidobjectsource.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/isolidobjectsource.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isolidobjectsource.h ifrit-3.4.2/core/isolidobjectsource.h --- ifrit-3.3.4/core/isolidobjectsource.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/isolidobjectsource.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isolidviewsubject.cpp ifrit-3.4.2/core/isolidviewsubject.cpp --- ifrit-3.3.4/core/isolidviewsubject.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/isolidviewsubject.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isolidviewsubject.h ifrit-3.4.2/core/isolidviewsubject.h --- ifrit-3.3.4/core/isolidviewsubject.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/isolidviewsubject.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/istereoimage.cpp ifrit-3.4.2/core/istereoimage.cpp --- ifrit-3.3.4/core/istereoimage.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/istereoimage.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -38,6 +38,18 @@ } +iStereoImage::iStereoImage(const iImage &img) +{ + this->operator=(img); +} + + +iStereoImage::iStereoImage(const iStereoImage &img) +{ + this->operator=(img); +} + + iStereoImage& iStereoImage::operator=(const iStereoImage &img) { mEyeImage[0] = img.mEyeImage[0]; diff -Nru ifrit-3.3.4/core/istereoimage.h ifrit-3.4.2/core/istereoimage.h --- ifrit-3.3.4/core/istereoimage.h 2011-01-27 17:51:29.000000000 +0000 +++ ifrit-3.4.2/core/istereoimage.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -41,6 +41,8 @@ public: iStereoImage(); + iStereoImage(const iImage &img); + iStereoImage(const iStereoImage &img); const iImage& Eye(int n) const; const iImage& LeftEye() const; diff -Nru ifrit-3.3.4/core/istereoimagearray.cpp ifrit-3.4.2/core/istereoimagearray.cpp --- ifrit-3.3.4/core/istereoimagearray.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/istereoimagearray.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -50,3 +50,13 @@ this->Add(arr[i]); } } + + +void iStereoImageArray::Fill(const iStereoImage &img) +{ + int i; + for(i=0; imNum; i++) + { + mArr[i] = img; + } +} diff -Nru ifrit-3.3.4/core/istereoimagearray.h ifrit-3.4.2/core/istereoimagearray.h --- ifrit-3.3.4/core/istereoimagearray.h 2011-01-27 17:51:30.000000000 +0000 +++ ifrit-3.4.2/core/istereoimagearray.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -46,6 +46,7 @@ iStereoImageArray(); void Copy(const iStereoImageArray &arr); + void Fill(const iStereoImage &img); }; #endif // ISTEREOIMAGEARRAY_H diff -Nru ifrit-3.3.4/core/istreamlinefilter.cpp ifrit-3.4.2/core/istreamlinefilter.cpp --- ifrit-3.3.4/core/istreamlinefilter.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/istreamlinefilter.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/istreamlinefilter.h ifrit-3.4.2/core/istreamlinefilter.h --- ifrit-3.3.4/core/istreamlinefilter.h 2011-01-27 17:51:30.000000000 +0000 +++ ifrit-3.4.2/core/istreamlinefilter.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/istring.cpp ifrit-3.4.2/core/istring.cpp --- ifrit-3.3.4/core/istring.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/istring.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/istring.h ifrit-3.4.2/core/istring.h --- ifrit-3.3.4/core/istring.h 2011-01-27 17:51:30.000000000 +0000 +++ ifrit-3.4.2/core/istring.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isurfacepipeline.cpp ifrit-3.4.2/core/isurfacepipeline.cpp --- ifrit-3.3.4/core/isurfacepipeline.cpp 2011-01-27 17:51:56.000000000 +0000 +++ ifrit-3.4.2/core/isurfacepipeline.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isurfacepipeline.h ifrit-3.4.2/core/isurfacepipeline.h --- ifrit-3.3.4/core/isurfacepipeline.h 2011-01-27 17:51:30.000000000 +0000 +++ ifrit-3.4.2/core/isurfacepipeline.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isurfaceviewsubject.cpp ifrit-3.4.2/core/isurfaceviewsubject.cpp --- ifrit-3.3.4/core/isurfaceviewsubject.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/isurfaceviewsubject.cpp 2013-07-11 01:23:42.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isurfaceviewsubject.h ifrit-3.4.2/core/isurfaceviewsubject.h --- ifrit-3.3.4/core/isurfaceviewsubject.h 2011-01-27 17:51:30.000000000 +0000 +++ ifrit-3.4.2/core/isurfaceviewsubject.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isystem.cpp ifrit-3.4.2/core/isystem.cpp --- ifrit-3.3.4/core/isystem.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/isystem.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/isystem.h ifrit-3.4.2/core/isystem.h --- ifrit-3.3.4/core/isystem.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/isystem.h 2013-07-11 01:23:29.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorfieldpipeline.cpp ifrit-3.4.2/core/itensorfieldpipeline.cpp --- ifrit-3.3.4/core/itensorfieldpipeline.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itensorfieldpipeline.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorfieldpipeline.h ifrit-3.4.2/core/itensorfieldpipeline.h --- ifrit-3.3.4/core/itensorfieldpipeline.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/itensorfieldpipeline.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorfieldviewsubject.cpp ifrit-3.4.2/core/itensorfieldviewsubject.cpp --- ifrit-3.3.4/core/itensorfieldviewsubject.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itensorfieldviewsubject.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorfieldviewsubject.h ifrit-3.4.2/core/itensorfieldviewsubject.h --- ifrit-3.3.4/core/itensorfieldviewsubject.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/itensorfieldviewsubject.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorglyphfilter.cpp ifrit-3.4.2/core/itensorglyphfilter.cpp --- ifrit-3.3.4/core/itensorglyphfilter.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itensorglyphfilter.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itensorglyphfilter.h ifrit-3.4.2/core/itensorglyphfilter.h --- ifrit-3.3.4/core/itensorglyphfilter.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/itensorglyphfilter.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itextactor.cpp ifrit-3.4.2/core/itextactor.cpp --- ifrit-3.3.4/core/itextactor.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itextactor.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itextactor.h ifrit-3.4.2/core/itextactor.h --- ifrit-3.3.4/core/itextactor.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/itextactor.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itextsubject.cpp ifrit-3.4.2/core/itextsubject.cpp --- ifrit-3.3.4/core/itextsubject.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itextsubject.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itextsubject.h ifrit-3.4.2/core/itextsubject.h --- ifrit-3.3.4/core/itextsubject.h 2011-01-27 17:51:31.000000000 +0000 +++ ifrit-3.4.2/core/itextsubject.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itransform.cpp ifrit-3.4.2/core/itransform.cpp --- ifrit-3.3.4/core/itransform.cpp 2011-01-27 17:51:57.000000000 +0000 +++ ifrit-3.4.2/core/itransform.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/itransform.h ifrit-3.4.2/core/itransform.h --- ifrit-3.3.4/core/itransform.h 2011-01-27 17:51:32.000000000 +0000 +++ ifrit-3.4.2/core/itransform.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iuniformgriddata.cpp ifrit-3.4.2/core/iuniformgriddata.cpp --- ifrit-3.3.4/core/iuniformgriddata.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/iuniformgriddata.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iuniformgriddata.h ifrit-3.4.2/core/iuniformgriddata.h --- ifrit-3.3.4/core/iuniformgriddata.h 2011-01-27 17:51:32.000000000 +0000 +++ ifrit-3.4.2/core/iuniformgriddata.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iuniformgridfileloader.cpp ifrit-3.4.2/core/iuniformgridfileloader.cpp --- ifrit-3.3.4/core/iuniformgridfileloader.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/iuniformgridfileloader.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iuniformgridfileloader.h ifrit-3.4.2/core/iuniformgridfileloader.h --- ifrit-3.3.4/core/iuniformgridfileloader.h 2011-01-27 17:51:32.000000000 +0000 +++ ifrit-3.4.2/core/iuniformgridfileloader.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldglyphpipeline.cpp ifrit-3.4.2/core/ivectorfieldglyphpipeline.cpp --- ifrit-3.3.4/core/ivectorfieldglyphpipeline.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldglyphpipeline.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldglyphpipeline.h ifrit-3.4.2/core/ivectorfieldglyphpipeline.h --- ifrit-3.3.4/core/ivectorfieldglyphpipeline.h 2011-01-27 17:51:32.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldglyphpipeline.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldstreamlinepipeline.cpp ifrit-3.4.2/core/ivectorfieldstreamlinepipeline.cpp --- ifrit-3.3.4/core/ivectorfieldstreamlinepipeline.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldstreamlinepipeline.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldstreamlinepipeline.h ifrit-3.4.2/core/ivectorfieldstreamlinepipeline.h --- ifrit-3.3.4/core/ivectorfieldstreamlinepipeline.h 2011-01-27 17:51:32.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldstreamlinepipeline.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldviewsubject.cpp ifrit-3.4.2/core/ivectorfieldviewsubject.cpp --- ifrit-3.3.4/core/ivectorfieldviewsubject.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldviewsubject.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorfieldviewsubject.h ifrit-3.4.2/core/ivectorfieldviewsubject.h --- ifrit-3.3.4/core/ivectorfieldviewsubject.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/ivectorfieldviewsubject.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorglyphfilter.cpp ifrit-3.4.2/core/ivectorglyphfilter.cpp --- ifrit-3.3.4/core/ivectorglyphfilter.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/ivectorglyphfilter.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectorglyphfilter.h ifrit-3.4.2/core/ivectorglyphfilter.h --- ifrit-3.3.4/core/ivectorglyphfilter.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/ivectorglyphfilter.h 2013-07-11 01:23:30.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectortextsubject.cpp ifrit-3.4.2/core/ivectortextsubject.cpp --- ifrit-3.3.4/core/ivectortextsubject.cpp 2011-01-27 17:51:58.000000000 +0000 +++ ifrit-3.4.2/core/ivectortextsubject.cpp 2013-07-11 01:23:43.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivectortextsubject.h ifrit-3.4.2/core/ivectortextsubject.h --- ifrit-3.3.4/core/ivectortextsubject.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/ivectortextsubject.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewfamily.h ifrit-3.4.2/core/iviewfamily.h --- ifrit-3.3.4/core/iviewfamily.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/iviewfamily.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewfamilytemplate.h ifrit-3.4.2/core/iviewfamilytemplate.h --- ifrit-3.3.4/core/iviewfamilytemplate.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/iviewfamilytemplate.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewmodule.cpp ifrit-3.4.2/core/iviewmodule.cpp --- ifrit-3.3.4/core/iviewmodule.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewmodule.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -119,6 +119,15 @@ // +// Declare static members +// +int iViewModule::mSnapshotIndex = 1; +int iViewModule::mAnimationIndex = 1; +iString iViewModule::mSnapshotRootName; +iString iViewModule::mAnimationRootName; + + +// // Define keys // IOBJECT_DEFINE_TYPE(iViewModule,ViewModule,vm,iObjectType::_Module); @@ -128,6 +137,7 @@ IOBJECT_DEFINE_KEY(iViewModule,AxesBoxLabels,abl,String,3); IOBJECT_DEFINE_KEY(iViewModule,AxesBoxRanges,abr,Float,6); IOBJECT_DEFINE_KEY(iViewModule,AnimationOutput,ao,Int,1); +IOBJECT_DEFINE_KEY(iViewModule,AnimationRootName,an,String,1); IOBJECT_DEFINE_KEY(iViewModule,BoundingBox,bb,Bool,1); IOBJECT_DEFINE_KEY(iViewModule,BoundingBoxType,bbt,Int,1); IOBJECT_DEFINE_KEY(iViewModule,BackgroundColor,bg,Color,1); @@ -178,6 +188,7 @@ IOBJECT_DEFINE_KEY(iViewModule,RulerScale,rs,Float,1); IOBJECT_DEFINE_KEY(iViewModule,RulerTitle,rt,String,1); IOBJECT_DEFINE_KEY(iViewModule,Size,s,Int,2); +IOBJECT_DEFINE_KEY(iViewModule,SnapshotRootName,sn,String,1); IOBJECT_DEFINE_KEY(iViewModule,UpdateRate,r,Int,1); IOBJECT_DEFINE_KEY(iViewModule,StereoAlignmentMarks,sam,Bool,1); IOBJECT_DEFINE_KEY(iViewModule,StereoMode,sm,Int,1); @@ -241,6 +252,9 @@ { int i; + if(mSnapshotRootName.IsEmpty()) this->SetSnapshotRootName("+image"); + if(mAnimationRootName.IsEmpty()) this->SetAnimationRootName("+anim"); + mBoxType = -1; // needs to be reset mImageMagnification = 1; mSavedProjection = 0; @@ -251,6 +265,7 @@ mAntialiasing = true; mInImageRender = false; mBackgroundImageFixedAspect = false; + mInAnimation = false; mRate = 10; mBoxSize = -1.0; @@ -1084,7 +1099,6 @@ mRenderTool->SetBackground(mBackgroundColor); mMeasuringBox->SetColor(fg); mBox1Actor->GetProperty()->SetColor(fg.ToVTK()); - mAnimator->SetCameraPathColor(fg); mMarkerFamily->SetHandlesColor(fg); this->ClearCache(); } @@ -1331,7 +1345,24 @@ if(this->GetErrorStatus()->NoError()) { mObsProgress->SetMode(iProgressEventObserver::_Writing); // auto-driven - mWriter->WriteFrame(tmp,m); + + switch(m) + { + case ImageType::Snapshot: + { + mWriter->WriteImageFrame(tmp,this->GetSnapshotFileName()); + mSnapshotIndex++; + break; + } + case ImageType::AnimationFrame: + { + if(mInAnimation) mWriter->WriteMovieFrame(tmp,this->GetAnimationFileName()); else + { + IERROR_LOW("Trying to write a frame for an animation that has not started."); + } + break; + } + } } else { @@ -1376,6 +1407,9 @@ this->PackValue(s,KeyLabelOffset(),mLabelOffset); this->PackValue(s,KeyLabelDigits(),mLabelDigits); + this->PackValue(s,KeySnapshotRootName(),this->GetSnapshotRootName()); + this->PackValue(s,KeyAnimationRootName(),this->GetAnimationRootName()); + this->PackValue(s,KeyFontScale(),this->GetFontScale()); this->PackValue(s,KeyFontType(),this->GetFontType()); this->PackValue(s,KeyBoundingBoxType(),mBoxType); @@ -1474,6 +1508,9 @@ if(this->UnPackValue(s,KeyArtifactCorrection(),b)) this->SetArtifactCorrection(b); if(this->UnPackValue(s,KeyBackgroundImageFixedAspect(),b)) this->SetBackgroundImageFixedAspect(b); + if(this->UnPackValue(s,KeySnapshotRootName(),w)) this->SetSnapshotRootName(w); + if(this->UnPackValue(s,KeyAnimationRootName(),w)) this->SetAnimationRootName(w); + iObject::ReportMissingKeys(false); if(this->UnPackValue(s,KeyFontSize(),i)) this->SetFontScale(round(log(i/16.0)/0.3)); // for backward compatibility only iObject::ReportMissingKeys(true); @@ -1763,6 +1800,113 @@ } +void iViewModule::SetSnapshotRootName(const iString &name) +{ + if(!name.IsEmpty() && name!=mSnapshotRootName) + { + mSnapshotIndex = 1; + mSnapshotRootName = name; + + if(mSnapshotRootName[0] == '+') + { + mSnapshotRootName = this->GetControlModule()->GetShell()->GetEnvironment(Environment::Image) + mSnapshotRootName.Part(1); + } + +#ifdef _WIN32 + mSnapshotRootName.Replace("\\","/"); +#endif + this->ClearCache(); + } +} + + +const iString& iViewModule::GetSnapshotRootName() const +{ + return mSnapshotRootName; +} + + +const iString& iViewModule::GetSnapshotFileName() +{ + static iString root; + + root = mSnapshotRootName + "-" + iString::FromNumber(mSnapshotIndex,"%05d"); + + return root; +} + + +void iViewModule::SetAnimationRootName(const iString &name) +{ + if(!name.IsEmpty() && name!=mAnimationRootName) + { + mAnimationIndex = 1; + mAnimationRootName = name; + + if(mAnimationRootName[0] == '+') + { + mAnimationRootName = this->GetControlModule()->GetShell()->GetEnvironment(Environment::Image) + mAnimationRootName.Part(1); + } + +#ifdef _WIN32 + mAnimationRootName.Replace("\\","/"); +#endif + this->ClearCache(); + } +} + + +const iString& iViewModule::GetAnimationRootName() const +{ + return mAnimationRootName; +} + + +const iString& iViewModule::GetAnimationFileName() +{ + static iString root; + + root = mAnimationRootName; + + if(mAnimationIndex > 1) + { + iString tail; + if(root[root.Length()-1] == '-') + { + tail = "-"; + root = root.Part(0,root.Length()-1); + } + root += iString::FromNumber(mAnimationIndex) + tail; + } + + return root; +} + + +void iViewModule::StartAnimation() +{ + if(mInAnimation) + { + IERROR_LOW("Previous animation has not completed properly."); + } + + mWriter->StartMovie(); + mInAnimation = true; +} + + +void iViewModule::FinishAnimation() +{ + if(!mInAnimation) + { + IERROR_LOW("Animation is finishing without starting."); + } + + mAnimationIndex++; + mInAnimation = false; +} + + // // Access to RenderTool components // diff -Nru ifrit-3.3.4/core/iviewmodule.h ifrit-3.4.2/core/iviewmodule.h --- ifrit-3.3.4/core/iviewmodule.h 2011-01-27 17:51:33.000000000 +0000 +++ ifrit-3.4.2/core/iviewmodule.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -164,6 +164,13 @@ static const iObjectKey& KeyAnimationOutput(); static const iObjectKey& KeyPostScriptPaperFormat(); static const iObjectKey& KeyPostScriptOrientation(); + IOBJECT_DECLARE_GETSET2(SnapshotRootName,const iString&); + IOBJECT_DECLARE_GETSET2(AnimationRootName,const iString&); + //inline int GetAnimationIndex() const { return mAnimationIndex; } + static const iString& GetSnapshotFileName(); + static const iString& GetAnimationFileName(); + void StartAnimation(); + void FinishAnimation(); IOBJECT_DECLARE_GETSET1(LabelName,const iString&); //virtual void SetLabelName(const iString &s); @@ -273,7 +280,6 @@ inline iAbortRenderEventObserver* GetAbortRenderEventObserver() const { return mObsAbortRender; } inline iSlaveAbortRenderEventObserver* GetSlaveAbortRenderEventObserver() const { return mObsSlaveAbortRender; } inline iPicker* GetPicker() const { return mPicker; } - inline iWriter* GetWriter() const { return mWriter; } void AddObject(vtkProp* p); void RemoveObject(vtkProp* p); @@ -376,6 +382,10 @@ float mLabelScale, mLabelOffset; int mLabelDigits; + static int mSnapshotIndex, mAnimationIndex; + static iString mSnapshotRootName, mAnimationRootName; + bool mInAnimation; + // // Rendering pipeline // diff -Nru ifrit-3.3.4/core/iviewobject.cpp ifrit-3.4.2/core/iviewobject.cpp --- ifrit-3.3.4/core/iviewobject.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewobject.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewobject.h ifrit-3.4.2/core/iviewobject.h --- ifrit-3.3.4/core/iviewobject.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewobject.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewobjectfamily.cpp ifrit-3.4.2/core/iviewobjectfamily.cpp --- ifrit-3.3.4/core/iviewobjectfamily.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewobjectfamily.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewobjectfamily.h ifrit-3.4.2/core/iviewobjectfamily.h --- ifrit-3.3.4/core/iviewobjectfamily.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewobjectfamily.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubject.cpp ifrit-3.4.2/core/iviewsubject.cpp --- ifrit-3.3.4/core/iviewsubject.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubject.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubject.h ifrit-3.4.2/core/iviewsubject.h --- ifrit-3.3.4/core/iviewsubject.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubject.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectcomponent.cpp ifrit-3.4.2/core/iviewsubjectcomponent.cpp --- ifrit-3.3.4/core/iviewsubjectcomponent.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectcomponent.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectcomponent.h ifrit-3.4.2/core/iviewsubjectcomponent.h --- ifrit-3.3.4/core/iviewsubjectcomponent.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectcomponent.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectobserver.cpp ifrit-3.4.2/core/iviewsubjectobserver.cpp --- ifrit-3.3.4/core/iviewsubjectobserver.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectobserver.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectobserver.h ifrit-3.4.2/core/iviewsubjectobserver.h --- ifrit-3.3.4/core/iviewsubjectobserver.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectobserver.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectparallelpipeline.cpp ifrit-3.4.2/core/iviewsubjectparallelpipeline.cpp --- ifrit-3.3.4/core/iviewsubjectparallelpipeline.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectparallelpipeline.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectparallelpipeline.h ifrit-3.4.2/core/iviewsubjectparallelpipeline.h --- ifrit-3.3.4/core/iviewsubjectparallelpipeline.h 2011-01-27 17:51:34.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectparallelpipeline.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectpipeline.cpp ifrit-3.4.2/core/iviewsubjectpipeline.cpp --- ifrit-3.3.4/core/iviewsubjectpipeline.cpp 2011-01-27 17:51:59.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectpipeline.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectpipeline.h ifrit-3.4.2/core/iviewsubjectpipeline.h --- ifrit-3.3.4/core/iviewsubjectpipeline.h 2011-01-27 17:51:35.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectpipeline.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectpipelinedatamanager.cpp ifrit-3.4.2/core/iviewsubjectpipelinedatamanager.cpp --- ifrit-3.3.4/core/iviewsubjectpipelinedatamanager.cpp 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectpipelinedatamanager.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectpipelinedatamanager.h ifrit-3.4.2/core/iviewsubjectpipelinedatamanager.h --- ifrit-3.3.4/core/iviewsubjectpipelinedatamanager.h 2011-01-27 17:51:35.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectpipelinedatamanager.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/iviewsubjectpipelinetemplate.h ifrit-3.4.2/core/iviewsubjectpipelinetemplate.h --- ifrit-3.3.4/core/iviewsubjectpipelinetemplate.h 2011-01-27 17:51:35.000000000 +0000 +++ ifrit-3.4.2/core/iviewsubjectpipelinetemplate.h 2013-07-11 01:23:31.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivolumedataconverter.cpp ifrit-3.4.2/core/ivolumedataconverter.cpp --- ifrit-3.3.4/core/ivolumedataconverter.cpp 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/core/ivolumedataconverter.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivolumedataconverter.h ifrit-3.4.2/core/ivolumedataconverter.h --- ifrit-3.3.4/core/ivolumedataconverter.h 2011-01-27 17:51:35.000000000 +0000 +++ ifrit-3.4.2/core/ivolumedataconverter.h 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/core/ivolumeviewsubject.cpp ifrit-3.4.2/core/ivolumeviewsubject.cpp --- ifrit-3.3.4/core/ivolumeviewsubject.cpp 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/core/ivolumeviewsubject.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -114,6 +114,9 @@ IVIEWSUBJECT_DEFINE_INHERITED_KEYS_REPLICATING(iVolumeViewSubject); +int iVolumeViewSubject::mGPUMode = 0; // auto + + namespace iVolumeViewSubject_Private { class UniformGridVolumeRenderingHelper : public iVolumeRenderingHelper @@ -380,6 +383,8 @@ virtual bool IsAvailable() { + if(iVolumeViewSubject::GPUMode() < 0) return false; + if(iVolumeViewSubject::GPUMode() > 0) return true; return (mMapper->IsRenderSupported(mParent->GetViewModule()->GetRenderWindow(),mParent->GetVolume()->GetProperty()) != 0); } @@ -400,67 +405,6 @@ }; #endif - -/* - class ShearWarpRayCastHelper : public UniformGridVolumeRenderingHelper - { - - public: - - ShearWarpRayCastHelper(iVolumeViewSubject *parent, vtkImageData *input) : UniformGridVolumeRenderingHelper(parent,"Shear warp ray casting") - { - mMapper = vtkVolumeShearWarpMapper::New(); IERROR_ASSERT(mMapper); - mMapper->AddObserver(vtkCommand::ProgressEvent,parent->GetViewModule()->GetAbortRenderEventObserver()); - mMapper->IntermixIntersectingGeometryOn(); - mMapper->AutoAdjustSampleDistancesOn(); - mMapper->SetInput(input); - mMapper->SetFunctionTypeToComposite(); - } - - virtual ~ShearWarpRayCastHelper() - { - mMapper->Delete(); - } - - virtual vtkAbstractVolumeMapper* GetMapper() - { - return mMapper; - } - - virtual void SetBlendMode(int m) - { - switch(m) - { - case 0: - { - mMapper->SetFunctionTypeToComposite(); - break; - } - case 1: - { - mMapper->SetFunctionTypeToMIP(); - break; - } - } - } - - protected: - - virtual void AdjustSpacing() - { - if(mMapper->GetAutoAdjustSampleDistances() == 0) - { - mMapper->SetImageSampleDistance(mImageDownsampleFactor); - } - } - - private: - - vtkVolumeShearWarpMapper *mMapper; - }; -*/ - - #ifdef VTK_USE_VOLUMEPRO class VolumeProHelper : public UniformGridVolumeRenderingHelper { @@ -961,6 +905,12 @@ } +void iVolumeViewSubject::SetGPUMode(int m) +{ + mGPUMode = m; +} + + // // Helper class // diff -Nru ifrit-3.3.4/core/ivolumeviewsubject.h ifrit-3.4.2/core/ivolumeviewsubject.h --- ifrit-3.3.4/core/ivolumeviewsubject.h 2011-01-27 17:51:35.000000000 +0000 +++ ifrit-3.4.2/core/ivolumeviewsubject.h 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -148,6 +148,9 @@ IVIEWSUBJECT_DECLARE_INHERITED_KEYS; IVIEWSUBJECT_DECLARE_INHERITED_MEMBERS; + static void SetGPUMode(int m); + static int GPUMode(){ return mGPUMode; } + protected: iVolumeViewSubject(iViewModule *vm, const iDataType &type, const iString &name); @@ -164,6 +167,8 @@ int mBlendMode, mInterpolationType; float mImageDownsampleFactor, mDepthDownsampleFactor; + static int mGPUMode; + // // VTK members // diff -Nru ifrit-3.3.4/core/iwriter.cpp ifrit-3.4.2/core/iwriter.cpp --- ifrit-3.3.4/core/iwriter.cpp 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/core/iwriter.cpp 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -37,15 +37,16 @@ #include "iviewmodule.h" #include "ivtk.h" -#include +#include +#include #include + +#include #include #include #include #include -#include - #ifdef IVTK_SUPPORTS_AVI #include #endif @@ -65,15 +66,6 @@ // -// Declare static members -// -int iWriter::mCurrentSnapshotImageIndex = 1; -int iWriter::mCurrentAnimationImageIndex = 1; -iString iWriter::mCurrentSnapshotImageFilePrefix = "ifrit-im"; -iString iWriter::mCurrentAnimationImageFilePrefix = "ifrit-an"; - - -// // Helper class // class iGenericMultiImageMovieWriter : public vtkObjectBase @@ -90,7 +82,7 @@ mStarted = true; } - void WriteFrame(const iStereoImageArray& images, const iString &path, const iString &root); + void WriteFrame(const iStereoImageArray& images, const iString &root); void Finish() { @@ -110,10 +102,11 @@ protected: - iGenericMultiImageMovieWriter(iViewModule *vm) : mViewModule(vm) + iGenericMultiImageMovieWriter(iViewModule *vm, vtkImageWriter *writer) : mViewModule(vm) { IERROR_ASSERT(vm); mStarted = false; + mParentWriter = writer; } virtual ~iGenericMultiImageMovieWriter() @@ -126,33 +119,107 @@ bool mStarted; iArray mImageWriters; + vtkImageWriter *mParentWriter; }; namespace iWriter_Private { + class FileSetMovieWriter : public vtkGenericMovieWriter + { + public: + + static FileSetMovieWriter* New(vtkImageWriter *writer) + { + return new FileSetMovieWriter(writer); + } + + virtual void Start() + { + mRoot = iString(FileName); + if(mRoot[mRoot.Length()-1] != '-') + { + vtkDirectory *d = vtkDirectory::New(); IERROR_ASSERT(d); + if(d->Open(mRoot.ToCharPointer()) == 0) + { + if(vtkDirectory::MakeDirectory(mRoot.ToCharPointer())==0 || d->Open(mRoot.ToCharPointer())==0) + { + mRoot += "-"; + } + else + { + mRoot += "/frame-"; + } + } + else + { + mRoot += "/frame-"; + } + } + else + { + } + + mFrame = 0; + } + + virtual void Write() + { + iString suf = ".png"; + + if(mWriter->IsA("vtkJPEGWriter") != 0) suf = ".jpg"; + if(mWriter->IsA("vtkPNMWriter") != 0) suf = ".ppm"; + if(mWriter->IsA("vtkBMPWriter") != 0) suf = ".bmp"; + if(mWriter->IsA("vtkTIFFWriter") != 0) suf = ".tif"; + if(mWriter->IsA("vtkEPSWriter") != 0) suf = ".eps"; + + mWriter->SetInput(this->GetInput()); + mWriter->SetFileName((mRoot+iString::FromNumber(mFrame,"%05d")+suf).ToCharPointer()); + mWriter->Write(); + mFrame++; + } + + virtual void End() + { + } + + protected: + + FileSetMovieWriter(vtkImageWriter *writer) + { + mWriter = writer; IERROR_ASSERT(mWriter); + mWriter->Register(this); + } + + ~FileSetMovieWriter() + { + mWriter->Delete(); + } + + int mFrame; + iString mRoot; + vtkImageWriter *mWriter; + }; + template class MultiImageMovieWriter : public iGenericMultiImageMovieWriter { public: - static MultiImageMovieWriter* New(iViewModule *vm, const iString &suf) + static MultiImageMovieWriter* New(iViewModule *vm, const iString &suf, vtkImageWriter *writer = 0) { - return new MultiImageMovieWriter(vm,suf); + return new MultiImageMovieWriter(vm,suf,writer); } protected: - MultiImageMovieWriter(iViewModule *vm, const iString &suf) : iGenericMultiImageMovieWriter(vm) + MultiImageMovieWriter(iViewModule *vm, const iString &suf, vtkImageWriter *writer) : iGenericMultiImageMovieWriter(vm,writer) { - mSuffix = suf; + if(!suf.IsEmpty()) mSuffix = "." + suf; } - virtual vtkGenericMovieWriter* CreateWriter() const - { - return T::New(); - } + virtual vtkGenericMovieWriter* CreateWriter() const; virtual const iString& GetFileSuffix() const { @@ -162,6 +229,20 @@ iString mSuffix; }; + + template <> + vtkGenericMovieWriter* MultiImageMovieWriter::CreateWriter() const + { + return FileSetMovieWriter::New(mParentWriter); + } + + + template + vtkGenericMovieWriter* MultiImageMovieWriter::CreateWriter() const + { + return T::New(); + } + iString FrameFileName(int i, const iString &tag, const iString &root) { @@ -179,27 +260,21 @@ // // Other views // - return "v" + iString::FromNumber(i+1,(i<99)?"%02d":"%d") + "-" + root; + return root + "-v" + iString::FromNumber(i+1,(i<99)?"%02d":"%d"); } } else { - return tag + "-" + root; + return root + "-" + tag; } } - - - iString RightEyeFrameFileName(const iString &name) - { - return "re-" + name; - } }; using namespace iWriter_Private; -void iGenericMultiImageMovieWriter::WriteFrame(const iStereoImageArray& images, const iString &path, const iString &root) +void iGenericMultiImageMovieWriter::WriteFrame(const iStereoImageArray& images, const iString &root) { if(mStarted) { @@ -218,7 +293,15 @@ for(i=0; iSetFileName((path+name+"."+this->GetFileSuffix()).ToCharPointer()); + + if(images[i/2].IsStereo()) + { + mImageWriters[i]->SetFileName((name+"-left"+this->GetFileSuffix()).ToCharPointer()); + } + else + { + mImageWriters[i]->SetFileName((name+this->GetFileSuffix()).ToCharPointer()); + } mImageWriters[i]->SetInput(images[i/2].LeftEye().DataObject()); mImageWriters[i]->Start(); // @@ -227,7 +310,7 @@ if(images[i/2].IsStereo()) { mImageWriters[i+1]->SetInput(images[i/2].RightEye().DataObject()); - mImageWriters[i+1]->SetFileName((path+RightEyeFrameFileName(name)+"."+this->GetFileSuffix()).ToCharPointer()); + mImageWriters[i+1]->SetFileName((name+"-right"+this->GetFileSuffix()).ToCharPointer()); mImageWriters[i+1]->Start(); } else @@ -300,8 +383,6 @@ } - - void iWriter::SetImageFormat(int i) { if(ImageFormat::IsValid(i) && i!=mImageFormat) @@ -349,6 +430,15 @@ mImageWriter->AddObserver(vtkCommand::ProgressEvent,this->GetViewModule()->GetProgressEventObserver()); mImageWriter->AddObserver(vtkCommand::EndEvent,this->GetViewModule()->GetProgressEventObserver()); this->GetViewModule()->ClearCache(); + + // + // Reset the animation writer if needed + // + if(mAnimationOutput == AnimationOutput::Image) + { + mAnimationOutput = -1; + this->SetAnimationOutput(AnimationOutput::Image); + } } } @@ -382,9 +472,9 @@ default: { // - // Did not find a movie writer + // File-set movie writer // - mAnimationOutput = 0; + mMovieWriter = MultiImageMovieWriter::New(this->GetViewModule(),"",mImageWriter); IERROR_ASSERT(mMovieWriter); } } this->GetViewModule()->ClearCache(); @@ -414,71 +504,27 @@ } -void iWriter::Start() +void iWriter::StartMovie() { - if(mMovieWriter != 0) - { - mMovieWriter->Start(); - } + IERROR_ASSERT(mMovieWriter); + mMovieWriter->Start(); } -void iWriter::Finish() +void iWriter::FinishMovie() { - if(mMovieWriter != 0) - { - mMovieWriter->Finish(); - mCurrentAnimationImageIndex++; - } -} - - -void iWriter::WriteFrame(const iStereoImageArray& images, int mode) -{ - iString path, root; - int *cur; - - switch(mode) - { - case ImageType::Snapshot: - { - root = mCurrentSnapshotImageFilePrefix; - cur = &mCurrentSnapshotImageIndex; - break; - } - case ImageType::AnimationFrame: - { - root = mCurrentAnimationImageFilePrefix; - cur = &mCurrentAnimationImageIndex; - break; - } - default: - { - IERROR_LOW("Invalid argument to iWriter::WriteFrame."); - return; - } - } - - path = this->GetViewModule()->GetControlModule()->GetShell()->GetEnvironment(Environment::Image); - root += iString::FromNumber(*cur,"-%05d"); - - if(mode==ImageType::Snapshot || mMovieWriter==0) - { - this->WriteImageFrame(images,path,root); - (*cur)++; - } - else - { - this->WriteMovieFrame(images,path,root); - } + IERROR_ASSERT(mMovieWriter); + mMovieWriter->Finish(); } -void iWriter::WriteImageFrame(const iStereoImageArray& images, const iString &path, const iString &root) +void iWriter::WriteImageFrame(const iStereoImageArray& images, const iString &root) { int i; iString suf, name; + IERROR_ASSERT(mImageWriter); + switch(mImageFormat) { case ImageFormat::JPG: { suf = ".jpg"; break; } @@ -497,7 +543,14 @@ name = FrameFileName(i,images[i].GetTag(),root); mImageWriter->SetInput(images[i].LeftEye().DataObject()); - mImageWriter->SetFileName((path+name+suf).ToCharPointer()); + if(images[i].IsStereo()) + { + mImageWriter->SetFileName((name+"-left"+suf).ToCharPointer()); + } + else + { + mImageWriter->SetFileName((name+suf).ToCharPointer()); + } mImageWriter->Write(); // // Right eye @@ -505,22 +558,16 @@ if(images[i].IsStereo()) { mImageWriter->SetInput(images[i].RightEye().DataObject()); - mImageWriter->SetFileName((path+RightEyeFrameFileName(name)+suf).ToCharPointer()); + mImageWriter->SetFileName((name+"-right"+suf).ToCharPointer()); mImageWriter->Write(); } } } -void iWriter::WriteMovieFrame(const iStereoImageArray& images, const iString &path, const iString &root) +void iWriter::WriteMovieFrame(const iStereoImageArray& images, const iString &root) { - if(mMovieWriter != 0) - { - mMovieWriter->WriteFrame(images,path,root); - } - else - { - IERROR_LOW("Cannot write a movie file: a MovieWriter has not been created."); - } + IERROR_ASSERT(mMovieWriter); + mMovieWriter->WriteFrame(images,root); } diff -Nru ifrit-3.3.4/core/iwriter.h ifrit-3.4.2/core/iwriter.h --- ifrit-3.3.4/core/iwriter.h 2011-01-27 17:51:36.000000000 +0000 +++ ifrit-3.4.2/core/iwriter.h 2013-07-11 01:23:32.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -85,9 +85,10 @@ // // Writing functionality // - void Start(); - void WriteFrame(const iStereoImageArray& images, int mode); - void Finish(); + void WriteImageFrame(const iStereoImageArray& images, const iString &root); + void StartMovie(); + void WriteMovieFrame(const iStereoImageArray& images, const iString &root); + void FinishMovie(); void SetImageFormat(int); inline int GetImageFormat() const { return mImageFormat; } @@ -101,9 +102,6 @@ void SetPostScriptOrientation(int); inline int GetPostScriptOrientation() const { return mPostScriptOrientation; } - inline void ResetAnimationImageIndex(int v = 1){ if(v > 0) mCurrentAnimationImageIndex = v; } - inline int GetCurrentAnimationImageIndex() const { return mCurrentAnimationImageIndex; } - protected: virtual ~iWriter(); @@ -112,15 +110,9 @@ iWriter(iViewModule *vm); - void WriteImageFrame(const iStereoImageArray& images, const iString &path, const iString &root); - void WriteMovieFrame(const iStereoImageArray& images, const iString &path, const iString &root); - // // Members // - static int mCurrentSnapshotImageIndex, mCurrentAnimationImageIndex; - static iString mCurrentSnapshotImageFilePrefix, mCurrentAnimationImageFilePrefix; - int mImageFormat, mAnimationOutput; int mPostScriptPaperFormat, mPostScriptOrientation; diff -Nru ifrit-3.3.4/debian/changelog ifrit-3.4.2/debian/changelog --- ifrit-3.3.4/debian/changelog 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/changelog 2013-07-12 15:41:13.000000000 +0000 @@ -1,8 +1,26 @@ -ifrit (3.3.4-3ubuntu1) quantal; urgency=low +ifrit (3.4.2-1) unstable; urgency=low + * QA upload. + * New upstream release. + + Drop existing patches. + * Patch to link in libGL. (Closes: #713651). + * Move debian/rules to dh style with cmake. + * Move to source format 3.0 (quilt). + * Add watch file. + * Make VCS tag canonical. + * Bump debhelper build-dep and compat to 9. + * Bump Standards Version to 3.9.4. + + -- Barry deFreese Thu, 11 Jul 2013 10:06:04 -0400 + +ifrit (3.3.4-4) unstable; urgency=low + + * QA upload. + + [ Ilya Barygin ] * Build-depend on libtiff-dev rather than libtiff4-dev. - -- Ilya Barygin Sat, 29 Sep 2012 15:37:44 +0400 + -- Colin Watson Wed, 08 May 2013 16:18:57 +0100 ifrit (3.3.4-3) unstable; urgency=low diff -Nru ifrit-3.3.4/debian/compat ifrit-3.4.2/debian/compat --- ifrit-3.3.4/debian/compat 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/compat 2013-07-12 11:31:38.000000000 +0000 @@ -1 +1 @@ -7 +9 diff -Nru ifrit-3.3.4/debian/control ifrit-3.4.2/debian/control --- ifrit-3.3.4/debian/control 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/control 2013-07-12 15:39:27.000000000 +0000 @@ -1,13 +1,12 @@ Source: ifrit Section: science Priority: optional -Maintainer: Ubuntu Developers -XSBC-Original-Maintainer: Debian QA Group -Build-Depends: debhelper (>= 7), libvtk5-dev, libqt4-dev, libqt4-opengl-dev, cmake, libncurses5-dev, libtiff-dev, quilt, chrpath -Standards-Version: 3.8.3 +Maintainer: Debian QA Group +Build-Depends: debhelper (>= 9), libvtk5-dev, libqt4-dev, libqt4-opengl-dev, cmake, libncurses5-dev, libtiff-dev, chrpath +Standards-Version: 3.9.4 Homepage: http://sites.google.com/site/ifrithome/ Vcs-Browser: http://git.debian.org/git/users/mhy/ifrit.git -Vcs-Git: git://git.debian.org/git/users/mhy/ifrit.git +Vcs-Git: git://anonscm.debian.org/users/mhy/ifrit.git Package: ifrit Architecture: any diff -Nru ifrit-3.3.4/debian/ifrit.install ifrit-3.4.2/debian/ifrit.install --- ifrit-3.3.4/debian/ifrit.install 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/ifrit.install 2013-07-12 11:31:38.000000000 +0000 @@ -1,2 +1,2 @@ -usr/bin/ifrit -usr/share/applications/ifrit.desktop +./ifrit usr/bin +debian/ifrit.desktop usr/share/applications diff -Nru ifrit-3.3.4/debian/patches/03-link-gl.patch ifrit-3.4.2/debian/patches/03-link-gl.patch --- ifrit-3.3.4/debian/patches/03-link-gl.patch 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/debian/patches/03-link-gl.patch 2013-07-12 15:42:43.000000000 +0000 @@ -0,0 +1,40 @@ +Description: Explicitely link in libGL to fix FTBFS. + There is probably a cleaner fix for this. +Debian-Bug: http://bugs.debian.org/713651 +Author: Barry deFreese +Index: ifrit-3.4.2/build/CMakeLists.txt +=================================================================== +--- ifrit-3.4.2.orig/build/CMakeLists.txt 2013-07-12 09:42:43.000000000 -0400 ++++ ifrit-3.4.2/build/CMakeLists.txt 2013-07-12 10:56:33.000000000 -0400 +@@ -237,14 +237,14 @@ + ADD_DEFINITIONS(-DI_CUSTOM_VP1000) + ENDIF(tmp) + ENDIF(CustomVP1000) +- +-IF(Extension:ART) +- FILE(GLOB tmp ${src}/special/artio/*.c) +- IF(tmp) +- SET(sources ${sources} ${tmp}) +- INCLUDE_DIRECTORIES(${src}/special/artio) +- ENDIF(tmp) +-ENDIF(Extension:ART) ++ ++IF(Extension:ART) ++ FILE(GLOB tmp ${src}/special/artio/*.c) ++ IF(tmp) ++ SET(sources ${sources} ${tmp}) ++ INCLUDE_DIRECTORIES(${src}/special/artio) ++ ENDIF(tmp) ++ENDIF(Extension:ART) + + # + # Create target +@@ -290,7 +290,7 @@ + # + # Add libraries + # +-TARGET_LINK_LIBRARIES(${target} vtkFiltering vtkHybrid vtkRendering) ++TARGET_LINK_LIBRARIES(${target} vtkFiltering vtkHybrid vtkRendering GL) + # + # Optional libraries + # diff -Nru ifrit-3.3.4/debian/patches/series ifrit-3.4.2/debian/patches/series --- ifrit-3.3.4/debian/patches/series 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/patches/series 2013-07-12 14:56:10.000000000 +0000 @@ -1,2 +1 @@ -01-gcc-4.3.diff -02-gcc-4.7.diff +03-link-gl.patch diff -Nru ifrit-3.3.4/debian/rules ifrit-3.4.2/debian/rules --- ifrit-3.3.4/debian/rules 2013-08-11 04:17:14.000000000 +0000 +++ ifrit-3.4.2/debian/rules 2013-07-12 14:23:51.000000000 +0000 @@ -7,10 +7,6 @@ # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 -include /usr/share/quilt/quilt.make - -CFLAGS = -Wall -g - ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else @@ -20,25 +16,18 @@ INSTALL_PROGRAM += -s endif -build: build-arch build-indep -build-arch: build-stamp -build-indep: build-stamp +%: + dh $@ --buildsystem=cmake --sourcedirectory=build -build-stamp: $(QUILT_STAMPFN) - dh_testdir - cd build && cmake -D DESIRED_QT_VERSION:STRING=4 \ - -D QT_LIBRARY_DIR:STRING=/usr/lib/qt4 \ - -D QT_QMAKE_EXECUTABLE:STRING=/usr/bin/qmake-qt4 \ - -D CMAKE_EXE_LINKER_FLAGS:STRING=-Wl,--as-needed \ - -D CMAKE_COLOR_MAKEFILE:BOOL=FALSE \ - . - cd build && $(MAKE) VERBOSE=1 - touch build-stamp +override_dh_autoconfigure: + cd build && cmake \ + -DDESIRED_QT_VERSION:STRING=4 \ + -DQT_LIBRARY_DIR:STRING=/usr/lib/qt4 \ + -DQT_QMAKE_EXECUTABLE:STRING=/usr/bin/qmake-qt4 \ + -DCMAKE_EXE_LINKER_FLAGS:STRING="${CMAKE_EXE_LINKER_FLAGS} -Wl,--as-needed -lGL" \ + -DCMAKE_COLOR_MAKEFILE:BOOL=FALSE -clean: unpatch - dh_testdir - dh_testroot - -cd build && $(MAKE) clean +override_dh_clean: # Clean up stuff which make clean leaves behind rm -f build/CMakeCache.txt build/cmake_install.cmake build/Makefile rm -f configure/iconfiguresettings.ext.h @@ -48,41 +37,6 @@ find -name "\.#*" -delete dh_clean -install: build - dh_testdir - dh_testroot - dh_prep - dh_installdirs - - chrpath --delete ifrit || true - - install -d $(CURDIR)/debian/tmp/usr/bin - install -m0755 ifrit $(CURDIR)/debian/tmp/usr/bin - install -d $(CURDIR)/debian/tmp/usr/share/applications - install -m0644 debian/ifrit.desktop $(CURDIR)/debian/tmp/usr/share/applications - -# Build architecture-independent files here. -binary-indep: build install -# We have nothing to do by default. - -# Build architecture-dependent files here. -binary-arch: build install - dh_testdir - dh_testroot - dh_installchangelogs - dh_installdocs - dh_install --sourcedir=debian/tmp - dh_installmenu - dh_installman - dh_link - dh_strip - dh_compress - dh_fixperms - dh_installdeb - dh_shlibdeps - dh_gencontrol - dh_md5sums - dh_builddeb - -binary: binary-indep binary-arch -.PHONY: build clean binary-indep binary-arch binary install +override_dh_install: + chrpath --delete ifrit + dh_install diff -Nru ifrit-3.3.4/debian/source/format ifrit-3.4.2/debian/source/format --- ifrit-3.3.4/debian/source/format 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/debian/source/format 2013-08-11 04:17:15.076466982 +0000 @@ -0,0 +1 @@ +3.0 (quilt) diff -Nru ifrit-3.3.4/debian/watch ifrit-3.4.2/debian/watch --- ifrit-3.3.4/debian/watch 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/debian/watch 2013-07-12 11:31:38.000000000 +0000 @@ -0,0 +1,2 @@ +version=3 +http://astro.uchicago.edu/%7Egnedin/IFRIT/ifrit-src\.(.+)\.tar\.gz Binary files /tmp/B1qZfdWXBt/ifrit-3.3.4/docs/UserGuide-1side.pdf and /tmp/ePAbPJK35X/ifrit-3.4.2/docs/UserGuide-1side.pdf differ Binary files /tmp/B1qZfdWXBt/ifrit-3.3.4/docs/UserGuide-2side.pdf and /tmp/ePAbPJK35X/ifrit-3.4.2/docs/UserGuide-2side.pdf differ Binary files /tmp/B1qZfdWXBt/ifrit-3.3.4/docs/UserGuide1side.pdf and /tmp/ePAbPJK35X/ifrit-3.4.2/docs/UserGuide1side.pdf differ Binary files /tmp/B1qZfdWXBt/ifrit-3.3.4/docs/UserGuide2side.pdf and /tmp/ePAbPJK35X/ifrit-3.4.2/docs/UserGuide2side.pdf differ diff -Nru ifrit-3.3.4/help/ihelpfactory.cpp ifrit-3.4.2/help/ihelpfactory.cpp --- ifrit-3.3.4/help/ihelpfactory.cpp 2011-01-27 17:52:02.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactory.cpp 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -30,6 +30,7 @@ #include "iconfigure.h" +#include "iconsole.h" #include "ierror.h" #include "ifile.h" #include "iobject.h" @@ -215,7 +216,7 @@ f.WriteLine("//LICENSE A"); f.WriteLine("#if 0"); - f.WriteLine("#include \"../Work/"+outroot+".txt\""); + f.WriteLine("#include \"../../Work/"+outroot+".txt\""); f.WriteLine("#else"); f.WriteLine("static iHelpData data[] = {"); @@ -265,6 +266,9 @@ f.WriteLine("};"); f.WriteLine("#endif"); f.Close(); + + iConsole::Display(iConsole::_Warning,"IFrIT is creating compressed help data...\nPlease compile again and re-run."); + exit(0); } @@ -547,57 +551,16 @@ #ifdef I_DEBUG -void iHelpFactory::CreateUserGuide(UGForm form) +void iHelpFactory::CreateUserGuide() { static const iString afterPartTitle("

 "); iString text, stmp; iHelpDataBuffer *dtmp1; - if(form == _Publish) - { - iHelpFactory::CreateUserGuide(iHelpFactory::_Public); - iHelpFactory::CreateUserGuide(iHelpFactory::_Private); - system("Work\\scripts\\createug.csh"); - return; - } - - iString kind; - switch(form) - { - case _Base: - { - kind = "Base"; - break; - } - case _Public: - { - kind = "Public"; - break; - } - case _Private: - { - kind = "Private"; - break; - } - } - // // Create the title page // stmp = "Title page

\"<h1IFrIT
User Guide\">

by

Nick Gnedin and IFrIT

 

 

 

IFrIT Version " + iVersion::GetVersion() + "

"; - switch(form) - { - case _Public: - { - stmp += "

(Including Public Extensions)

"; - break; - } - case _Private: - { - stmp += "

(Including All Extensions)

"; - break; - } - } // // Create preface @@ -611,7 +574,7 @@ delete dtmp1; } stmp += ""; - WriteFile("Work/docs/ugTitle"+kind+".html",stmp); + WriteFile("Work/docs/ugTitle.html",stmp); // // Create part on user guide @@ -819,45 +782,19 @@ #endif // - // Define what to create + // If extra info is included, remove special and tags // - switch(form) - { - case _Base: - { - // - // Remove everything between and tags - // - text.RemoveFormatting(""); - // - // No break, keep going - // - } - case _Public: - { - // - // Remove everything between and tags - // - text.RemoveFormatting("",""); - break; - } - case _Private: - { - // - // If extra info is included, remove special and tags - // - text.RemoveFormatting(""); - text.Replace("",""); - text.Replace("",""); - text.Replace("",""); - break; - } - } + text.RemoveFormatting(""); + text.Replace("",""); + text.Replace("",""); + text.Replace("",""); // // Create the html file // - WriteFile("Work/docs/ug"+kind+".html","© 2005-2008 by Nick Gnedin"+text+""); + WriteFile("Work/docs/ug.html","© 2005-2012 by Nick Gnedin"+text+""); + + system("Work\\scripts\\createpdf.csh"); } #endif diff -Nru ifrit-3.3.4/help/ihelpfactory.h ifrit-3.4.2/help/ihelpfactory.h --- ifrit-3.3.4/help/ihelpfactory.h 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactory.h 2013-07-11 01:23:44.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -117,15 +117,7 @@ }; #ifdef I_DEBUG - enum UGForm - { - _Publish, - _Base, - _Public, - _Private - }; - - static void CreateUserGuide(UGForm form); + static void CreateUserGuide(); #endif static void CreateTopicList(iString &text); diff -Nru ifrit-3.3.4/help/ihelpfactorydataOR.h ifrit-3.4.2/help/ihelpfactorydataOR.h --- ifrit-3.3.4/help/ihelpfactorydataOR.h 2011-01-27 17:52:00.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataOR.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -25,7 +25,7 @@ =========================================================================*/ #if 0 -#include "../Work/help/ihelpfactorydataOR.txt" +#include "../../Work/help/ihelpfactorydataOR.txt" #else static iHelpData data[] = { {70,71,"or.-d.dp","DataPresent",0, @@ -73,9 +73,9 @@ {50,42,"or.-fvo.gs","GlyphSize",0, "\170\234\13\311\110\125\50\315\313\114\313\57\312\125\50\316\254\112\125\50\311\127\50\116\116\314\111\125\110\314\311\121\110\317\251\54\310\50\126\50\317\54\311\320\3\0\113\314\17\142"}, {738,1653,"or.-svo.c","Color",0, -"\170\234\205\124\115\157\333\60\14\375\53\104\116\11\320\272\351\206\136\266\54\207\25\150\57\3\132\154\305\356\264\114\333\134\144\111\220\344\174\354\327\217\222\355\306\155\12\354\220\0\246\310\307\107\362\221\317\336\72\362\221\51\300\246\334\336\133\155\375\346\246\334\136\245\257\47\207\212\343\151\370\106\123\45\333\63\152\212\221\222\15\2\105\210\55\5\222\177\117\4\356\214\125\133\17\33\4\61\327\337\26\175\123\64\125\241\324\142\53\0\277\231\16\360\124\376\41\25\103\102\331\334\240\240\37\132\126\55\240\47\360\344\274\100\232\110\25\140\200\140\65\127\20\172\137\243\22\334\345\223\43\363\370\3\234\325\247\306\32\324\320\121\150\127\160\75\103\100\255\141\236\5\350\250\310\145\252\147\116\326\27\207\201\217\325\175\107\23\23\260\71\246\200\227\217\353\122\150\240\44\40\26\60\17\101\241\106\17\313\333\153\145\73\147\215\260\136\201\124\216\336\343\111\310\166\275\216\74\173\273\202\212\204\177\305\246\1\153\62\241\170\162\4\266\176\113\356\277\15\113\356\47\41\242\255\40\105\13\113\325\222\332\11\172\120\236\135\144\153\206\21\4\107\212\153\126\143\131\203\261\263\322\244\212\42\262\16\253\342\45" -"\45\236\115\176\252\366\4\21\167\122\61\302\347\163\5\360\363\361\73\354\121\367\22\243\154\105\133\66\261\30\177\233\233\154\201\245\346\35\301\247\273\273\142\135\254\163\102\117\325\52\167\364\235\250\346\215\235\222\325\332\142\114\375\161\126\60\301\364\135\51\215\56\51\36\210\14\254\263\14\157\7\65\306\1\160\256\310\1\45\75\110\60\65\22\231\311\136\211\11\43\160\310\146\57\2\33\325\125\133\255\355\41\174\1\36\46\60\224\46\176\316\6\216\274\227\110\316\161\11\330\244\116\227\64\302\127\164\234\346\366\332\345\371\0\35\26\274\330\272\211\34\156\277\136\44\61\324\340\145\22\241\325\261\351\303\145\236\21\354\134\375\150\110\261\236\366\344\3\125\5\74\110\307\351\210\235\323\311\163\314\46\10\267\160\140\331\214\100\132\224\40\17\321\143\305\111\52\262\104\36\331\224\366\160\316\40\333\244\151\36\175\375\66\74\145\177\27\4\145\57\125\14\252\236\330\310\62\124\62\204\245\143\263\113\54\107\321\153\252\243\354\2\372\35\224\143\57\306\27\317\115\33\105\54\17\54\264\364\351\115\1\177\311\333\13\22\271\367\122\301\242\314\241\206\102\130\314\312\220\75\35\57\103\162\36\266\40\245\123\111" -"\356\302\257\74\101\150\121\366\46\45\140\131\20\325\173\237\204\236\35\106\200\63\364\353\304\123\214\124\251\61\11\111\144\161\236\253\170\214\147\141\217\236\261\224\66\366\141\160\312\230\63\42\303\116\314\320\247\116\312\225\61\66\46\255\115\215\34\357\357\354\172\35\363\161\270\367\126\342\176\11\230\14\362\365\72\174\354\373\341\245\13\263\144\123\123\162\321\370\21\261\145\276\73\225\205\24\321\342\76\111\304\123\323\247\162\163\264\234\270\60\357\306\72\57\135\143\62\156\75\124\337\25\377\0\56\45\100\63"}, +"\170\234\205\124\301\156\333\60\14\375\25\42\247\4\110\335\164\103\57\133\226\303\12\264\227\1\55\266\142\167\132\246\155\55\262\44\110\162\34\357\353\107\311\166\355\66\1\166\110\0\123\344\343\43\371\310\27\147\54\271\40\311\303\76\77\74\30\145\334\376\66\77\154\343\327\263\105\41\103\77\174\243\56\242\355\5\25\205\100\321\6\236\2\204\232\74\361\277\43\2\73\143\225\306\301\36\201\315\345\267\125\133\145\125\221\11\261\72\60\300\157\111\35\74\347\177\110\4\37\121\366\267\310\350\135\55\105\15\350\10\34\131\307\220\72\120\1\350\301\33\45\13\360\255\53\121\60\356\372\331\222\176\372\1\326\250\276\62\32\25\64\344\353\15\334\54\20\120\51\130\146\1\72\13\262\211\352\314\311\270\254\33\370\30\325\66\64\61\1\223\142\62\170\275\136\227\100\15\71\1\111\6\163\340\5\52\164\260\276\273\21\246\261\106\63\353\15\160\345\350\34\366\114\266\151\125\220\213\267\55\24\304\374\13\251\53\60\72\21\12\275\45\60\345\173\162\377\155\130\164\357\231\210\62\214\24\14\254\105\115\342\310\350\136\70\151\203\64\172\30\201\267\44\144\51\305\130\326\140\154\14\67\251\240\200\122\371\115\366\32" +"\23\57\46\77\125\333\103\300\43\127\214\360\171\256\0\176\76\175\207\23\252\226\143\204\51\350\40\165\330\216\277\375\155\262\300\132\311\43\301\247\373\373\355\156\273\113\11\35\25\233\324\321\17\242\132\66\166\112\126\52\203\41\366\307\32\306\4\335\66\71\67\72\247\320\21\151\330\45\31\336\15\152\14\3\340\122\221\3\112\174\340\140\252\70\62\221\335\262\11\3\110\237\314\216\5\66\252\253\64\112\231\316\177\1\71\114\140\50\215\375\254\361\62\310\23\107\312\24\27\201\165\354\164\116\43\174\101\347\151\156\157\135\136\16\320\142\46\127\7\73\221\303\303\327\213\44\232\52\274\114\302\264\32\251\133\177\231\147\4\233\253\37\15\61\326\321\211\234\247\42\203\107\356\70\235\261\261\52\172\216\331\30\341\16\72\311\233\341\111\261\22\370\41\70\54\144\224\12\57\221\103\251\163\323\315\31\170\233\24\55\243\157\336\207\307\354\37\202\40\157\271\212\101\325\23\33\136\206\202\207\260\266\122\37\43\313\121\364\212\312\300\273\200\356\10\371\330\213\361\305\311\252\16\54\226\107\311\264\124\377\256\200\277\344\314\5\211\324\173\256\140\225\247\120\115\336\257\26\145\360\236\216\227\41\72\17\133\20\323\211" +"\50\167\346\227\367\340\153\344\275\211\11\44\57\210\150\235\213\102\117\16\43\300\14\375\66\361\30\303\125\52\214\102\142\131\314\163\145\217\361\54\234\320\111\314\271\215\255\37\234\22\346\202\310\260\23\13\364\251\223\174\145\264\11\121\153\123\43\307\373\273\270\136\347\164\34\36\234\341\270\137\14\306\203\174\273\16\327\175\257\136\72\277\110\66\65\45\25\215\327\210\255\323\335\51\14\304\210\32\117\121\42\216\252\66\226\233\242\371\304\371\145\67\166\151\351\52\235\160\313\241\372\46\373\7\14\375\100\53"}, { 0U, 0, "or.-svo.o","Opacity",0, "&:or.-svo.c"}, { 0U, 0, "or.-svo.p","Palette",0, @@ -111,17 +111,6 @@ {321,575,"or.a","Animator",0, "\170\234\135\221\101\156\203\60\20\105\257\362\305\252\225\42\162\1\32\251\313\256\323\13\14\60\6\253\306\103\355\1\312\355\73\70\125\22\165\207\214\377\274\371\317\115\173\171\217\176\42\225\324\234\333\13\272\304\244\234\101\310\234\274\175\210\103\216\64\347\121\64\343\245\242\162\331\113\254\136\153\174\50\72\212\230\244\367\156\207\216\214\334\161\144\264\254\33\163\274\235\54\155\346\357\205\243\76\315\361\321\0\53\31\40\355\7\141\243\75\237\340\222\114\230\3\331\337\44\132\50\120\201\223\20\144\363\161\260\114\107\23\47\302\114\72\236\100\261\107\20\352\237\31\75\51\301\371\160\124\60\342\314\235\167\236\173\43\52\247\225\102\176\114\54\353\361\52\141\51\44\133\343\336\300\146\147\360\117\331\245\204\321\20\306\304\356\255\132\206\232\162\355\253\77\155\107\362\272\314\263\44\155\316\164\251\361\151\63\356\222\212\236\254\224\24\233\327\321\12\250\327\300\266\377\300\267\375\315\363\104\41\130\217\101\140\251\201\113\246\145\364\76\33\177\277\341\171\75\114\75\346\272\144\42\152\64\377\137\317\242\233\244\57\260\321\70\241\335\261\344\303\234\57\322\115\101\244\140\57\253\152\207\146\134\312\225\207\340\103" "\300\163\323\334\35\115\237\50\270\166\311\317\172\300\112\335\137\24\0\314\233"}, -{116,143,"or.a.cpc","CameraPathClosed",0, -"\170\234\125\212\73\16\302\60\14\206\257\362\253\23\54\51\335\323\110\354\14\134\301\15\256\34\251\324\221\35\350\365\211\272\61\176\217\73\374\50\55\13\232\120\203\127\316\145\55\354\70\204\233\260\165\315\210\4\61\136\347\101\55\120\360\41\145\172\263\21\52\65\211\43\45\24\7\41\157\352\374\302\246\132\161\211\113\172\366\372\350\60\117\161\134\322\25\152\240\35\132\171\107\376\330\227\377\247\333\71\205\37\325\32\57\251"}, -{187,289,"or.a.cpd","CameraPathDemo",0, -"\170\234\115\217\101\212\303\60\14\105\257\42\272\56\51\263\157\3\163\207\136\100\304\162\54\160\244\40\51\23\162\373\332\311\54\12\132\210\57\301\173\377\135\330\241\15\12\340\24\254\2\253\351\112\26\307\35\320\235\147\141\231\341\7\102\201\3\46\334\234\34\242\120\133\27\62\354\171\326\132\165\77\303\47\102\61\312\257\233\332\200\203\337\306\377\257\25\243\74\37\70\302\316\121\164\213\316\332\260\326\3\252\142\352\4\224\3\204\166\110\30\10\231\153\243\250\165\227\264\115\327\235\27\74\375\134\160\365\242\1\55\230\311\7\370\315\101\166\342\23\55\52\36\166\75\152\376\26\355\12\367\357\340\217\33\256\65\67\362\120\243\164\125\354\130\236\131\260\202\7\6\15\37\265\35\150\200"}, -{320,622,"or.a.cpx","CameraPathX",0, -"\170\234\155\221\115\156\203\100\14\205\257\142\145\35\221\13\120\66\125\267\155\245\166\221\144\147\30\23\106\142\74\310\36\110\271\175\75\120\224\37\165\301\302\306\176\357\363\233\117\211\3\111\362\244\120\326\325\53\6\22\374\304\324\35\313\103\135\355\37\173\247\265\207\354\36\373\347\334\7\245\4\307\75\234\326\201\63\64\61\212\363\214\311\244\143\13\251\43\30\242\347\144\25\57\125\211\320\11\265\57\273\50\5\26\272\253\232\105\21\6\223\54\17\130\25\360\335\221\222\315\12\331\356\15\24\205\354\23\234\165\365\42\154\272\77\213\0\141\324\4\35\116\264\170\360\30\152\222\374\263\211\141\210\114\331\137\7\152\174\353\311\101\75\377\103\302\203\261\274\57\213\37\355\355\312\257\104\203\146\256\15\145\56\340\355\47\31\360\235\364\112\241\33\37\134\175\337\103\115\340\57\34\205\334\312\33\274\252\347\313\375\336\66\67\262\243\326\63\271\355\370\247\263\103\324\324\317\60\252\301\267\121\100\161\312\112\131\125\110\123\224\134\345\223\54\150\22\306\36\64\331\13\354\301\14\233\65\222\273\224\301\353\242\150\44\74\21\173\103\61\361\20\335\232\316\242\201\115\362\23\131\373\352\155\41\13\204\150\366\206" -"\260\131\75\247\327\75\274\244\275\5\273\236\226\344\212\137\204\377\335\307"}, -{ 0U, 0, "or.a.cpy","CameraPathY",0, -"&:or.a.cpx"}, -{ 0U, 0, "or.a.cpz","CameraPathZ",0, -"&:or.a.cpx"}, {292,534,"or.a.dp","Phi",0, "\170\234\125\120\111\156\303\60\14\374\12\221\123\2\4\352\7\122\337\173\13\212\176\200\226\231\110\200\54\272\24\35\67\175\175\51\71\113\163\33\222\303\341\160\216\302\23\211\106\52\160\350\273\143\210\207\267\276\333\127\374\25\110\161\255\60\17\265\363\311\51\325\6\170\316\52\234\100\3\331\354\234\154\171\33\63\14\164\26\242\262\203\376\12\113\210\76\64\102\361\224\11\142\1\141\105\245\1\172\322\205\50\267\241\56\134\325\12\175\317\121\343\205\340\44\70\122\161\377\314\334\257\77\374\0\12\301\134\146\114\120\246\100\22\275\241\325\306\36\242\43\7\123\210\60\104\41\257\221\163\75\35\130\342\257\231\156\304\241\136\126\174\145\134\152\10\46\344\136\36\155\252\165\374\370\324\216\363\274\112\0\376\330\144\102\301\224\310\302\340\147\223\117\15\173\373\105\20\266\230\157\134\222\211\362\20\375\234\120\356\13\123\102\313\347\266\121\274\45\230\167\16\76\326\174\16\10\101\350\364\276\141\161\350\312\246\63\167\72\217\175\242\346\157\344\301\0\166\215\373\374\307\304\132\330\25\373\140\276\153\62\205\201\163\272\256\261\263\336\63\173\41\217\250\112\122\334\37\270\142\272\272"}, { 0U, 0, "or.a.dr","Roll",0, @@ -130,26 +119,15 @@ "&:or.a.dp"}, {78,82,"or.a.dz","Zoom",0, "\170\234\35\311\321\11\200\60\14\5\300\125\336\4\356\340\50\155\174\265\1\155\260\211\26\235\136\361\357\340\146\74\146\273\266\25\45\111\130\107\276\61\252\112\105\124\302\205\215\120\377\220\66\56\310\214\101\266\377\142\30\304\232\363\70\65\364\42\112\117\73\175\172\1\325\245\36\71"}, -{179,328,"or.a.fpe","FocalPathEnabled",0, -"\170\234\155\217\321\15\203\60\14\104\127\261\30\40\135\200\42\165\207\166\0\23\22\142\11\142\344\270\215\330\276\201\360\101\53\176\42\347\174\176\76\77\40\145\122\33\100\3\52\50\217\343\344\122\371\70\360\154\161\202\205\51\52\54\250\301\300\363\102\5\112\200\265\302\211\343\10\71\320\116\373\265\262\337\45\213\263\23\204\231\77\145\111\16\56\236\325\102\232\121\154\240\102\251\254\255\331\42\4\161\376\336\260\30\64\251\351\16\367\266\262\275\141\147\340\225\266\211\236\65\234\151\65\122\34\56\157\51\374\211\163\271\223\41\55\316\222\137\213\25\120\172\122\101\131\241\274\61\171\226\31\225\70\376\245\37\336\102\107\70\214\124\55\346\13\356\206\165\213"}, -{163,229,"or.a.fpp","FocalPathToPoint",0, -"\170\234\135\216\61\16\302\60\14\105\257\142\165\202\245\25\173\32\211\5\211\215\201\13\270\251\103\54\265\161\24\33\365\372\244\205\211\315\376\366\173\366\25\164\143\13\11\54\241\201\26\12\34\231\24\266\104\226\250\266\230\300\41\244\112\161\354\244\366\330\307\102\235\217\22\160\201\42\234\15\12\132\162\3\172\140\205\40\153\251\244\112\63\260\11\40\50\347\327\102\277\315\223\233\374\155\47\37\173\373\150\334\123\216\162\274\270\141\362\347\36\356\371\373\110\100\245\343\166\300\225\52\356\352\103\321\154\140\262\141\235\365\137\76\277\353\61\155\320\226\244\305\230\171\105\143\311\375\7\121\15\121\171"}, -{281,561,"or.a.fpx","FocalPathX",0, -"\170\234\175\220\115\116\304\60\14\205\257\142\165\135\165\56\120\272\101\260\204\112\314\142\146\166\156\352\322\110\115\34\305\51\250\267\47\77\105\120\61\142\21\51\261\363\336\373\354\336\263\43\37\64\11\264\103\367\314\12\227\36\303\174\151\117\103\127\37\112\327\122\102\73\36\312\267\124\6\241\0\227\32\256\245\177\3\305\354\107\155\61\104\137\236\40\314\4\216\265\15\361\145\313\53\112\363\105\241\41\217\60\45\277\362\47\336\227\205\77\5\164\371\332\42\314\236\246\207\212\175\203\215\124\335\56\111\26\355\11\73\60\74\122\3\347\231\204\242\300\123\164\377\231\12\75\305\343\161\223\302\106\250\346\35\311\200\131\45\300\214\37\224\203\354\152\6\362\251\251\330\70\266\224\170\305\221\322\223\246\21\206\355\16\216\165\21\350\45\13\137\247\307\14\226\266\362\26\310\111\206\333\121\266\14\370\75\146\32\336\340\6\3\301\250\5\207\45\332\257\242\355\373\235\204\311\121\325\375\336\370\223\315\202\264\367\103\102\15\354\63\271\47\221\150\30\127\311\200\220\154\227\175\375\377\204\270\143\310\231\373\44\370\23\322\174\1\357\225\303\20"}, -{ 0U, 0, "or.a.fpy","FocalPathY",0, -"&:or.a.fpx"}, -{ 0U, 0, "or.a.fpz","FocalPathZ",0, -"&:or.a.fpx"}, {159,210,"or.a.fs","FlybySpeed",0, "\170\234\115\216\275\16\202\100\20\204\137\145\102\255\147\142\215\44\126\66\46\66\276\300\2\213\154\2\167\170\173\7\342\323\273\32\143\354\146\177\346\233\71\242\241\221\43\101\47\346\26\342\221\172\106\111\350\43\167\207\42\104\107\116\213\252\33\326\155\275\102\323\72\160\271\243\152\3\122\214\114\232\243\271\354\102\150\105\23\371\206\115\176\221\51\322\314\203\242\346\264\60\33\171\11\150\202\127\276\147\111\62\63\272\150\217\352\160\265\310\237\135\376\300\126\347\62\261\77\235\221\275\44\335\140\221\324\177\32\326\41\373\126\374\315\304\3\52\117\333\360\173\334\273\27\44\10\112\0"}, -{220,398,"or.a.is","InheritSettings",0, -"\170\234\225\220\101\156\302\100\14\105\257\362\305\272\32\172\200\20\211\45\153\172\1\147\342\60\106\311\14\265\35\220\70\175\47\1\241\262\104\362\352\333\377\373\331\173\330\115\74\46\170\42\207\135\70\312\40\334\343\226\330\23\153\225\31\222\235\65\323\10\143\167\311\47\103\31\326\106\103\110\312\303\156\123\64\320\246\155\272\166\237\145\42\57\332\154\273\266\331\122\213\322\235\71\72\110\31\312\116\222\37\331\371\335\77\237\202\305\40\157\21\70\106\225\213\277\222\304\60\33\367\1\207\1\165\354\220\53\236\370\361\211\264\373\136\6\277\76\217\65\47\165\103\175\102\2\215\377\156\224\54\56\64\312\275\22\173\301\235\265\4\374\244\212\121\213\177\147\271\322\310\331\227\136\254\306\352\101\343\276\254\122\256\41\217\5\125\100\54\323\104\271\7\331\112\67\210\232\277\304\347\47\155\205\12\177\55\361\212\7"}, -{299,548,"or.a.lf","LogoFile",0, -"\170\234\205\220\121\113\303\60\24\205\377\312\141\40\154\120\72\361\171\356\101\160\143\352\264\17\305\367\273\64\135\3\151\156\111\122\147\377\275\67\53\353\104\21\237\222\264\367\236\363\235\123\66\32\216\132\15\256\21\345\136\33\253\161\62\261\71\277\114\113\107\215\310\70\150\364\101\127\240\0\202\345\43\43\64\174\162\140\7\375\241\375\0\162\62\33\215\274\203\243\116\176\306\161\71\107\71\351\264\175\210\111\311\244\275\253\43\173\331\14\350\135\245\175\210\314\25\16\3\336\313\147\314\237\212\307\155\206\342\165\237\341\141\137\144\50\167\233\115\46\126\225\174\333\56\162\274\44\220\263\266\140\371\204\330\223\265\3\102\53\107\6\123\177\13\41\246\123\76\375\251\264\256\2\356\156\157\56\24\177\361\213\112\224\76\254\115\340\101\221\225\22\52\111\76\346\262\23\0\24\271\64\322\131\122\62\362\63\142\357\241\330\73\11\370\333\160\334\237\72\137\21\32\257\353\373\31\373\234\162\333\315\326\51\146\301\301\244\351\25\55\327\350\74\167\332\307\141\354\302\110\171\334\221\62\161\300\74\172\162\241\223\62\234\32\26\27\50\305\56\172\266\211\375\37\233\267\121\147\265\244\253\113\376\5\116\355\275\366"}, +{300,548,"or.a.lf","LogoFile",0, +"\170\234\165\220\301\152\303\60\20\104\177\145\10\24\22\60\116\351\331\315\241\320\204\266\111\233\203\351\175\43\313\261\100\326\32\111\156\352\277\357\52\46\116\151\311\111\222\275\73\363\146\312\106\303\121\253\301\65\242\334\153\143\65\116\46\66\347\227\151\351\250\21\31\7\215\76\350\12\24\100\260\174\144\204\206\117\16\354\240\277\264\37\100\116\146\243\221\167\160\324\311\317\70\56\347\50\47\235\266\17\61\51\231\264\167\165\144\57\233\1\275\253\264\17\221\271\302\141\300\147\371\206\371\353\376\171\223\141\377\276\313\360\264\333\147\50\137\326\353\114\254\52\371\266\131\344\330\46\220\263\266\140\371\204\330\223\265\3\102\53\107\6\123\377\12\41\246\123\76\375\255\264\256\2\36\356\357\56\24\267\370\105\45\112\37\326\46\360\240\310\112\11\225\44\37\163\331\11\0\212\134\32\351\54\51\31\371\33\261\367\120\354\235\4\374\157\70\356\117\235\27\204\306\353\372\161\306\76\247\334\332\331\52\305\334\262\72\117\27\264\134\241\363\334\151\37\207\261\13\43\345\161\107\312\304\1\363\350\311\205\116\312\160\152\130\134\240\24\273\350\331\46\366\133\66\74\332\174\214\72\305\222\256\56\371\17\77\155\275\325" +""}, +{161,280,"or.a.ll","LogoLocation",0, +"\170\234\175\316\261\16\203\60\14\4\320\137\71\61\267\100\313\206\102\366\112\214\375\201\64\165\102\244\20\43\47\250\277\337\60\61\265\243\345\247\273\173\56\204\215\163\50\201\23\330\241\324\133\31\54\102\156\152\130\132\323\106\327\350\310\236\21\126\343\111\165\106\243\322\303\145\53\104\251\305\43\25\362\44\110\373\372\42\311\160\302\53\172\24\306\0\43\4\143\55\155\205\336\27\230\372\344\30\371\223\107\265\107\255\142\320\373\266\221\134\43\271\2\313\222\110\106\314\265\155\146\153\216\115\123\177\42\11\176\371\241\156\207\252\271\177\243\356\47\372\23\65\250\256\116\373\2\327\311\143\174"}, {147,204,"or.a.lo","LogoOpacity",0, "\170\234\125\216\101\16\202\60\20\105\257\362\303\112\22\104\331\43\247\160\345\156\320\151\231\330\316\220\266\142\274\275\204\30\243\313\277\170\377\275\363\304\260\231\256\122\136\60\207\262\316\236\60\45\166\247\312\122\113\155\160\325\20\314\33\44\222\347\376\100\103\3\57\13\53\50\203\340\202\121\21\365\230\115\264\100\37\161\344\4\227\54\342\210\142\350\132\134\70\331\327\21\351\316\171\323\154\247\45\221\346\231\22\257\354\116\164\221\54\143\340\272\301\163\222\360\127\326\175\120\51\310\26\344\206\235\232\356\177\370\272\175\3\50\312\107\101"}, -{161,280,"or.a.lp","LogoPosition",0, -"\170\234\175\316\301\16\202\60\20\4\320\137\231\160\126\100\271\221\322\273\211\7\17\376\100\305\155\151\122\272\144\133\342\357\133\22\23\116\162\334\354\313\314\74\47\302\302\311\147\317\21\154\221\313\255\14\46\41\73\124\54\265\251\203\255\164\140\307\360\263\161\244\32\243\121\350\346\322\50\104\261\306\55\146\162\44\210\353\374\42\111\260\302\63\132\144\106\7\43\4\63\216\264\144\172\237\140\312\223\103\340\117\352\325\32\264\12\136\257\313\102\162\16\144\63\106\226\110\322\343\136\332\36\277\115\103\273\43\361\156\372\243\56\233\52\271\207\121\327\35\35\104\165\252\51\323\276\366\61\143\354"}, {140,187,"or.a.ls","LoadScriptFile",0, "\170\234\125\316\301\15\203\60\14\205\341\125\236\70\265\207\302\2\151\244\356\320\5\114\10\215\53\32\43\333\10\261\175\21\364\322\1\276\377\275\147\141\303\252\354\371\46\165\332\160\241\344\54\365\212\131\145\316\352\33\46\241\301\100\30\171\312\130\331\13\274\144\4\102\321\74\336\233\345\325\132\152\271\211\124\371\103\56\12\113\312\263\207\216\42\250\16\340\152\256\113\162\373\167\242\55\65\61\364\361\361\163\241\353\343\201\244\177\347\344\160\301\142\371\100\147\21\343\36\77\127\366\207\326\176\1\53\265\101\217"}, {126,174,"or.a.nb","NumberOfBlendedFrames",0, @@ -157,24 +135,14 @@ {346,685,"or.a.nf","NumberOfFrames",0, "\170\234\215\222\321\152\204\60\20\105\177\345\76\266\260\225\135\366\17\12\155\351\103\241\17\373\3\243\216\232\66\46\66\231\254\353\337\167\242\262\153\241\224\202\204\150\62\367\236\271\316\251\143\270\324\227\34\340\33\64\201\172\216\150\174\0\123\325\301\270\41\11\152\22\102\143\54\27\70\165\46\302\17\142\274\103\105\16\45\43\105\256\365\42\42\237\71\220\305\110\123\54\360\234\45\56\324\17\226\167\60\15\46\237\320\321\231\341\235\235\164\341\131\60\327\221\126\6\303\161\247\112\306\265\220\215\105\256\312\66\125\140\22\206\356\310\231\236\346\63\305\15\136\326\175\100\143\247\207\162\322\352\340\123\333\345\312\260\200\57\352\5\136\67\20\204\261\363\152\277\234\145\251\153\217\312\241\62\221\105\26\230\137\342\31\364\155\246\277\342\171\47\301\333\371\166\34\130\363\30\215\164\352\141\64\303\374\361\106\255\275\15\226\46\256\377\210\350\43\105\301\161\377\203\111\125\46\125\265\66\107\276\50\344\360\16\112\252\356\253\41\41\160\233\54\5\274\275\77\275\40\212\306\326\27\170\374\157\77\342\161\330\357\146\20\276\10\253\354\34\343\215\76\17\306\141\277\172\106\334\315\256\307\255\316\212\143\144\201\215" "\222\127\353\375\47\364\321\46\63\100\155\232\206\3\273\112\153\112\226\221\131\247\47\225\221\277\22\273\315\270\105\120\120\134\57\150\363\377\277\57\276\1\236\331\363\156"}, -{162,242,"or.a.nph","NumberOfCameraPathHandles",0, -"\170\234\145\216\101\16\302\40\20\105\257\362\303\332\340\5\264\153\67\356\274\300\0\323\102\4\246\241\324\332\333\113\133\27\46\256\337\373\57\377\341\31\171\116\206\13\244\207\362\224\135\344\111\101\62\152\103\27\202\57\334\137\225\24\115\172\122\235\245\304\205\60\122\365\227\63\165\32\267\143\1\52\214\171\142\207\52\10\271\66\311\326\360\342\270\42\111\31\375\136\373\31\303\254\160\205\206\41\344\141\143\251\5\144\316\16\113\250\207\234\244\345\64\356\322\302\337\133\15\306\210\104\117\376\313\245\115\353\43\277\203\211\174\202\231\353\256\114\226\63\37\320\26\131\34\73\375\1\31\102\125\301"}, -{289,570,"or.a.nps","NumberOfCameraPathSteps",0, -"\170\234\215\221\101\122\303\60\14\105\257\242\351\72\15\145\137\272\144\206\65\134\100\115\144\242\301\266\202\144\267\315\355\121\222\16\315\212\141\147\113\372\172\337\337\37\3\101\256\351\114\12\22\300\12\215\6\30\45\177\102\361\316\21\141\120\12\57\73\321\26\133\333\235\72\114\244\10\43\226\341\370\204\247\26\336\362\62\270\251\103\222\236\232\155\65\311\205\266\133\227\51\311\264\340\140\164\164\120\237\364\145\341\321\147\203\42\2\66\210\226\165\33\146\116\130\130\62\134\71\106\27\213\213\225\274\126\225\342\324\302\73\105\352\12\337\51\235\250\372\365\217\327\155\115\7\121\127\244\61\322\355\1\62\110\70\301\331\321\220\45\357\213\362\205\61\102\101\373\152\341\325\25\164\303\204\256\151\200\3\114\122\1\365\327\247\103\20\214\276\53\345\216\146\174\340\350\61\134\271\14\15\30\116\15\74\37\16\153\261\161\115\17\66\122\307\201\251\367\306\232\210\255\341\160\134\363\134\243\376\337\173\74\267\32\373\331\273\123\16\260\177\350\357\123\112\330\15\116\230\113\344\164\331\144\177\236\226\163\341\104\313\41\242\225\305\306\374\53\325\334\141\35\333\37\353\207\307\362"}, {184,262,"or.a.nt","NumberOfTransitionFrames",0, "\170\234\55\217\61\216\303\60\14\4\277\262\110\35\70\37\360\271\270\342\312\124\371\0\165\136\105\2\54\51\241\350\4\376\175\44\73\35\301\345\142\206\267\100\344\65\71\52\212\307\177\311\225\317\65\132\174\21\136\45\261\302\202\30\104\11\267\60\317\234\141\345\116\13\255\360\16\314\20\144\276\61\213\11\174\134\210\130\241\224\171\300\55\264\361\241\345\101\265\255\257\153\114\161\21\155\175\214\202\240\364\77\247\242\203\14\331\235\246\321\115\327\65\375\36\210\277\235\74\136\334\64\136\144\72\303\255\206\222\227\355\120\250\207\31\304\133\223\370\142\73\363\214\262\173\175\305\273\163\225\127\63\216\271\61\133\204\230\344\316\275\320\342\376\32\267\176\66\174\0\3\276\134\203"}, -{77,81,"or.a.pop","PositionOnPath",0, -"\170\234\25\312\261\21\200\60\14\4\301\126\76\204\204\36\50\105\170\36\254\0\131\43\211\200\356\61\341\355\334\156\120\53\136\14\170\14\147\324\213\352\122\110\147\323\123\231\63\211\46\67\103\340\43\265\164\30\226\54\72\354\271\17\306\212\11\377\344\122\175\373\0\331\23\35\275"}, -{76,85,"or.a.rc","RestoreCamera",0, -"\170\234\55\312\321\15\200\40\14\5\300\125\336\4\356\340\50\25\36\151\23\1\323\126\131\137\77\374\275\334\216\130\226\105\221\52\211\270\130\254\31\3\113\231\112\377\230\50\322\211\307\270\20\72\357\263\342\40\234\221\323\131\41\55\377\46\303\272\244\315\261\275\102\275\37\150"}, -{816,1930,"or.a.s","Style",0, -"\170\234\205\125\115\217\323\60\20\375\53\43\116\273\122\151\371\72\255\112\45\44\204\304\11\4\234\270\115\343\311\306\273\216\47\330\316\206\362\353\231\261\235\154\150\27\220\172\150\354\361\314\173\317\157\306\357\240\247\324\261\1\156\41\5\364\261\345\320\143\262\354\165\5\41\66\344\11\216\224\46\42\17\251\43\110\23\103\34\217\221\176\214\344\23\264\1\173\212\133\370\46\133\255\15\261\256\344\174\262\204\336\326\164\66\302\20\330\214\15\31\11\341\76\157\67\143\10\232\45\227\331\302\273\66\121\310\33\253\124\33\370\370\41\174\374\6\15\372\107\210\71\250\200\223\317\374\345\351\347\134\334\12\172\277\140\150\355\3\301\204\247\170\263\37\335\141\357\354\141\177\74\304\44\260\32\270\372\232\116\216\336\276\270\336\357\216\207\233\125\126\303\24\301\163\202\246\103\177\113\5\62\326\374\211\313\237\102\273\34\230\254\163\163\60\173\167\2\333\12\244\11\14\46\71\146\235\244\303\100\340\30\15\231\355\176\247\60\12\224\300\202\205\166\261\101\107\63\240\227\27\200\112\124\204\53\364\162\133\203\152\212\116\312\344\143\361\32\314\30\254\277\75\23\375\170\22\314\103\40\103\255\365\42\74\366\74\212\334\127" -"\221\222\0\116\35\354\21\272\100\355\333\147\34\266\270\65\303\63\5\364\271\263\132\175\277\303\303\346\74\42\345\10\241\235\360\257\61\41\307\174\141\347\36\103\24\365\131\330\257\34\366\376\73\163\77\307\251\105\6\12\311\12\243\77\64\112\143\177\174\124\347\325\205\72\145\77\352\315\43\210\111\214\334\126\213\261\123\21\236\122\146\3\166\53\327\147\323\177\165\375\213\204\266\164\203\261\201\232\54\165\352\120\174\354\170\222\263\305\6\261\234\255\150\312\71\165\214\164\202\374\20\274\155\304\127\204\151\14\305\305\75\336\53\320\5\144\254\111\73\236\162\261\251\143\67\23\26\214\245\35\255\330\160\255\124\353\116\317\245\156\125\352\365\112\251\106\34\33\304\213\116\324\225\205\300\343\155\227\67\36\154\34\321\331\137\305\63\163\176\126\50\25\275\160\22\11\32\212\61\53\31\360\116\130\163\70\125\72\63\11\1\305\123\314\355\301\315\30\201\253\110\142\26\353\66\160\34\323\5\217\36\117\271\315\216\31\206\325\113\316\122\260\264\177\355\337\114\261\16\1\221\202\36\164\106\340\275\220\150\264\243\244\232\365\121\313\147\265\126\114\321\151\327\303\300\326\47\105\65\141\60\145\137\146\116\100\7\3\206\245" -"\112\35\101\271\241\223\254\53\321\201\243\235\147\341\52\257\241\201\274\131\350\255\155\335\154\7\351\41\161\361\135\265\105\317\206\324\331\67\263\143\304\336\161\320\115\31\112\147\161\353\32\31\103\274\234\224\63\244\315\222\17\205\211\43\367\257\144\75\77\250\132\216\243\112\307\213\6\362\265\146\57\227\40\332\257\370\253\131\324\115\177\30\254\346\34\120\306\107\165\331\233\352\62\231\320\126\263\142\246\47\246\101\163\67\112\66\275\125\41\40\214\365\25\160\250\157\100\205\137\207\147\147\233\16\4\235\342\104\155\216\234\276\230\260\154\136\320\171\252\255\267\360\151\351\140\235\71\54\273\241\226\326\367\103\134\266\224\257\72\254\355\376\130\111\374\253\376\120\347\234\135\176\56\236\175\22\53\251\130\146\277\272\70\267\152\145\46\220\164\6\54\217\336\223\170\213\260\73\171\227\176\3\33\171\252\13"}, -{172,260,"or.a.sfn","ScriptFileName",0, +{695,1580,"or.a.s","Style",0, +"\170\234\205\124\115\157\333\60\14\375\53\104\117\55\220\71\373\270\25\151\200\2\303\200\336\206\255\247\335\150\211\216\325\312\242\47\311\361\334\137\77\112\262\123\57\131\67\40\207\130\244\310\367\236\36\171\17\35\305\226\65\160\3\321\243\13\15\373\16\243\141\227\116\20\202\42\107\120\123\34\211\34\304\226\40\216\14\141\250\3\375\34\310\105\150\74\166\24\52\170\224\120\143\174\230\117\162\75\71\102\147\346\162\46\100\357\131\17\212\264\244\160\227\303\152\360\76\125\311\155\52\270\157\42\371\34\130\225\332\300\303\27\377\360\10\12\335\53\304\234\124\300\311\147\376\162\364\153\151\156\4\275\73\141\150\314\221\140\304\51\334\356\6\273\337\131\263\337\325\373\20\5\226\202\353\357\161\262\164\367\376\146\267\255\367\267\253\252\232\51\200\343\10\252\105\167\240\2\31\347\372\221\313\237\102\273\134\30\215\265\113\62\73\73\201\151\4\322\10\32\243\134\63\126\312\241\47\260\214\232\164\265\333\46\30\5\212\147\301\102\333\240\320\322\2\350\303\5\240\222\25\340\32\235\274\126\237\64\105\53\155\362\265\160\3\172\360\306\35\316\104\257\47\301\334\173\322\324\30\47\302\143\307\203\310\175\35\50\12\340" +"\330\302\16\241\365\324\334\135\261\257\260\322\375\125\2\364\265\65\251\373\156\213\373\315\171\106\314\31\102\73\342\233\71\76\347\174\143\153\137\123\22\352\263\264\227\234\366\371\7\163\267\344\45\213\364\344\243\21\106\177\150\24\207\256\176\125\347\343\205\72\45\36\322\313\43\210\111\264\274\126\203\241\115\42\374\115\231\15\230\112\236\317\304\377\352\372\206\204\246\114\203\66\236\124\226\72\266\50\76\266\74\312\335\142\203\120\356\316\150\312\275\344\30\231\4\371\41\70\243\304\127\204\161\360\305\305\35\76\47\240\47\220\141\56\332\362\230\233\215\55\333\205\260\140\54\343\150\304\206\153\245\32\73\275\223\276\263\122\237\126\112\51\161\254\27\57\132\121\127\16\74\17\207\66\7\216\46\14\150\315\113\361\314\122\237\23\224\31\275\160\22\11\24\205\220\225\364\370\44\254\331\117\63\235\205\204\200\342\61\344\361\140\65\4\340\131\44\61\213\261\33\250\207\170\301\243\303\51\217\131\235\141\230\364\310\131\12\226\361\237\347\67\123\234\227\200\110\101\307\264\43\360\131\110\250\64\121\322\315\270\220\332\147\265\126\114\321\246\251\207\236\215\213\11\325\210\136\227\270\354\34\217\26\172\364\247\56\363\12\312" +"\3\35\345\74\21\355\71\230\145\27\256\352\152\352\311\351\23\275\265\255\125\325\313\14\211\213\237\146\133\164\254\51\71\373\166\161\214\330\73\364\51\50\113\351\54\157\335\43\143\10\227\233\162\201\264\71\325\103\141\142\311\376\253\130\307\307\244\226\345\220\244\343\223\6\362\265\146\57\217\40\332\257\370\47\263\44\67\25\203\375\6\236\261\54\162"}, +{172,260,"or.a.sf","ScriptFile",0, "\170\234\105\217\101\16\203\40\20\105\257\62\161\335\342\5\250\111\67\135\165\127\57\60\352\130\46\101\60\3\244\365\366\5\214\65\141\61\360\347\377\377\350\15\201\303\205\300\317\20\363\74\263\45\370\160\64\365\26\351\33\17\105\43\30\241\371\326\244\267\12\243\342\246\323\103\167\167\274\140\364\2\257\121\170\215\272\35\72\335\142\7\321\303\100\220\2\115\300\273\35\353\46\173\7\34\212\54\311\235\75\241\272\25\364\46\213\371\40\10\341\164\365\316\156\260\212\137\111\342\166\51\161\47\205\27\205\312\206\112\361\364\70\355\0\217\214\377\207\300\261\366\35\1\245\65\77\45\264\71\325\146\113\256\51\337\125\77\134\351\131\237"}, -{124,161,"or.a.sop","StopOnPath",0, -"\170\234\115\316\101\12\303\60\14\104\321\253\14\131\227\344\2\256\41\107\221\35\45\66\155\44\43\53\320\336\276\301\253\56\207\317\203\131\221\124\337\54\150\246\215\315\277\360\102\216\52\335\355\312\336\357\311\10\204\142\274\77\47\265\231\246\30\122\134\245\236\344\152\141\111\61\54\24\341\212\356\332\240\62\104\246\223\215\320\310\13\110\66\144\25\257\162\361\210\64\160\125\171\340\305\334\252\34\377\146\257\37\336\356\3\350\215\62\317\77\1\303\70\364"}, {151,226,"or.a.tbf","NumberOfTitlePageBlendedFrames",0, "\170\234\165\215\101\16\302\60\14\4\277\262\352\3\312\7\12\7\336\300\7\334\304\151\54\245\11\262\335\126\360\172\32\161\340\304\165\265\63\363\310\214\272\255\63\53\132\102\122\132\331\20\67\225\272\340\310\22\62\374\174\114\204\254\234\256\103\323\221\106\117\303\315\305\13\343\111\13\117\27\272\101\14\163\341\32\71\342\20\377\102\111\324\34\262\236\237\356\356\323\56\266\121\221\67\271\264\12\13\134\171\304\275\203\275\27\224\311\317\74\125\160\112\34\274\143\204\137\12\126\332\121\136\210\142\326\312\336\31\157\120\336\231\312\137\377\7\237\270\121\253"}, {352,701,"or.a.tf","TitlePageFile",0, @@ -182,8 +150,6 @@ "\110\26\173\211\357\22\372\221\142\122\226\316\227\340\33\164\222\267\220\164\152\310\35\44\74\100\131\132\303\131\257\340\20\224\26\271\204\55\151\105\157\217\131\163\313\262\374\6\344\162\367\123"}, {104,118,"or.a.tnf","NumberOfTitlePageFrames",0, "\170\234\35\214\321\15\203\60\14\5\127\171\142\200\164\1\312\24\135\340\121\234\304\22\161\220\61\252\272\175\103\177\117\167\367\252\2\273\332\52\216\236\221\235\115\116\154\227\253\25\174\252\276\53\142\30\63\121\135\362\163\352\236\230\42\117\113\150\354\202\203\105\346\7\27\350\210\364\74\166\176\145\3\343\37\255\122\324\354\36\215\363\15\150\332\30\332\55\375\0\243\171\51\243"}, -{149,234,"or.a.us","UseScript",0, -"\170\234\155\216\115\12\302\60\20\205\257\62\164\145\67\251\356\323\100\317\40\36\40\211\23\63\102\223\62\63\241\327\267\126\120\12\156\337\317\367\336\4\262\222\306\14\232\275\202\54\30\51\21\12\254\31\65\43\157\62\202\57\64\173\245\132\140\156\242\20\20\146\177\107\150\102\345\261\7\254\207\314\230\306\256\75\214\104\103\235\263\301\115\173\253\62\134\43\323\242\166\10\316\16\336\301\211\22\154\366\115\360\147\214\227\36\352\147\54\66\146\54\333\25\124\175\363\153\72\116\124\66\376\300\377\202\153\170\142\324\377\374\163\157\136\110\237\116\347"}, {242,471,"or.a.xs","CrossSectionSpeed",0, "\170\234\235\220\61\156\303\60\14\105\257\362\221\251\5\2\347\2\256\227\114\235\233\13\110\62\145\261\260\305\124\224\342\344\366\221\155\4\50\32\40\103\107\22\174\237\174\74\5\202\236\211\172\210\107\256\105\153\20\22\371\217\235\244\346\272\353\132\333\35\223\250\176\221\313\54\261\75\330\256\75\230\16\142\277\153\7\157\23\31\55\251\342\106\141\320\263\146\23\35\301\336\60\7\166\1\156\201\241\33\215\111\56\244\260\224\147\242\270\256\313\263\300\111\124\372\51\234\371\102\360\311\114\244\357\350\113\342\70\254\63\46\362\144\26\276\301\251\226\256\244\104\61\377\211\236\171\34\327\374\212\44\51\103\130\121\53\45\366\113\216\225\153\35\311\113\227\165\63\156\360\351\61\225\61\363\171\44\160\334\116\327\377\75\302\244\372\307\40\163\334\103\342\170\133\23\36\207\76\242\177\335\370\302\356\331\152\221\250\264\170\377\354\104\375\100\173\260\7\147\44\62\56\124\1\316\315\35\112\13\250\365"}, {258,441,"or.c","Camera",0, @@ -230,8 +196,8 @@ "&:or.cb.br"}, {283,492,"or.cb.br","BarRight",0, "\170\234\145\120\313\116\304\60\14\374\25\153\117\40\355\113\342\132\172\340\214\204\204\20\167\67\161\133\243\154\22\22\267\245\174\75\156\252\255\126\313\51\321\170\146\74\343\252\251\137\60\275\122\53\325\251\251\1\275\205\252\100\357\334\365\53\26\123\210\224\204\51\103\46\1\351\351\26\12\55\20\232\176\171\227\211\114\1\114\160\41\101\203\51\37\341\103\61\114\335\160\41\257\322\240\34\316\127\371\14\372\107\170\72\230\160\211\301\57\14\366\102\35\45\225\44\234\367\60\261\364\52\111\104\260\161\62\64\304\276\53\333\262\101\207\11\106\114\214\215\243\175\1\321\10\217\4\26\5\101\346\250\350\322\252\304\106\107\42\4\154\301\162\216\16\147\262\20\174\231\155\241\327\314\67\124\15\131\166\341\205\240\102\320\64\355\363\56\244\343\41\217\341\30\167\365\367\200\136\130\346\352\204\65\14\131\55\265\147\216\144\270\235\265\336\325\251\125\173\75\355\47\323\4\157\315\27\31\311\345\274\17\333\52\157\351\7\270\205\372\134\22\37\376\15\252\363\343\232\156\104\67\20\374\122\12\305\366\256\333\304\316\101\317\226\356\212\375\1\230\215\254\222"}, -{119,137,"or.cb.c","Color",0, -"\170\234\55\215\61\12\2\61\24\5\257\362\112\55\214\213\262\335\42\150\43\333\172\203\220\274\350\307\230\37\222\257\170\174\27\265\230\146\30\230\43\202\146\155\320\4\273\21\306\267\41\363\312\22\35\346\202\332\264\262\231\260\377\272\16\337\210\136\31\44\11\43\174\307\176\23\364\121\265\260\30\56\347\23\136\76\77\227\174\12\32\171\220\142\356\317\264\375\32\254\262\334\211\335\70\272\301\15\110\313\273\61\256\335\7\11\371\56\271"}, +{120,137,"or.cb.c","Color",0, +"\170\234\55\215\101\12\302\60\24\5\257\362\226\12\261\26\245\273\42\350\246\270\365\6\41\171\321\140\314\17\311\127\172\374\26\165\61\233\141\140\316\160\222\244\102\2\364\101\50\147\105\342\235\331\167\270\146\224\52\205\125\43\333\257\153\260\225\150\205\56\206\110\17\333\160\334\71\171\25\311\314\212\333\164\301\307\246\367\232\217\116\74\117\61\253\371\63\356\277\6\233\24\237\304\141\30\114\157\172\204\365\135\351\267\335\2\11\61\56\261"}, {65,66,"or.cb.s","Size",0, "\170\234\163\124\50\112\315\111\54\311\54\113\125\50\316\254\112\125\310\117\123\50\311\110\125\110\316\317\311\57\122\110\112\54\122\110\54\126\110\124\110\53\112\114\56\311\314\317\203\111\227\147\346\245\344\227\203\165\350\1\0\17\275\27\205"}, {94,125,"or.cb.so","SideOffset",0, @@ -311,18 +277,24 @@ "\170\234\15\307\301\11\200\60\20\4\300\126\266\2\33\361\33\374\237\272\222\23\274\204\313\22\260\173\235\337\224\352\3\155\277\171\10\311\236\34\14\15\314\377\55\161\232\14\172\73\341\1\125\142\53\53\302\344\223\270\132\76\246\345\3\40\4\27\325"}, {135,164,"or.dr","DataReader",0, "\170\234\35\215\261\15\303\60\14\4\127\171\170\0\171\1\105\125\232\264\11\62\0\35\221\66\21\131\62\104\271\310\366\41\134\376\377\341\76\56\351\116\203\236\114\231\173\234\227\4\65\164\266\243\125\323\245\60\244\165\224\106\131\353\212\354\44\104\13\33\232\200\112\301\370\35\36\244\267\35\143\143\144\265\157\300\143\340\103\325\167\153\70\270\273\141\367\242\174\316\102\103\335\213\126\21\11\133\147\271\115\347\32\104\302\151\123\172\127\275\320\227\263\324\55\316\224\256\307\360\7\276\72\71\272"}, -{268,519,"or.dr.bc","BoundaryConditions",0, -"\170\234\235\221\101\117\303\60\14\205\377\212\217\233\4\351\312\15\310\52\1\7\56\110\160\100\342\234\66\356\152\51\304\121\342\240\225\137\117\322\116\223\100\73\161\213\354\147\177\357\71\357\23\45\40\57\170\300\10\41\162\300\50\63\244\200\3\215\204\11\144\102\220\200\300\43\364\234\275\65\161\206\201\275\45\41\366\351\116\147\327\151\107\235\356\273\17\343\234\156\372\356\222\16\66\105\360\170\252\77\235\313\125\276\337\155\201\76\203\233\13\312\110\345\105\204\342\311\263\114\344\17\300\131\22\131\134\214\54\233\153\261\347\343\275\156\52\167\145\277\141\44\266\64\374\207\337\376\342\163\10\234\110\20\52\64\325\330\177\301\140\252\101\213\136\150\60\356\12\110\241\132\104\137\306\345\345\120\132\244\73\356\257\167\252\325\115\171\326\64\147\75\10\237\372\255\272\135\333\233\72\234\350\33\57\322\312\360\115\371\40\170\15\350\237\137\40\173\222\264\125\153\370\246\134\377\301\256\141\312\152\16\153\330\221\343\305\43\14\306\103\217\140\254\105\133\127\126\326\230\45\107\124\77\17\122\267\311"}, +{269,519,"or.dr.bc","BoundaryConditions",0, +"\170\234\235\220\61\117\304\60\14\205\377\212\307\73\11\322\53\33\220\253\4\14\54\110\60\40\61\247\215\173\265\24\342\50\161\320\225\137\117\322\36\110\210\233\330\54\373\331\357\175\176\235\50\1\171\301\3\106\10\221\3\106\231\41\5\34\150\44\114\40\23\202\4\4\36\241\347\354\255\211\63\14\354\55\11\261\117\67\72\273\116\73\352\164\337\275\140\44\266\64\350\246\357\316\151\141\123\104\367\247\376\303\117\273\312\367\273\55\320\173\160\163\261\63\2\34\2\47\22\204\104\266\104\50\326\65\305\162\222\374\241\24\107\60\21\241\14\275\320\140\334\5\220\102\265\210\76\214\313\113\130\55\322\35\367\227\73\325\352\246\224\120\51\277\365\40\174\232\267\352\172\35\157\352\162\242\117\74\353\126\226\257\312\223\340\71\240\177\174\202\354\111\322\126\351\246\202\257\360\157\306\271\377\200\267\277\300\213\161\345\112\340\131\246\152\316\131\352\17\376\44\272\135\275\233\362\375\73\273\336\53\130\34\126\277\221\343\331\34\203\361\320\43\30\153\321\126\234\172\165\314\222\43\252\57\112\127\267\311"}, {251,452,"or.dr.e","EraseData",0, "\170\234\145\220\121\116\303\60\20\104\257\62\362\27\225\150\270\100\251\204\204\220\370\157\17\260\115\326\251\121\354\265\326\33\112\156\117\342\224\252\300\237\275\73\373\106\63\57\11\216\132\13\222\34\36\56\32\214\267\222\206\151\203\254\222\131\155\202\235\311\300\112\205\13\212\104\206\370\171\306\30\204\72\356\320\221\21\274\112\104\344\50\72\65\170\67\120\333\162\266\2\111\214\142\32\122\17\322\176\214\234\154\345\225\314\155\360\141\106\56\250\104\53\266\262\154\312\14\23\234\170\165\355\32\34\356\64\164\247\12\353\371\217\203\67\126\270\327\171\275\165\10\351\27\172\171\327\103\71\175\160\153\15\336\104\301\137\24\363\300\217\240\122\102\237\52\4\237\64\214\365\304\35\123\360\242\361\300\251\210\226\271\237\345\67\107\256\151\157\360\325\360\257\366\277\345\146\11\265\314\156\115\124\315\234\341\126\365\45\14\303\32\32\73\302\131\331\77\273\261\157\274\157\106\163\373\253\5\256\36\273\47\332\127\176\363\15\143\177\237\122"}, {114,155,"or.dr.em","ErrorMessage",0, "\170\234\115\215\321\15\2\61\14\103\127\361\0\34\73\60\112\324\246\107\245\134\123\45\51\160\333\23\201\220\370\263\237\254\347\33\74\254\217\175\173\220\54\256\60\246\272\351\220\23\323\164\262\305\211\270\123\44\217\145\303\263\60\202\137\1\155\237\314\146\152\70\330\235\166\106\377\207\132\312\62\256\27\144\246\1\76\146\312\276\157\277\141\353\302\170\222\103\224\152\276\373\52\45\125\155\211\234\327\67\163\173\71\36"}, {106,125,"or.dr.gcf","GADGET-ConfigurationFlags",0, "\170\234\75\314\301\15\203\60\14\106\341\125\376\5\312\16\110\105\210\73\13\130\324\11\226\202\203\154\247\202\355\33\161\350\371\175\172\243\102\64\70\263\275\276\124\32\177\160\132\75\331\342\106\354\24\160\16\177\204\51\25\154\125\223\344\146\24\122\25\251\120\166\244\152\235\62\346\361\75\117\53\370\12\126\357\171\300\22\20\357\77\71\310\244\334\217\374\257\232\363\360\3\170\310\56\23"}, -{153,207,"or.dr.hls","ART-LoadInSets","--ART", -"\170\234\115\216\301\12\302\60\20\104\177\145\216\12\45\342\275\26\172\54\170\22\177\140\233\154\315\102\110\303\46\246\370\367\246\172\320\353\314\274\307\214\110\272\46\326\362\102\361\124\220\23\133\131\204\63\66\317\305\263\142\274\335\341\250\20\26\11\55\46\145\204\225\34\73\110\104\346\222\15\46\303\246\203\54\350\347\341\332\272\51\356\171\177\232\207\313\271\153\136\216\37\104\342\3\204\112\52\64\357\252\203\161\307\237\32\233\204\0\113\317\314\177\153\345\375\121\221\312\110\244\105\154\33\66\56\371\343\27\242\350\120\305\62\52\153\46\363\6\40\337\107\175"}, -{151,237,"or.dr.hrcs","ART-RightCoordinateSystem","--ART", -"\170\234\145\216\115\12\203\120\20\203\257\222\3\210\167\160\123\160\133\274\300\274\347\130\207\276\37\231\31\21\157\337\207\135\264\340\56\204\174\111\6\204\132\23\123\301\246\165\143\365\23\276\222\303\70\161\164\103\140\77\230\113\63\31\52\257\325\101\145\106\342\305\21\153\325\131\12\71\303\116\163\316\326\143\170\116\330\215\355\57\177\213\165\10\273\143\174\350\70\41\266\141\127\52\266\124\315\20\207\24\257\27\374\275\323\135\123\335\275\244\307\264\212\375\116\67\235\111\112\72\321\232\20\50\276\17\322\271\161\171\43\227\40\111\374\354\77\171\307\127\125"}, +{133,176,"or.dr.hip","ART-IncludeParticles","--ART", +"\170\234\115\214\101\12\302\60\20\105\257\362\227\12\122\161\137\12\135\272\25\57\60\115\47\166\40\44\141\146\264\365\366\306\56\304\345\377\274\367\106\124\55\225\325\337\360\205\34\126\71\110\24\66\54\145\305\170\273\143\46\47\104\111\355\42\145\244\102\63\317\35\256\21\306\16\57\350\247\341\322\237\247\341\324\12\234\167\100\362\3\204\27\251\320\364\25\177\15\254\222\22\2\75\215\377\300\120\124\331\152\311\373\256\244\56\241\261\273\160\220\10\161\360\46\346\166\354\76\77\1\75\313"}, +{133,177,"or.dr.hiv","ART-IncludeVariables","--ART", +"\170\234\115\214\101\12\302\60\20\105\257\362\227\12\122\161\137\12\135\272\25\57\60\115\47\166\40\44\141\146\264\172\173\333\54\304\345\377\274\367\106\124\55\225\325\77\360\205\34\126\71\110\24\66\54\145\305\170\273\143\46\47\104\111\333\105\312\110\205\146\236\73\134\43\214\35\136\320\117\303\245\77\117\303\151\53\160\156\200\344\7\10\225\324\45\354\342\257\201\125\122\102\240\247\361\37\30\212\52\133\55\271\355\27\251\320\264\153\315\70\110\204\70\370\55\346\166\354\276\202\305\76\76"}, +{128,166,"or.dr.hrc","ART-ROICenter","--ART", +"\170\234\115\315\115\12\302\60\20\5\340\253\274\3\324\277\175\50\210\53\127\102\355\5\222\146\322\16\110\46\114\42\122\117\157\115\245\270\234\217\367\336\30\327\236\273\176\327\335\256\27\212\205\324\34\134\333\300\154\172\347\67\255\146\243\377\363\176\116\325\221\124\22\151\141\312\310\211\6\16\63\312\104\120\32\131\42\44\324\153\51\141\124\366\50\202\207\130\337\340\65\221\22\312\262\2\316\70\42\210\302\142\170\72\252\217\116\77\310\351\233\333\177\0\136\137\66\101"}, +{ 0U, 0, "or.dr.hrs","ART-ROISize","--ART", +"&:or.dr.hrc"}, +{ 0U, 0, "or.dr.hrt","ART-ROIType","--ART", +"&:or.dr.hrc"}, {104,117,"or.dr.is","IsSet",0, "\170\234\25\314\61\16\203\60\14\5\320\253\174\61\267\241\354\24\211\243\270\215\135\42\245\66\162\234\201\333\3\353\33\336\212\217\131\145\122\70\123\176\232\326\3\273\333\316\36\7\142\243\270\74\272\153\303\204\42\227\60\276\335\235\65\220\51\10\122\52\67\210\371\37\204\231\260\71\313\173\350\277\44\222\312\260\64\216\171\244\345\1\322\214\327\75\250\105\72\1\234\21\47\375"}, {295,565,"or.dr.l","LoadData",0, @@ -364,8 +336,8 @@ {525,1170,"or.ic","ImageComposer",0, "\170\234\225\124\313\216\333\60\14\374\25\42\247\26\10\234\103\157\201\326\100\133\240\300\236\333\37\240\45\332\46\152\75\40\311\311\246\137\137\122\366\42\131\24\105\267\227\30\221\305\341\160\146\150\63\364\317\36\47\372\32\175\212\205\262\71\15\75\130\14\140\243\37\70\20\24\272\120\306\5\70\70\112\44\77\241\202\101\230\63\215\117\207\230\273\213\77\364\27\56\53\56\374\13\53\307\0\127\271\32\257\305\234\260\227\252\32\41\12\114\134\153\132\53\260\366\352\340\133\314\100\57\350\323\102\107\340\332\32\126\136\356\335\166\14\250\161\242\72\123\26\40\100\310\64\255\13\146\360\124\346\43\10\106\132\320\122\173\341\126\113\116\236\51\123\21\212\33\223\70\266\336\357\241\333\330\142\21\54\16\42\103\325\7\73\301\16\261\365\177\57\106\147\122\157\254\60\240\334\33\366\23\224\154\237\16\155\354\162\76\263\265\63\346\332\245\60\35\172\63\310\225\241\377\34\136\245\120\276\42\104\273\254\372\253\41\16\306\34\75\174\2\307\343\110\131\325\377\213\332\103\157\116\257\215\323\146\152\331\212\377\121\12\230\105\370\264\160\335\354\62\334\17\150\177\116\71\256\301\231\23\213\56\301\351\351\30\305\200\373" "\351\66\124\7\77\146\202\173\301\176\334\100\325\322\42\26\74\130\67\145\166\35\174\217\276\115\253\377\366\133\36\157\162\311\243\30\115\76\325\133\363\27\141\344\27\332\61\267\141\120\345\222\41\203\244\144\324\310\150\166\132\16\334\106\37\167\200\206\273\261\273\23\177\145\247\105\203\114\155\161\221\72\121\41\264\41\167\34\14\267\253\230\116\232\72\151\332\202\124\337\116\331\230\353\261\222\357\340\213\244\344\370\370\136\321\376\154\253\103\316\170\21\244\230\35\345\242\151\171\36\41\304\307\122\231\373\241\362\375\273\266\331\110\226\107\46\167\124\302\241\261\66\373\212\303\233\35\147\21\41\266\214\313\362\310\236\251\34\34\320\126\26\172\37\204\303\160\113\130\44\200\37\317\272\241\127\136\26\50\54\61\275\201\315\204\225\356\121\25\31\256\263\234\134\164\117\13\224\131\345\344\255\271\135\163\376\257\117\106\367\33\62\51\244\214"}, -{131,157,"or.ic.bc","BorderColor",0, -"\170\234\55\216\301\12\302\60\20\104\177\145\216\172\60\26\245\267\42\350\105\172\365\17\322\144\123\227\246\331\260\111\375\176\203\365\60\360\30\336\300\334\341\44\212\102\2\352\233\60\211\172\122\130\225\55\171\114\326\55\363\216\274\332\231\212\301\230\220\125\62\151\145\52\373\266\64\235\120\62\71\16\114\36\266\340\172\162\262\146\111\224\52\136\317\7\76\66\156\115\37\234\170\272\161\252\346\237\341\374\153\160\210\274\20\56\175\157\72\323\41\264\77\112\376\150\276\144\366\66\142"}, +{132,157,"or.ic.bc","BorderColor",0, +"\170\234\55\216\301\12\302\60\20\104\177\145\216\12\261\26\245\267\42\350\245\170\365\17\322\144\123\227\266\331\260\111\375\176\203\365\60\360\30\336\300\334\341\144\21\205\4\224\67\141\24\365\244\260\52\133\364\30\255\233\247\35\171\265\23\345\6\317\210\244\222\110\13\123\336\267\271\352\204\234\310\161\140\362\260\31\327\223\223\65\111\244\130\360\32\36\370\330\145\253\172\357\304\323\215\143\61\377\364\347\137\203\303\302\63\341\322\165\246\65\55\102\375\243\344\217\315\27\144\56\66\132"}, {139,206,"or.ic.bgv","BackgroundWindowViewModule",0, "\170\234\115\216\121\16\202\100\14\104\257\62\7\100\22\217\340\207\7\51\120\166\33\331\26\167\13\4\117\357\202\61\372\333\231\67\257\67\5\345\114\73\66\361\10\135\122\307\31\66\242\267\64\233\262\172\1\77\27\232\340\6\217\374\327\350\250\177\204\154\213\16\160\231\270\264\270\123\37\177\340\321\71\210\317\174\220\225\13\110\41\303\67\130\245\324\141\171\221\213\151\365\353\140\33\266\150\205\41\211\2\43\130\105\104\117\63\371\151\151\140\31\227\153\3\31\177\107\110\175\62\315\276\267\157\151\214\112\71"}, { 0U, 0, "or.ic.bgv2","BackgroundWindowViewModule2",0, @@ -377,8 +349,8 @@ "\170\234\165\217\101\156\203\100\14\105\257\362\17\200\270\103\26\135\364\30\146\306\60\126\300\246\63\46\50\75\175\15\115\224\52\122\267\366\377\317\317\27\5\325\112\167\354\342\5\272\55\3\127\330\210\144\313\152\312\352\15\374\265\321\14\67\170\341\77\211\201\322\165\252\266\151\206\313\314\255\307\7\245\362\52\36\231\243\361\213\237\344\306\15\4\245\205\237\33\131\150\142\214\121\306\136\254\75\7\223\105\122\364\74\110\176\302\73\130\5\51\170\131\375\216\346\125\164\352\40\43\324\36\245\126\154\233\63\6\306\72\123\342\34\200\127\275\307\147\370\232\227\356\274\173\223\26\37\311\67\271\230\306\343\232\155\17\172\176\227\242\32\334\225\223\214\22\300\361\120\170\330\374\113\161\272\206\374\132\71\24\130\23\367\77\164\15\177\11"}, {62,59,"or.ic.bw","BorderWidth",0, "\170\234\163\124\50\317\114\51\311\120\320\310\314\123\50\310\254\110\315\51\326\124\310\117\123\50\311\110\125\110\312\57\112\111\55\122\110\54\312\57\315\113\121\110\112\114\316\116\207\60\63\163\23\323\123\213\365\0\150\116\25\40"}, -{134,190,"or.ic.fgc","ForegroundWindowBorderColor",0, -"\170\234\115\216\101\16\302\60\14\4\277\342\43\134\362\7\220\20\167\176\220\46\156\142\251\265\301\116\132\321\327\223\100\21\34\255\335\231\365\211\301\253\372\47\254\124\62\160\235\7\124\220\21\202\314\167\141\344\142\200\217\352\47\50\2\45\343\137\143\24\305\244\122\71\66\226\243\254\346\340\342\103\376\241\275\325\231\317\100\242\5\355\175\7\231\104\277\341\40\32\233\360\340\15\156\356\352\316\307\56\336\153\252\150\115\25\211\23\54\144\355\15\332\174\41\341\175\321\275\0\336\65\105\101"}, +{135,190,"or.ic.fgc","ForegroundWindowBorderColor",0, +"\170\234\115\216\101\16\302\60\14\4\277\342\43\110\125\377\0\22\342\316\17\334\304\115\42\265\66\330\111\253\362\172\22\50\202\243\265\73\263\76\61\240\52\156\260\246\34\201\313\74\220\202\214\340\144\276\13\23\147\3\172\24\234\40\13\344\110\177\215\121\224\202\112\141\137\131\366\262\132\17\27\164\361\207\266\126\143\76\3\41\55\144\357\333\311\44\372\15\7\121\137\205\7\64\270\165\327\356\174\154\342\275\246\112\126\125\76\161\200\45\131\175\43\75\61\47\341\175\261\177\1\335\165\105\75"}, {142,214,"or.ic.fgs","ForegroundWindowScale",0, "\170\234\115\216\101\16\302\60\14\4\277\262\17\100\225\170\2\7\36\342\46\156\153\51\330\305\116\133\301\353\111\104\45\270\317\314\356\115\101\356\364\302\41\165\201\156\217\221\35\66\41\331\143\65\145\255\1\176\156\124\120\15\165\341\77\142\62\347\331\155\323\334\134\315\166\304\200\73\245\345\247\166\252\73\337\201\131\166\16\20\246\142\124\105\147\254\46\215\71\203\205\43\140\16\246\163\354\172\301\330\136\55\322\212\75\222\314\235\243\205\163\167\167\211\306\311\273\225\114\317\175\110\40\22\25\316\303\7\10\371\116\310"}, {146,253,"or.ic.fgv","ForegroundWindowViewModule",0, @@ -640,6 +612,10 @@ "&:or.vm.abl"}, {177,246,"or.vm.ac","ArtifactCorrection",0, "\170\234\115\217\261\152\3\61\20\104\177\145\312\4\314\345\7\114\300\145\110\153\322\357\131\253\234\100\326\12\355\310\347\373\373\110\215\111\67\305\233\267\263\327\55\71\152\263\252\215\7\156\126\330\54\73\66\333\361\110\336\45\103\32\123\224\33\35\157\26\251\5\241\53\150\130\373\257\43\25\374\134\277\337\7\244\330\244\204\254\141\301\127\104\42\206\327\225\223\74\223\237\154\135\317\37\43\234\376\11\367\224\63\126\105\323\273\75\64\100\6\276\51\364\131\265\270\302\342\210\154\62\146\335\153\247\60\131\361\5\227\127\177\136\55\106\110\336\345\230\157\250\153\341\11\156\303\63\144\126\147\145\56\261\30\261\36\10\32\245\147\56\177\314\106\130\262"}, +{652,1418,"or.vm.an","AnimationRootName",0, +"\170\234\165\124\301\156\333\60\14\375\25\242\247\26\110\335\256\273\155\151\200\2\133\7\37\266\1\105\357\203\154\321\11\1\113\362\50\311\156\366\365\243\254\332\216\223\315\310\301\260\304\307\367\36\37\363\172\100\260\312\40\270\6\202\274\67\324\342\265\277\1\262\301\301\160\240\372\0\312\222\121\201\234\5\362\60\60\205\200\266\200\147\307\240\300\72\173\373\7\331\101\257\332\70\203\154\25\34\30\233\307\53\307\105\157\12\345\256\166\333\152\367\64\341\374\214\241\213\141\173\127\355\266\167\152\7\35\273\16\71\34\67\122\53\35\344\227\60\330\271\0\235\342\60\201\252\72\104\325\202\161\75\145\232\231\367\65\25\130\300\100\341\340\142\30\57\372\330\64\364\166\363\31\250\201\313\266\217\367\251\161\352\205\26\120\255\364\65\234\20\27\225\331\5\5\36\205\210\12\271\355\106\12\364\354\125\46\41\45\265\263\76\160\254\3\152\51\313\347\256\155\335\100\166\17\106\131\213\374\351\234\321\213\150\374\41\365\211\21\150\207\136\374\14\200\2\237\364\110\143\103\66\172\360\264\267\322\25\64\61\326\301\361\61\37\373\50\344\347\366\214\102\120\147\162\76\126\36\177\107\264\341\124\234\260\365\240\30\327\352" +"\302\101\205\163\344\4\352\141\113\273\321\220\333\173\171\76\24\235\335\157\357\110\234\133\175\177\130\276\143\250\341\372\175\112\243\65\370\46\135\374\173\160\64\6\144\321\43\366\124\307\177\245\204\232\61\45\245\121\173\114\351\22\332\27\21\221\241\72\51\345\201\274\314\341\277\126\246\10\145\77\100\371\323\360\214\241\152\44\271\253\361\145\323\310\152\352\111\217\354\171\64\40\171\45\227\215\300\64\354\114\266\152\204\20\5\112\353\64\131\61\343\322\236\113\143\12\50\55\70\326\50\255\45\121\275\43\241\126\327\244\145\106\252\155\217\340\172\121\45\163\111\230\112\364\142\117\56\172\71\250\47\41\223\322\115\112\121\312\244\44\116\257\227\223\243\315\3\34\327\40\45\143\144\233\65\316\113\65\106\146\240\266\205\112\214\351\72\311\33\352\51\122\163\160\154\64\25\262\207\207\15\174\234\44\64\147\40\76\310\176\372\51\254\135\73\147\165\311\332\104\377\175\45\226\240\371\16\153\152\150\211\3\332\236\330\131\223\232\367\212\111\125\62\236\362\371\245\174\375\125\176\177\372\366\365\327\227\362\145\65\376\121\144\340\344\330\172\340\112\226\321\164\55\206\323\25\165\231\100\24\261\334\36\123\321\170\346\217\76\240" +"\21\155\317\134\276\56\73\230\151\203\305\141\246\114\162\224\242\163\376\167\61\152\335\200\227\261\212\245\247\267\321\326\116\57\332\227\302\305\101\23\275\54\374\33\371\120\374\5\177\320\364\151"}, {244,405,"or.vm.ao","AnimationOutput",0, "\170\234\155\220\61\153\304\60\14\205\377\312\33\133\70\102\173\320\245\235\72\224\162\224\102\207\160\273\222\50\234\300\261\134\133\11\344\337\127\161\216\343\206\216\302\357\373\236\344\366\302\350\124\3\123\104\312\232\70\333\12\273\220\241\327\150\131\103\361\211\61\112\244\0\235\55\315\6\35\341\151\212\62\221\211\306\6\247\21\142\220\202\302\6\123\74\35\52\164\113\324\47\323\314\3\304\101\217\375\316\34\173\336\114\243\4\56\157\30\65\103\35\312\130\50\314\134\376\21\320\122\171\367\23\46\135\204\53\373\272\3\233\352\31\175\146\62\207\175\275\357\237\217\317\343\236\73\370\74\70\164\13\36\357\203\357\347\323\125\367\260\165\6\62\363\55\64\325\336\354\233\112\366\140\111\334\213\177\101\220\56\123\226\212\16\230\150\105\124\103\347\273\56\44\201\272\340\5\176\142\10\110\156\362\253\246\362\330\240\165\361\336\161\365\372\75\32\303\172\107\315\161\360\332\163\373\205\227\346\17\111\377\217\76"}, {160,242,"or.vm.bb","BoundingBox",0, @@ -648,7 +624,7 @@ "\170\234\205\221\315\116\303\60\20\204\137\145\325\23\110\371\1\172\203\220\103\205\220\172\357\241\364\266\216\67\265\245\305\133\331\16\111\337\36\73\1\125\5\44\116\273\266\107\237\306\63\73\103\20\317\47\2\351\41\246\275\101\60\236\372\347\225\370\352\343\275\122\152\325\66\252\335\310\340\264\165\107\330\310\324\324\252\155\152\154\13\300\0\275\60\313\30\36\233\201\333\206\155\326\336\145\301\343\14\323\324\343\300\21\266\257\176\273\53\103\74\63\201\372\106\51\231\340\306\223\56\25\223\323\151\132\27\45\35\6\272\175\152\352\314\132\170\367\27\136\307\30\202\355\176\63\300\72\330\227\332\172\352\242\25\127\300\321\23\271\174\373\126\100\106\346\365\160\315\175\270\160\15\132\137\106\223\64\327\144\161\124\236\354\104\14\243\325\4\154\35\205\153\310\372\37\163\243\215\6\366\105\266\201\116\303\1\160\242\0\301\310\350\162\174\235\210\117\132\214\64\77\24\213\36\275\117\231\2\306\231\233\302\51\176\326\202\212\127\55\243\42\16\137\125\44\370\137\32\217\356\110\263\246\202\235\261\141\351\72\315\41\120\77\160\352\317\317\156\262\337\365\13\204\16\143\44\17\47\226\30\252\345\243\165\252\366\23\203\101" "\270\177"}, {114,131,"or.vm.bg","BackgroundColor",0, -"\170\234\55\315\261\16\202\60\24\205\341\127\71\243\46\132\23\11\33\161\160\161\227\47\250\267\247\322\120\357\45\264\350\353\113\10\303\277\174\313\337\263\26\324\201\170\171\31\337\263\55\32\40\226\155\206\305\315\213\120\171\102\231\50\51\46\6\370\2\217\346\54\366\231\114\251\25\317\307\35\137\237\27\242\23\13\274\45\255\156\257\273\154\202\103\116\43\161\155\133\267\207\270\36\176\103\252\74\272\77\330\227\53\356"}, +"\170\234\55\315\261\16\202\60\24\205\341\127\71\243\46\125\23\15\33\161\160\161\227\47\250\267\247\322\120\357\45\264\350\353\103\10\303\277\174\313\337\261\26\324\236\170\173\31\76\223\315\32\40\226\155\202\305\315\213\120\351\120\106\112\212\211\1\276\300\343\166\22\373\216\246\324\212\327\363\201\237\317\63\321\212\5\336\223\126\267\327\136\66\301\41\247\201\270\66\215\333\103\134\17\377\76\125\36\317\13\327\243\53\346"}, {247,446,"or.vm.bi","BackgroundImage",0, "\170\234\165\220\275\156\303\60\14\204\137\345\220\251\5\2\347\5\134\17\355\324\245\123\137\200\262\151\233\250\176\2\111\266\223\74\175\51\65\15\222\41\233\10\335\175\344\335\347\210\74\113\302\61\206\43\307\174\206\276\51\45\231\74\17\40\170\162\214\60\202\74\370\44\51\213\237\40\216\46\306\50\226\367\352\345\377\71\6\127\307\362\201\115\254\205\141\54\251\140\24\11\103\375\317\24\303\342\7\214\41\126\345\52\151\41\53\27\312\22\74\122\317\236\361\42\76\145\246\241\56\125\326\111\375\175\260\352\270\3\44\316\60\147\264\204\71\362\370\266\13\261\131\135\143\246\135\327\232\356\375\246\373\50\276\366\140\272\366\100\335\55\341\153\203\357\200\310\253\16\310\341\351\226\375\265\207\232\335\35\265\232\224\143\311\257\236\207\312\32\174\205\54\175\155\203\262\222\375\300\125\110\327\114\233\344\271\120\376\212\22\137\303\337\305\121\226\133\372\31\311\206\215\113\65\252\175\364\76\71\261\371\5\377\353\237\234"}, {132,173,"or.vm.bia","BackgroundImageFixedAspect",0, @@ -753,11 +729,14 @@ "\170\234\45\314\301\11\200\60\14\106\341\125\176\172\226\272\100\355\301\25\234\240\140\112\205\330\110\232\52\156\57\352\371\175\274\205\254\301\12\301\66\143\102\53\162\125\110\205\311\1\311\137\11\11\105\51\117\116\324\237\273\127\166\121\73\223\206\61\105\217\371\306\112\71\165\266\341\325\112\330\32\252\374\77\377\0\60\211\40\246"}, {154,241,"or.vm.s","Size",0, "\170\234\155\216\301\15\203\60\14\105\127\261\70\243\260\100\232\25\332\103\27\60\324\200\245\64\216\234\0\202\351\233\6\251\252\324\336\236\354\347\357\177\237\71\101\124\211\244\171\207\101\102\126\361\11\362\114\220\370\40\220\261\362\312\151\101\317\7\146\226\0\33\207\207\154\120\250\172\203\22\5\3\327\30\45\161\46\310\122\347\26\101\151\274\64\242\146\175\232\330\70\333\273\333\333\50\21\266\353\235\355\320\175\136\267\345\344\273\111\341\115\113\30\366\236\132\140\103\6\206\31\303\304\141\72\315\25\375\102\200\76\311\271\240\337\322\177\153\276\0\161\337\126\321"}, -{164,248,"or.vm.sam","StereoAlignmentMarkers",0, -"\170\234\135\216\121\16\202\60\20\5\257\362\302\267\201\13\324\136\102\56\120\144\113\33\333\56\351\56\22\156\57\110\214\306\377\67\363\246\17\204\201\71\221\53\230\53\317\124\165\203\6\247\120\236\246\104\2\11\274\306\62\301\245\70\205\222\251\50\262\253\17\252\2\317\25\343\342\22\366\301\310\53\104\251\22\43\363\110\55\372\20\345\253\14\116\120\30\344\75\335\25\321\303\70\204\112\376\332\160\155\237\271\25\151\354\211\233\316\131\304\143\255\130\204\306\13\366\227\35\320\275\364\37\322\306\232\301\336\316\333\176\233\311\164\203\175\13\216\206\217\305\104\373\123\51\246\213\266\175\1\310\145\127\65"}, +{147,200,"or.vm.sam","StereoAlignmentMarkers",0, +"\170\234\115\315\313\15\302\60\20\105\321\126\236\122\100\322\200\161\7\254\110\3\23\62\376\10\333\23\171\6\42\272\47\300\2\366\127\347\316\211\261\210\24\246\206\255\313\306\335\236\260\104\6\223\30\13\53\64\311\236\133\4\225\34\123\253\334\14\225\372\215\273\42\110\307\172\247\202\43\130\145\207\32\167\26\124\131\171\304\234\262\376\310\104\212\46\340\20\370\152\310\341\170\60\34\41\165\16\247\101\372\370\250\243\326\301\273\305\137\276\312\371\120\330\115\213\167\23\371\217\211\374\66\14\56\373\277\253\272\51\373\361\5\340\331\107\71"}, {446,862,"or.vm.sm","StereoMode",0, "\170\234\155\223\315\156\334\60\14\204\137\205\107\7\310\356\66\375\157\140\54\20\64\275\265\227\244\350\235\153\321\226\22\131\24\44\171\135\367\351\113\111\336\6\106\172\262\141\176\32\15\207\364\243\247\316\364\206\42\44\115\60\122\322\254\40\61\114\221\362\103\231\350\55\56\20\23\5\142\60\43\16\264\207\237\202\366\154\55\317\306\15\160\106\73\311\171\14\4\330\165\344\23\251\333\166\262\307\326\232\143\173\72\276\151\17\247\343\55\374\140\367\42\327\310\173\225\274\332\267\207\314\125\366\246\262\367\23\132\20\155\305\163\204\46\315\14\264\310\15\306\101\176\217\344\61\140\242\13\161\45\136\2\14\304\63\132\273\263\346\231\4\111\60\371\215\364\333\52\375\65\54\61\211\372\267\54\330\344\203\121\117\111\254\300\140\61\106\212\133\103\357\352\251\107\63\172\113\160\222\106\167\201\324\352\175\103\276\257\144\216\306\70\51\133\354\4\14\344\224\150\257\361\245\305\113\65\26\277\74\45\77\245\234\61\302\257\7\372\175\141\174\340\47\352\22\207\75\334\131\13\334\227\301\260\122\240\71\230\77\354\262\173\153\334\232\170\37\170\54\204\245\76\345\230\256\1\235\52\137\350\114\356\177\144\60\203\56\150\35" "\244\114\72\200\306\230\255\214\50\341\25\246\372\256\11\3\132\63\70\351\146\66\111\227\162\61\374\317\351\65\110\77\345\306\45\17\105\134\237\144\4\63\172\117\152\223\321\207\232\321\367\325\52\260\263\313\6\370\130\201\207\213\303\327\304\247\165\103\2\105\45\355\335\137\366\63\257\261\4\343\247\340\131\126\127\143\120\163\356\272\71\123\110\246\223\122\235\12\341\231\266\43\376\134\25\357\34\332\41\240\327\320\310\204\167\335\202\156\313\175\131\27\110\123\367\114\341\304\162\3\64\62\227\135\311\371\265\372\101\176\201\277\331\142\47\362"}, +{357,594,"or.vm.sn","SnapshotRootName",0, +"\170\234\125\222\115\157\333\60\14\206\377\12\321\323\12\144\116\267\153\75\3\5\332\14\76\364\122\344\136\320\26\155\23\260\50\203\142\342\372\337\217\266\207\144\323\111\20\77\336\347\45\165\36\10\4\43\101\352\300\374\336\361\110\300\142\11\346\201\333\1\262\340\224\207\144\300\21\173\312\200\112\60\53\233\221\74\173\136\340\53\207\13\216\377\206\273\244\221\2\164\232\242\267\104\3\115\136\337\54\200\41\260\364\120\162\365\375\311\317\217\142\222\276\74\162\165\270\75\375\274\77\221\265\360\15\133\133\233\157\120\364\345\232\231\223\0\147\10\144\244\221\305\165\274\361\12\136\42\14\112\335\257\207\244\305\65\26\334\75\124\145\123\325\53\26\234\234\10\255\74\66\125\171\304\12\46\115\23\251\55\217\5\324\273\353\215\160\33\103\103\75\113\206\231\155\0\204\151\274\144\310\334\313\141\143\330\375\265\112\150\56\314\262\325\6\126\152\55\351\2\171\242\226\73\276\63\221\134\131\223\104\22\203\53\52\143\343\76\352\323\107\175\376\254\337\137\176\277\175\276\326\37\317\220\74\125\147\316\164\330\212\262\351\72\45\67\151\177\205\320\165\241\115\161\32\335\365\76\214\175\145\73\300\105\2\351\270\254\105\133" +"\54\57\331\50\272\267\223\326\147\10\311\261\305\355\355\330\40\64\337\220\331\103\276\255\175\171\273\303\3\344\4\70\216\377\345\220\264\51\334\35\337\376\304\175\154\361\222\315\67\304\331\212\77\233\276\320\341"}, {93,96,"or.vm.wn","WindowNumber",0, "\170\234\35\310\61\16\200\40\14\0\300\257\64\354\302\7\220\37\270\31\167\220\32\110\220\222\2\52\277\327\70\336\255\41\126\140\264\176\242\234\6\24\246\202\334\306\127\255\163\256\320\2\102\314\36\37\240\343\307\336\231\61\67\320\26\2\343\61\13\142\171\235\302\150\147\266\210\67\54\344\173\102\255\234\321\312\32\371\2\252\260\41\241"}, {122,168,"or.w","Volume",0, diff -Nru ifrit-3.3.4/help/ihelpfactorydataOR.h.stub ifrit-3.4.2/help/ihelpfactorydataOR.h.stub --- ifrit-3.3.4/help/ihelpfactorydataOR.h.stub 2011-01-27 17:50:36.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataOR.h.stub 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -//LICENSE A -#include "../Work/help/ihelpfactorydataOR.txt" diff -Nru ifrit-3.3.4/help/ihelpfactorydataSR.h ifrit-3.4.2/help/ihelpfactorydataSR.h --- ifrit-3.3.4/help/ihelpfactorydataSR.h 2011-01-27 17:52:01.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataSR.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -25,7 +25,7 @@ =========================================================================*/ #if 0 -#include "../Work/help/ihelpfactorydataSR.txt" +#include "../../Work/help/ihelpfactorydataSR.txt" #else static iHelpData data[] = { {767,1745,"sr.cl.i","Command-line Shell",0, diff -Nru ifrit-3.3.4/help/ihelpfactorydataSR.h.stub ifrit-3.4.2/help/ihelpfactorydataSR.h.stub --- ifrit-3.3.4/help/ihelpfactorydataSR.h.stub 2011-01-27 17:50:36.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataSR.h.stub 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -//LICENSE A -#include "../Work/help/ihelpfactorydataSR.txt" diff -Nru ifrit-3.3.4/help/ihelpfactorydataUG.h ifrit-3.4.2/help/ihelpfactorydataUG.h --- ifrit-3.3.4/help/ihelpfactorydataUG.h 2011-01-27 17:52:01.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataUG.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -25,7 +25,7 @@ =========================================================================*/ #if 0 -#include "../Work/help/ihelpfactorydataUG.txt" +#include "../../Work/help/ihelpfactorydataUG.txt" #else static iHelpData data[] = { {284,427,"ug.pf","Preface",0, @@ -132,18 +132,17 @@ "\266\120\325\211\232\234\345\135\130\55\127\172\265\202\372\47\156\147\145\366\331\15\104\143\130\235\321\302\126\335\367\162\177\20\360\60\261\341\332\310\133\125\10\264\322\56\350\57\26\172\364\136\141\253\375\140\217\67\161\104\220\267\30\352\375\123\74\37\372\206\252\251\374\103\356\60\157\112\116\140\117\374\261\42\307\306\30\263\254\70\3\12\223\7\243\370\346\323\50\113\325\264\241\41\14\346\5\47\353\224\346\46\225\2\62\46\7\163\104\335\131\201\275\12\372\131\373\130\211\237\105\34\137\10\110\326\207\216\370\70\276\362\344\0\336\13\227\51\366\340\370\212\106\355\203\157\45\70\332\312\151\222\350\174\307\317\53\36\135\15\347\72\13\166\251\224\113\35\205\211\342\11\115\305\75\242\251\264\166\215\163\366\164\156\234\255\100\2\252\346\42\13\356\0\300\162\105\42\101\111\320\116\174\361\125\72\343\103\47\171\144\305\71\44\65\160\44\2\110\333\234\36\267\135\255\362\205\372\70\57\357\307\206\23\360\326\272\233\140\46\61\124\153\233\13\203\153\223\11\262\101\362\55\56\226\226\77\252\255\320\14\301\272\175\201\216\226\40\355\353\125\66\112\274\345\251\207\160\45\257\153\353\124\44\26\213\113\336\32\71" "\163\222\30\16\73\357\205\162\316\272\231\360\66\23\14\17\62\42\301\16\207\66\310\130\141\43\73\345\60\342\102\72\43\351\17\234\5\16\347\31\62\215\103\300\11\61\270\310\271\175\220\352\263\303\347\47\314\102\233\107\300\210\275\30\14\316\46\150\77\134\115\171\14\32\361\322\273\304\73\142\135\22\221\375\164\154\77\166\217\326\350\157\135\25\262\173\156\310\50\16\146\201\361\222\236\103\171\150\112\32\307\71\77\105\42\314\155\60\145\175\166\70\350\145\36\10\275\113\121\13\336\300\263\163\105\155\264\117\303\335\314\152\177\375\30\314\370\140\234\167\217\241\150\325\317\305\237\174\165\62\67\237\233\200\7\172\74\276\110\221\77\236\351\127\336\111\155\150\134\221\202\237\15\33\117\136\227\235\17\23\232\63\367\332\63\327\330\321\224\157\224\151\172\335\27\135\173\212\354\273\35\237\7\300\212\110\16\175\245\264\337\216\237\62\233\312\200\75\66\66\12\347\57\60\376\331\63\37\375\325\43\26\177\232\305\262\257\164\222\334\57\36\22\71\75\152\350\107\217\222\260\20\347\237\203\43\14\355\42\261\54\317\260\327\35\253\347\214\240\104\252\175\173\40\261\27\234\341\153\60\113\112\37\307\311\1\176\334\373\66" "\332\125\161\44\231\152\231\235\327\65\175\31\344\262\54\330\156\2\143\371\340\57\34\4\337\7\126\16\371\351\220\55\136\377\155\244\26\177\225\360\72\164\362\370\203\106\112\131\232\50\206\271\2\121\160\303\63\7\335\320\175\6\326\62\7\173\361\73\315\55\215\276\11\44\35\324\125\36\111\376\242\124\5\45\301\202\334\313\375\54\66\76\236\324\323\346\225\306\251\205\215\16\7\266\375\17\44\361\106\203\304\363\157\104\270\316\360\154\122\223\337\121\302\72\265\356\214\314\146\5\367\126\372\225\205\364\171\112\317\260\161\60\26\250\17\251\173\322\250\370\356\12\373\224\326\130\167\301\255\252\312\16\220\222\35\374\324\43\153\26\23\153\204\231\372\270\14\343\171\67\133\317\212\151\122\341\330\352\340\125\364\153\132\345\276\275\174\371\303\177\212\157\177\170\371\362\73\374\77\264\230\77\1\250\117\261\41"}, -{688,1937,"ug.sc.as","Specific Animator Script Statements",0, -"\170\234\315\125\313\162\333\60\14\374\25\214\117\311\214\37\367\216\252\231\114\77\241\371\1\210\202\154\66\24\251\360\141\307\375\372\2\44\345\107\142\47\71\366\342\261\144\160\261\330\135\320\317\73\202\301\31\343\16\332\156\41\104\214\64\222\215\1\320\23\70\153\216\260\107\243\173\320\26\42\227\242\325\43\106\347\41\50\257\247\370\243\231\332\46\306\266\351\132\117\266\47\337\154\272\26\32\335\322\333\344\51\4\355\154\263\321\155\263\311\65\376\272\166\205\306\174\132\157\234\172\171\115\56\122\373\274\323\341\114\16\210\71\45\176\10\231\123\203\260\363\64\374\134\244\355\72\250\65\275\55\132\64\133\352\74\152\5\227\300\310\255\4\370\146\73\36\255\207\211\374\340\374\50\270\30\301\246\261\43\17\156\0\345\154\240\327\44\275\13\167\26\53\310\17\322\77\50\262\64\13\244\222\367\122\306\162\366\356\0\17\362\156\320\76\104\20\340\107\140\351\270\222\47\207\275\16\211\245\375\213\221\151\324\372\120\16\30\214\221\33\347\23\153\226\350\54\304\173\275\127\201\342\254\41\172\217\307\357\310\167\232\322\61\357\323\74\67\307\11\251\343\16\362\323\175\312\207\235\13\124\305\52\271\141\271\42\152\113\71" -"\66\125\362\153\166\367\247\252\3\175\65\103\56\14\231\225\360\224\100\320\311\21\66\167\325\323\220\31\224\240\276\17\11\356\27\355\36\275\306\316\120\310\311\210\116\216\152\17\174\20\223\211\25\162\15\271\261\162\343\50\1\341\257\51\320\220\214\230\3\43\276\344\255\111\74\163\116\114\155\206\346\200\307\300\331\43\225\346\224\6\34\11\370\65\113\322\323\44\242\333\310\333\125\31\153\313\206\133\64\300\123\305\313\160\235\170\73\277\306\205\110\364\124\127\260\250\304\314\135\367\207\124\274\247\250\161\330\377\147\133\46\224\12\150\217\21\145\144\316\122\334\25\11\75\51\347\373\32\247\65\74\261\307\20\46\122\232\305\121\30\150\311\317\214\75\241\147\101\243\334\70\272\66\354\132\113\157\347\360\210\127\50\27\133\216\141\210\204\375\111\324\273\374\226\222\330\303\116\253\135\156\226\253\5\165\246\305\230\302\236\372\173\162\147\317\71\176\262\2\336\231\125\111\304\154\300\240\15\131\346\375\55\371\113\172\372\302\270\153\177\25\104\370\175\106\34\274\33\241\334\60\206\212\206\202\76\317\367\241\33\74\224\321\306\24\4\137\363\247\370\221\37\353\316\336\357\366\370\161\25\220\23\353\266\56\205\272\75\263\17" -"\304\336\365\147\43\352\211\345\354\162\375\143\351\365\60\20\137\77\252\56\317\227\0\60\31\124\65\216\121\114\231\355\274\51\16\123\352\10\62\22\373\305\335\330\102\331\70\136\265\102\266\163\375\361\2\142\336\253\13\214\245\104\301\320\25\263\342\312\15\177\257\251\172\232\63\376\211\165\230\215\273\216\322\77\265\210\261\310"}, -{2033,6568,"ug.sc.av","Pre-defined Animator Script Variables",0, +{566,1599,"ug.sc.as","Specific Animator Script Statements",0, +"\170\234\315\124\315\156\333\60\14\176\25\242\247\26\310\317\275\360\14\24\173\204\365\5\150\211\216\205\311\222\53\321\115\272\247\37\51\331\115\263\45\135\217\273\4\160\114\175\277\224\237\7\202\76\172\37\217\56\34\40\63\62\215\24\70\3\46\202\30\374\33\274\242\167\26\134\0\226\121\14\156\104\216\11\262\111\156\342\307\146\152\33\346\266\351\332\104\301\122\152\366\135\13\215\153\351\64\45\312\331\305\320\354\135\333\354\313\114\272\234\335\242\367\237\316\373\150\176\276\314\221\251\175\36\134\76\213\3\22\115\263\74\344\242\251\101\30\22\365\337\356\346\303\56\233\35\235\356\132\364\7\352\22\72\3\37\201\121\250\24\370\52\235\130\263\60\121\352\143\32\25\27\31\302\74\166\224\40\366\140\142\310\364\62\53\167\325\56\141\145\175\241\374\331\120\240\65\40\63\247\244\143\22\247\215\107\270\327\377\172\227\62\203\2\77\200\104\47\223\342\34\136\135\236\45\332\137\310\42\143\231\317\365\200\107\146\41\56\47\166\22\321\71\210\77\363\336\146\342\65\103\114\11\337\276\22\337\273\313\50\272\337\375\134\265\223\347\116\30\364\325\155\311\307\41\146\132\302\252\173\43\161\61\272\100\145\155\226\310\57" +"\325\335\162\345\43\332\377\154\47\124\122\5\265\310\10\32\307\321\361\120\127\44\221\211\311\56\346\167\360\44\376\41\117\144\34\172\60\230\151\43\317\202\75\141\302\221\130\357\207\133\10\273\66\320\251\164\127\251\304\14\352\65\54\241\145\46\264\153\41\267\365\155\64\337\343\340\314\120\310\312\264\242\256\262\4\123\325\223\275\25\67\235\110\26\226\266\132\130\212\176\133\157\365\132\100\357\74\5\321\375\245\370\25\211\105\174\121\334\265\337\53\42\374\70\43\366\51\216\120\357\203\247\232\241\242\257\376\376\142\203\373\152\155\234\263\342\73\371\325\76\312\343\262\141\267\331\36\166\120\24\232\70\216\172\112\343\15\350\343\41\316\122\146\74\7\53\41\110\167\366\134\304\162\142\263\266\274\174\6\255\353\173\222\313\142\250\66\377\117\0\230\74\232\145\35\131\113\131\353\274\32\216\110\352\10\12\222\364\45\154\122\41\13\255\13\213\330\56\332\267\17\20\117\353\207\370\214\261\321\125\360\164\241\254\266\162\245\337\113\251\211\326\35\377\244\72\54\305\135\256\322\157\154\131\70\236"}, +{2037,6568,"ug.sc.av","Pre-defined Animator Script Variables",0, "\170\234\275\131\301\216\343\66\22\375\25\302\227\264\201\226\173\27\271\145\35\3\1\222\5\346\62\130\40\271\5\173\240\44\312\142\102\251\24\222\262\333\375\365\171\105\122\242\154\313\75\101\147\167\116\231\230\144\361\325\253\142\325\53\365\247\136\310\272\326\136\123\57\74\11\103\225\64\342\44\255\226\245\121\116\324\252\62\322\252\132\234\265\157\205\157\225\330\173\177\330\227\7\154\331\277\224\207\375\13\376\127\354\245\150\255\152\276\337\214\307\235\253\166\125\265\71\124\324\165\262\257\367\57\362\360\34\317\225\207\37\172\335\111\117\126\374\134\131\75\170\76\57\306\276\126\326\171\154\165\302\251\223\262\270\176\260\252\250\125\243\173\334\373\164\64\124\112\263\315\230\166\342\227\126\71\265\0\131\311\136\224\112\110\347\364\221\317\234\244\31\361\263\247\147\121\216\236\227\173\362\274\143\164\130\145\107\201\307\352\143\353\105\213\213\205\323\265\22\324\10\230\211\66\72\325\173\101\3\300\0\355\263\320\73\265\343\63\27\121\123\377\15\37\72\341\266\376\62\135\364\244\173\321\310\312\77\307\115\116\167\203\271\210\1\266\302\115\23\234\126\172\1\56\305\146\2\272\141\306\261\243\343\377\22\376\141\5\150\33" "\250\307\365\216\1\175\372\267\375\364\313\166\47\76\61\144\355\204\125\156\120\363\75\154\213\355\323\60\220\323\136\261\225\275\76\14\322\312\116\171\260\272\177\321\40\377\334\352\252\215\230\23\222\153\122\146\332\74\355\366\303\341\77\13\362\147\212\277\333\217\346\260\67\372\60\107\232\354\116\356\334\346\220\322\301\371\213\121\163\102\160\324\21\115\37\375\17\153\354\16\377\217\14\71\220\262\15\236\116\277\67\32\370\356\320\177\47\146\373\70\124\315\27\74\117\277\133\302\202\272\377\335\217\135\151\126\176\157\314\245\274\54\176\346\360\247\245\101\372\166\136\331\335\73\333\67\263\267\75\254\53\133\120\123\64\214\326\335\70\216\30\351\106\253\350\175\334\313\156\306\275\354\167\44\1\116\343\55\50\211\350\324\322\113\120\140\220\147\77\364\202\114\135\104\322\244\321\322\315\330\303\371\2\151\131\360\326\374\374\330\114\310\217\51\136\2\377\226\306\221\250\106\153\221\114\310\306\364\316\210\352\370\50\316\332\30\216\276\125\35\235\20\152\244\260\24\6\240\254\300\43\164\10\320\32\5\345\12\5\270\17\266\353\217\120\21\201\53\161\264\262\36\361\360\203\51\335\37\171\213\33\113\247\376\30\371\45\306\335\357" "\121\363\0\303\127\144\306\257\60\343\255\354\135\50\255\377\13\162\262\65\240\363\147\245\142\35\363\147\70\103\375\304\325\234\111\50\113\241\70\30\324\267\112\341\241\71\103\147\270\133\153\347\310\234\260\216\302\140\142\5\351\325\371\172\23\356\356\334\366\75\306\37\373\366\365\110\157\162\375\11\357\272\0\243\252\176\124\205\170\155\252\66\25\20\133\311\267\204\332\143\56\105\171\21\35\325\152\345\226\172\230\157\11\325\206\135\36\132\375\340\232\151\113\150\12\265\72\132\245\334\26\245\232\340\161\354\6\312\242\222\41\236\362\25\264\274\23\311\224\6\117\21\353\67\240\360\115\167\243\157\267\153\30\375\75\106\230\364\362\243\50\133\262\372\215\172\377\21\234\312\250\123\260\276\212\324\336\43\265\144\314\107\201\246\110\6\220\41\341\303\277\120\43\7\56\45\325\10\365\222\272\54\62\34\247\373\355\227\175\131\203\375\66\303\176\43\352\126\320\362\317\251\164\305\313\370\71\175\344\252\327\234\325\225\45\347\12\207\226\317\64\375\365\354\136\36\3\163\215\320\236\337\40\166\63\27\374\302\260\17\34\36\243\244\73\151\207\2\243\337\42\323\1\371\26\57\21\317\217\233\362\304\336\164\303\334\301\357\260\127" "\273\334\42\143\134\212\206\365\144\61\220\356\375\25\362\175\151\157\216\216\267\107\117\132\235\213\161\370\302\261\327\333\143\101\13\1\335\65\121\254\225\276\375\21\116\0\71\162\272\36\121\226\212\40\207\240\162\100\24\331\250\53\243\104\212\132\355\126\126\116\142\315\265\64\242\252\362\222\370\266\230\25\33\356\260\362\262\23\77\53\357\71\21\374\215\112\145\332\143\260\2\51\42\220\22\265\361\206\175\25\343\260\111\130\142\46\317\225\242\326\66\305\262\261\324\55\322\36\217\55\130\341\260\260\211\155\24\64\274\141\242\341\246\342\45\5\211\270\242\10\347\310\206\76\124\107\143\53\141\35\334\35\313\220\151\306\50\123\70\0\274\21\176\25\104\365\61\271\232\256\235\266\213\260\75\53\152\321\252\40\303\23\110\366\141\40\353\271\60\237\311\242\363\124\104\26\212\200\305\22\32\27\306\204\212\205\300\147\362\51\106\201\275\140\164\223\333\15\216\376\216\162\351\130\320\157\164\317\15\104\211\264\251\100\127\261\107\264\225\330\157\101\240\245\172\254\260\336\61\102\53\220\334\307\70\144\54\73\130\13\153\75\11\325\64\140\217\341\241\302\114\114\262\211\337\122\200\102\17\171\247\155\46\372\256\131\373\132\35\23" "\201\314\275\54\203\176\120\122\26\136\135\325\64\144\215\322\141\130\231\205\163\14\156\366\207\362\132\246\351\261\266\76\165\73\223\225\45\162\35\61\57\214\54\225\171\367\361\343\130\225\217\125\144\310\26\245\264\356\113\207\312\174\250\344\76\202\307\132\224\364\172\103\3\6\136\10\163\70\317\57\212\232\46\275\347\310\101\243\244\37\155\232\105\57\241\122\120\217\40\55\313\305\64\334\234\127\246\262\171\256\151\165\135\253\176\215\71\24\145\275\34\141\42\153\367\24\305\52\226\55\40\24\164\16\123\106\174\327\227\74\203\362\23\32\214\274\0\234\114\355\65\30\22\301\120\56\56\56\214\347\53\255\311\347\372\356\265\107\5\35\360\126\256\207\221\65\145\13\307\305\223\304\360\34\252\356\37\43\136\57\104\251\267\40\176\73\313\334\360\356\202\162\145\354\230\324\303\3\26\341\36\61\204\265\264\363\161\3\2\302\176\25\342\337\35\330\22\161\261\217\147\104\245\2\46\225\206\134\151\375\335\220\273\206\260\374\2\302\277\61\117\325\43\163\232\46\376\33\254\151\214\130\116\0\317\210\377\111\241\76\305\156\65\353\0\225\106\206\25\364\46\203\67\164\244\377\157\354\371\206\264\226\224\72\262\265\217\36\77\320" -"\55\153\220\351\32\62\15\262\322\376\362\36\352\264\145\272\47\340\10\210\32\103\62\64\367\330\166\123\0\46\225\367\217\120\53\376\271\206\141\270\306\260\56\122\256\101\334\166\360\11\305\362\243\11\215\226\367\205\112\361\116\225\31\7\376\150\140\124\343\213\310\340\375\207\221\270\45\174\24\173\270\7\205\345\241\231\305\207\224\270\155\325\324\262\210\271\321\66\262\132\144\17\127\352\25\335\273\266\341\104\146\354\126\217\202\1\210\46\263\174\70\213\143\101\135\41\151\225\251\327\326\275\352\335\335\372\327\251\356\261\221\244\256\143\271\2\330\64\115\144\311\166\223\360\124\162\177\166\213\36\265\102\57\302\165\132\266\146\35\124\121\220\252\371\233\156\255\73\170\316\66\61\234\360\247\6\272\251\57\311\30\236\141\322\140\230\52\130\302\141\256\220\125\245\6\37\254\152\240\176\25\154\201\263\330\316\343\65\331\56\370\375\353\347\377\246\154\71\103\76\304\117\311\237\147\130\71\347\117\323\325\120\122\361\121\0\323\222\145\46\171\126\124\121\41\145\17\73\45\373\44\76\343\322\214\172\122\370\223\42\347\171\110\73\232\234\13\114\345\232\224\16\55\121\76\141\215\327\121\106\27\124\200\37\110\303\73\347\141\37" -"\217\312\100\127\363\27\134\346\20\221\235\255\326\244\130\121\172\241\60\257\206\61\0\7\322\107\363\171\261\345\24\170\142\335\151\55\5\223\126\261\76\146\223\213\120\137\217\211\167\265\45\100\321\235\116\243\360\373\371\61\261\363\57\216\155\326\202\123\55\232\330\11\127\212\151\304\234\274\172\162\300\365\302\237\212\207\303\117\322\32\235\305\150\376\236\35\205\55\163\23\74\111\37\276\163\124\346\357\344\131\373\326\152\200\122\221\274\273\100\173\110\375\252\213\32\30\275\344\310\202\76\162\204\66\350\46\1\317\343\307\40\113\155\200\75\304\251\121\374\247\214\222\373\70\135\315\146\174\35\124\264\105\136\32\236\342\161\47\0\52\133\141\346\235\116\314\177\372\120\110\315\232\107\171\157\211\7\240\351\157\31\251\132\244\30\106\67\242\30\243\50\233\343\140\24\376\162\200\356\241\154\217\264\166\151\132\14\342\213\37\144\172\64\67\177\53\331\375\11\121\44\1\64"}, +"\55\153\220\315\65\144\376\304\265\122\366\256\140\117\173\246\233\2\22\140\132\176\260\240\321\162\227\15\257\364\235\27\76\16\74\260\33\325\370\42\242\277\377\50\21\267\204\17\122\17\367\340\121\77\64\263\370\210\21\267\255\232\132\243\206\256\251\241\101\126\332\137\336\143\46\155\271\45\6\63\247\41\31\164\117\124\44\51\67\47\1\374\217\0\362\237\313\42\346\106\333\310\152\221\75\134\251\127\164\357\332\206\23\231\261\133\75\212\50\100\64\231\345\303\131\34\13\352\12\111\253\114\275\266\356\125\357\356\326\277\116\165\217\215\44\165\35\313\25\300\246\151\42\113\266\233\204\247\222\373\263\133\364\250\25\172\221\62\247\145\153\326\101\25\5\251\232\277\351\326\272\203\347\154\23\303\11\177\152\240\233\372\222\214\341\31\46\15\206\251\202\45\34\346\12\131\125\152\360\301\252\6\352\127\301\26\70\137\354\74\136\223\355\202\337\277\176\376\157\312\330\63\344\103\374\224\374\171\206\225\125\353\151\272\32\112\52\246\37\60\55\131\146\222\147\105\25\25\122\366\260\123\262\117\342\63\56\315\250\47\205\77\51\162\236\207\264\243\311\271\300\124\256\111\351\320\22\345\23\326\170\35\145\164\101\5\370\201\64\274" +"\163\36\366\361\260\15\164\65\177\301\145\16\21\331\331\152\115\212\25\245\27\12\363\152\30\3\160\40\175\64\237\27\133\116\201\47\326\235\326\122\60\151\25\353\143\66\271\10\365\365\230\170\67\0\5\50\272\323\151\24\176\77\77\46\166\376\305\261\315\132\160\232\46\46\166\302\225\142\32\61\47\257\236\34\160\275\360\247\342\341\360\223\264\106\147\61\232\277\147\107\141\313\334\4\117\322\207\357\34\225\371\73\171\326\276\265\32\240\124\44\357\56\320\36\122\277\352\242\6\106\57\71\262\240\217\34\241\15\272\111\300\363\370\61\310\122\33\140\17\161\152\24\377\51\243\344\76\116\127\263\31\137\7\25\155\221\227\206\247\170\334\11\200\312\126\230\171\247\23\363\237\76\24\122\263\346\121\336\133\342\1\150\372\133\106\252\26\51\206\321\215\50\306\50\312\346\70\30\205\277\34\240\104\52\333\43\255\135\232\26\203\370\342\7\231\36\315\315\337\112\166\177\2\11\301\0\370"}, {110,126,"ug.ce.i","Code Examples",0, "\170\234\45\214\101\16\203\60\14\4\277\262\57\200\17\40\156\105\342\336\17\230\304\101\226\102\214\34\247\320\337\67\250\267\321\356\354\276\156\72\316\314\25\232\20\364\70\233\263\165\210\75\111\152\270\114\134\312\216\165\261\365\215\110\116\110\362\350\144\14\372\220\144\332\62\103\12\46\367\71\152\250\323\330\1\121\214\203\253\175\237\337\377\270\152\263\300\275\251\156\262\65\27\55\303\17\130\272\55\273"}, {795,5723,"ug.ce.f","Fortran",0, diff -Nru ifrit-3.3.4/help/ihelpfactorydataUG.h.stub ifrit-3.4.2/help/ihelpfactorydataUG.h.stub --- ifrit-3.3.4/help/ihelpfactorydataUG.h.stub 2011-01-27 17:50:36.000000000 +0000 +++ ifrit-3.4.2/help/ihelpfactorydataUG.h.stub 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -//LICENSE A -#include "../Work/help/ihelpfactorydataUG.txt" diff -Nru ifrit-3.3.4/help/iimagefactory.cpp ifrit-3.4.2/help/iimagefactory.cpp --- ifrit-3.3.4/help/iimagefactory.cpp 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactory.cpp 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -139,7 +139,7 @@ f.WriteLine("//LICENSE A"); f.WriteLine("#if 0"); - f.WriteLine("#include \"../Work/help/iimagefactorydataempty.h\""); + f.WriteLine("#include \"../../Work/help/iimagefactorydataempty.h\""); f.WriteLine("#else"); wlist = "const iImageFactory::ByteData data[] = {\n"; diff -Nru ifrit-3.3.4/help/iimagefactory.h ifrit-3.4.2/help/iimagefactory.h --- ifrit-3.3.4/help/iimagefactory.h 2011-01-27 17:52:01.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactory.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/help/iimagefactorydata1.cpp ifrit-3.4.2/help/iimagefactorydata1.cpp --- ifrit-3.3.4/help/iimagefactorydata1.cpp 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata1.cpp 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -26,6 +26,7 @@ =========================================================================*/ +#include "iconsole.h" #include "iimagefactory.h" #include "istring.h" @@ -45,6 +46,7 @@ if(num == 0) { CreateData("Work/images","Code/help/iimagefactorydata1.h","az"); + iConsole::Display(iConsole::_Warning,"IFrIT is creating compressed help data...\nPlease compile again and re-run."); exit(0); } diff -Nru ifrit-3.3.4/help/iimagefactorydata1.h ifrit-3.4.2/help/iimagefactorydata1.h --- ifrit-3.3.4/help/iimagefactorydata1.h 2011-01-27 17:52:01.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata1.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -25,7 +25,7 @@ =========================================================================*/ #if 0 -#include "../Work/help/iimagefactorydataempty.h" +#include "../../Work/help/iimagefactorydataempty.h" #else static unsigned int art_png[] = {0x828282,0x8c8c8d,0x27e7e7e,0x37b7b7c,0x37b7b7b,0x3787879,0x3767676,0x3737373,0x3717171,0x36e6e6e,0x36c6c6c,0x36a6a6a,0x3676768,0x3656565,0x3636363,0x3616161,0x35f5f5f,0x35e5e5e,0x35c5c5c,0x35b5b5b,0x3595959,0x3585858,0x3585858,0x3585858,0x3585858,0x3585858,0x3585858,0x3585858,0x3575757,0x2585858,0x626262,0x5d5d5d,0x909090,0x64787879,0xe19d9e9e,0xe89f9e9f,0xe89b9b9c,0xe8989898,0xe8959595,0xe8929192,0xe88e8e8f,0xe88b8b8b,0xe8888888,0xe8858586,0xe8838383,0xe8808080,0xe87d7d7d,0xe87b7b7b,0xe8797979,0xe8767677,0xe8747475,0xe8737373,0xe8717171,0xe8707070,0xe8707070,0xe8707070,0xe8707070,0xe8707070,0xe8707070,0xe8707070,0xe8707070,0xe06c6c6c,0x61565656,0x646464,0x2848485,0xe1a4a4a4,0xffbdbdbd,0xffb9b9b9,0xffb5b5b5,0xffb1b1b2,0xffaeadae,0xffaaaaaa,0xffa6a6a6,0xffa3a3a3,0xff9f9fa0,0xff9c9c9c,0xff989899,0xff959595,0xff929292,0xff8f8f8f,0xff8d8c8d,0xff8a8a8a,0xff878787,0xff858585,0xff838383,0xff818181,0xff808080,0xff808080,0xff808080,0xff808080,0xff808080,0xff808080,0xff808080,0xff808080,0xdd6b6b6b,0x15f5f5f,0x3858586,0xe8acacac,0xffc0c0c1,0xffa67b66,0xffbb8144 ,0xffbd8945,0xffbd8945,0xffbd8945,0xffbe8945,0xffbd8945,0xffbd8945,0xffbd8945,0xffbd8945,0xffbd8945,0xffbd8945,0xffbe8945,0xffbe8945,0xffbe8945,0xffbe8945,0xffbe8945,0xffbe8946,0xffbe8946,0xffbe8a46,0xffbf8a47,0xffbf8a47,0xffc08b47,0xffc08b48,0xffbe8547,0xffa97f69,0xff808080,0xe46e6e6e,0x25a5a5a,0x38a8a8a,0xe8b0b0b0,0xffc5c5c5,0xffb56d41,0xffeb8c14,0xffef9b16,0xffc4b788,0xff9abab9,0xff76b8d6,0xff86aba4,0xffaab598,0xffd6b46a,0xfff1aa36,0xfff09e1b,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9c16,0xffef9b16,0xffeb8e14,0xffb97244,0xff808080,0xe46e6e6e,0x25b5b5b,0x38c8c8d,0xe8b3b3b3,0xffc9c9c9,0xffb56a41,0xffe88212,0xffec9014,0xffec9114,0xffec9217,0xffe79d35,0xffa8a27c,0xff56a6d0,0xff089cff,0xff19a3ff,0xff58aedd,0xffa0ac97,0xffe5a649,0xffed931a,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9114,0xffec9014,0xffe88312,0xffb76e44,0xff808080,0xe46e6e6e,0x25b5b5b,0x38f8f90,0xe8b6b6b7,0xffcdcdcd,0xffb36541,0xffe47510,0xffe88212,0xffe88312,0xffe88312,0xffe88312 @@ -497,6 +497,16 @@ ,0xf82400,0x2300f427,0x8d8d8dc0,0xbfbdbc,0x2700c023,0xf82500f4,0xfa2200,0x2400fa22,0xf62500f8,0xf42700,0x2400f12a,0x815248c6,0xc0bab6b5,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbfc0,0x975f53,0x2a00c624,0xf42700f1,0xf62500,0x2200f824,0xfa2200fa,0xf82500,0x2300f427,0x8d8d8dc0,0xbfbdbc,0x2800bf23,0xf72500f3,0xf92400,0x2500f824,0xf42700f6,0xf12a00,0x5248c624,0xbab6b581,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x53bfbfbf,0x2400975f,0xf12a00c6,0xf42700,0x2400f625,0xf92400f8,0xf72500,0x2300f328,0x8d8d8dbf,0xbfbdbc,0x2900bf24,0xf52600f2,0xf72500,0x2700f626,0xf12a00f4,0x47c62400,0xb6b58151,0xc0c0c0ba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0x5f53bfbf,0xc6240097,0xf12a00,0x2600f427,0xf72500f6,0xf52600,0x2400f229,0x8d8d8dbf,0xbfbdbc,0x2a00be24,0xf42700f0,0xf52600,0x2a00f427,0xc72500f1,0xb5815147,0xc0c0bab6,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0x975f53bf,0xc72500,0x2700f12a,0xf52600f4,0xf42700,0x2400f02a,0x8d8d8dbe,0xbfbdbc ,0x2c00bd25,0xf12900ef,0xf22800,0x2500f12a,0x815147c7,0xc0bab6b5,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbfc0,0x975f53,0x2a00c725,0xf22800f1,0xf12900,0x2500ef2c,0x8d8d8dbd,0xbfbdbc,0x2e00bf25,0xef2c00ec,0xef2c00,0x5146c725,0xbab6b580,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x52bfbfbf,0x2500975e,0xef2c00c7,0xef2c00,0x2500ec2e,0x8d8d8dbf,0x1bfbdbd,0x2f00b824,0xec2e00eb,0x46c62600,0xb6b58051,0xc0c0c0ba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0x5e52bfbf,0xc6260097,0xec2e00,0x2300eb2f,0x939393b7,0x2dc0c0c0,0x2f009c43,0xc62600eb,0xb5805146,0xc0c0bab6,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0x975e51bf,0xc62600,0x3019eb2f,0xb0abaa92,0x83c0c0c0,0x1d01b08c,0x834f4398,0xc0b9b5b4,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbfc0,0x9b594b,0x7772981c,0xbebdbd8d,0xc0c0c0c0,0xaeabc0c0,0xbebcbcb9,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xaabfbfbf,0xbebeb8ac,0xc0c0c0bf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int create_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0xbebebfbf,0xbdbdbdbe,0xbebdbdbd,0xbfbfbebe,0xc0c0c0bf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb0bbbaba,0xa9a9b1b0,0xa5a5a5a9,0xa9a5a5a5,0xb2b2a9a9,0xbbbbbbb2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdbdbcc0,0x68abaaaa,0x60438074,0x7b5d3e7d,0x437b5d3e,0x79707d60,0xadadad83,0xc0bdbdbd,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9b9b9c0,0x23949492,0x8c31bf71,0xe88d31e7,0x31e88d31,0x6d28e78c,0x9d9d9db0,0xc0bbbaba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb7b6b6c0,0x218c8a89,0x8a2dc875,0xe78a2de7,0x2de78a2d,0x7226e78a,0x939291bd,0xc0b8b8b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1e8b8987,0x8727ca75,0xe68727e6,0x27e68727,0x7223e687,0x91908fbf,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1c8b8987,0x8421cc74,0xe68421e6,0x21e68421,0x7221e684,0x91908fc1,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1a8b8987,0x801ace74,0xe4801ae4,0x1ae4801a,0x711ee480,0x91908fc3,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0 +,0x198b8987,0x7c18cf74,0xdf7c18df,0x18df7c18,0x711ddf7c,0x91908fc4,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x198c8987,0x7717cf74,0xd87717d8,0x17d87717,0x711dd877,0x92908fc3,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x198c8a87,0x7216cd73,0xcd7216cd,0x16cd7216,0x6f1dcd72,0x92908fc1,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdbdc0c0,0xb8b8b8bd,0xb5b6b6b6,0xb5b5b5b5,0xb5b5b5b5,0xb5b5b5b5,0xb5b5b5b5,0xabababb5,0x19868481,0x6c15cb72,0xc46c15c4,0x15c46c15,0x6e1cc46c,0x8b8987c0,0xb5acacac,0xb5b5b5b5,0xb5b5b5b5,0xb5b5b5b5,0xb5b5b5b5,0xb6b6b6b5,0xbdb9b9b9,0xc0c0bdbd,0xc0c0c0c0,0xbac0c0c0,0xaaaabbbb,0x959391aa,0x858c8a87,0x88858b88,0x8b88858b,0x858b8885,0x88858b88,0x85827f8b,0x19776f67,0x6814c971,0xbc6814bc,0x14bc6814 +,0x6d1bbc68,0x7a746dbf,0x8585827f,0x88858b88,0x8b88858b,0x858b8885,0x88858b88,0x8d8a888b,0xad969493,0xbbbbadad,0xc0c0c0bc,0xb0bfbfbf,0x7c69b1b1,0xc7711c8f,0x19c87119,0x7119c871,0xc87119c8,0x19c87119,0x7119c871,0xc87119c8,0x14c87018,0x6614bc68,0xb86614b8,0x14b86614,0x6814b866,0xc87019bd,0x19c87119,0x7119c871,0xc87119c8,0x19c87119,0x7119c871,0xc77019c8,0x79c6721e,0xb4b38e83,0xc0c0c0b4,0xa9bebebe,0x6f49a9a9,0xb8661495,0x14b86614,0x6614b866,0xb86614b8,0x14b86614,0x6614b866,0xb86614b8,0x14b86614,0x6614b866,0xb86614b8,0x14b86614,0x6614b866,0xb86614b8,0x14b86614,0x6614b866,0xb86614b8,0x14b86614,0x6614b866,0xb86614b8,0x59b86614,0xadad8a72,0xbfbfbfad,0xa6bdbdbd,0x6f47a6a6,0xbc681496,0x14bc6814,0x6814bc68,0xbc6814bc,0x14bc6814,0x6814bc68,0xbc6814bc,0x14bc6814,0x6814bc68,0xbc6814bc,0x14bc6814,0x6814bc68,0xbc6814bc,0x14bc6814,0x6814bc68,0xbc6814bc,0x14bc6814,0x6814bc68,0xbc6814bc,0x56bc6814,0xaaaa8970,0xbebebeaa,0xa6bdbdbd,0x6f48a6a6,0xc36c1596,0x15c36c15,0x6c15c36c,0xc36c15c3,0x15c36c15,0x6c15c36c,0xc36c15c3,0x15c36c15,0x6c15c36c,0xc36c15c3,0x15c36c15,0x6c15c36c,0xc36c15c3,0x15c36c15,0x6c15c36c +,0xc36c15c3,0x15c36c15,0x6c15c36c,0xc36c15c3,0x56c36c15,0xaaaa8a70,0xbebebeaa,0xaabebebe,0x724baaaa,0xcc711699,0x16cc7116,0x7116cc71,0xcc7116cc,0x16cc7116,0x7116cc71,0xcc7116cc,0x16cc7116,0x7116cc71,0xcc7116cc,0x16cc7116,0x7116cc71,0xcc7116cc,0x16cc7116,0x7116cc71,0xcc7116cc,0x16cc7116,0x7116cc71,0xcc7116cc,0x5ccc7116,0xadad8c74,0xbfbfbfad,0xb2bfbfbf,0x8172b2b2,0xc7792a90,0x24cb7824,0x7824cb78,0xcb7824cb,0x24cb7824,0x7824cb78,0xcb7824cb,0x19cd7822,0x7617d779,0xd57617d5,0x17d57617,0x7818d576,0xcd7822d6,0x24cb7824,0x7824cb78,0xcb7824cb,0x24cb7824,0x7824cb78,0xcb7824cb,0x80c5782c,0xb5b49189,0xc0c0c0b5,0xbbc0c0c0,0xafafbcbb,0xa0a0a0af,0x96989898,0x95959696,0x95959595,0x95959595,0x95959595,0x8f8f8f95,0x1d797672,0x7a18df7f,0xdc7a18dc,0x18dc7a18,0x791fdc7a,0x7c7a78d3,0x958f8f8f,0x95959595,0x95959595,0x95959595,0x95959595,0x98989895,0xb0a1a1a1,0xbcbcb1b1,0xc0c0c0bd,0xc0c0c0c0,0xbdbdc0c0,0xbbbababe,0xb8b9b9b9,0xb8b8b9b8,0xb9b8b8b9,0xb8b9b8b8,0xb8b8b9b8,0xaeaeaeb8,0x1b888582,0x7c18e07e,0xe07c18e0,0x18e07c18,0x791fe07c,0x8d8b8ad2,0xb8b0b0b0,0xb8b8b9b8,0xb9b8b8b9,0xb8b9b8b8,0xb8b8b9b8,0xb9b9b9b9 +,0xbebbbbbb,0xc0c0bebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1b8c8a87,0x7f1ade7d,0xe47f1ae4,0x1ae47f1a,0x781fe47f,0x92908fd2,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1d8c8a87,0x811edb7c,0xe5811ee5,0x1ee5811e,0x7721e581,0x92908fce,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1e8b8987,0x8423d67a,0xe68423e6,0x23e68423,0x7623e684,0x91908fca,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x1f8b8987,0x8726d279,0xe68726e6,0x26e68726,0x7524e687,0x91908fc6,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x218b8987,0x892acd77,0xe7892ae7,0x2ae7892a,0x7425e789,0x91908fc1,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb6b6b6c0,0x228a8987,0x8b2ec976,0xe78b2ee7,0x2ee78b2e,0x7327e78b,0x91908fbe,0xc0b7b7b7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb7b7b6c0,0x228c8b8a,0x8d31c574,0xe88d31e8,0x31e88d31,0x7228e88d,0x939392bb,0xc0b8b8b8,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9b9b9c0,0x24969594,0x8d32b66d,0xe88e34e7,0x32e88e34,0x6929e78d,0x9f9e9ea7,0xc0bbbaba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdbdbdc0,0x78adadad,0x6657847e,0x72625275,0x57726252,0x837f7566,0xb0b0b088,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb3bcbcbc,0xadadb4b4,0xaaaaaaad,0xadaaaaaa,0xb4b4adad,0xbcbcbcb5,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0xbebebebf,0xbfbebebe,0xc0c0bfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int create2_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbabac0c0,0xb3b3b3ba,0xbbb3b3b3,0xc0c0bbbb,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdc0c0c0,0x7b6ebdbd,0xa76f3587,0x75a76f35,0xbebe897f,0xc0c0c0be,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6c4fbbbb,0xe7892a8a,0x56e7892a,0xbcbc886f,0xc0c0c0bc,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6c4dbbbb,0xe5821e8b,0x54e5821e,0xbbbb8a6f,0xc0c0c0bb,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6d4dbbbb,0xdb7a178c,0x53db7a17,0xbbbb8b6f,0xc0c0c0bb,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdc0c0c0,0xbababdbd,0xbabababa,0xb5bababa,0x6b4bb5b5,0xc96f158b,0x51c96f15,0xb6b6896d,0xbababab6,0xbbbababa,0xbdbdbbbb,0xc0c0c0bd,0x6dbbbaba,0x6b4b8c7d,0x8a6b4b8a,0x4a8a6b4b,0x6529896a,0xba6714a1,0x2bba6714,0x6a4a9e65,0x8a6b4b89,0x4c8a6b4b,0x80738a6b,0xbcbcbc8d,0x2eb3b3b3,0x6714a468,0xba6714ba,0x14ba6714,0x6714ba67,0xba6714ba,0x14ba6714,0x6714ba67,0xba6714ba,0x14ba6714,0x6634ba67,0xb5b5b599,0x2fb3b3b3,0x6e15aa6c,0xc76e15c7,0x15c76e15,0x6e15c76e +,0xc76e15c7,0x15c76e15,0x6e15c76e,0xc76e15c7,0x15c76e15,0x6b36c76e,0xb5b5b59f,0x78bbbbbb,0x73599184,0x8c73598d,0x568c7359,0x6e308b71,0xd87817aa,0x32d87817,0x7257a76d,0x8c73598c,0x598c7359,0x877d8d73,0xbcbcbc91,0xbec0c0c0,0xbdbcbebe,0xbcbcbcbd,0xb7bcbcbc,0x6f4cb7b7,0xe27d1992,0x52e27d19,0xb7b78f70,0xbcbcbcb8,0xbcbcbcbc,0xbebebdbd,0xc0c0c0be,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6f4ebbbb,0xe583208f,0x54e58320,0xbbbb8d71,0xc0c0c0bb,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6e4fbbbb,0xe688288c,0x55e68828,0xbbbb8a70,0xc0c0c0bb,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbc0c0c0,0x6c50bbbb,0xe78c3088,0x57e78c30,0xbcbc876f,0xc0c0c0bc,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdc0c0c0,0x7e74bdbd,0x9a6d3e88,0x7a9b6d3f,0xbebe8a82,0xc0c0c0be,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcbcc0c0,0xb5b5b5bc,0xbcb5b5b5,0xc0c0bcbc,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; static unsigned int cycle_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc7b3bfc2,0xbfc194bc,0xc0c0c0b8,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbcbbc0,0xb8bfb9b8,0xbab8bfb9,0xbfbab8bf,0xb8bfbab8,0xbab9bfba,0xbebbbbbf,0xc0bfbfbf,0xc0c0c0c0,0xbebfc0c0,0xce6bb9ce,0xbec26ab9,0xb9bfc1b0,0xc0b9bfc1,0xbfc0babf,0xc0c0c0bd,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xafacc0c0,0xba897dbe,0x77b98274,0x8477ba84,0xba8477ba,0x7aba8477,0x887cba86,0xb99890ba,0xc0b6bdbf,0xc0c0c0c0,0x9dbdc5c0,0xd21db3da,0xbacb4eb7,0x7dbacb79,0xc97dbacb,0xbdc487bb,0xb8bfc1a2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb2c0c0c0,0x543cbeb4,0xb12c0bb5,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xcb12b0a,0x2d0db12c,0xb06350b1,0xc0b1bcc0,0xbfc1c0c0,0x40b6d5b8,0xdd0bb2dd,0xb2dd0db2,0xeb2dd0e,0xdb0eb2dd,0xb7d118b3,0x9fbdc557,0xc0bbbfc0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x5ebfbebd,0x2d0cb870 ,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb06250b1,0xbfb1bdc0,0xbacbbfbf,0x10b2dd79,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xde0bb2de,0xb2dc0bb2,0x6bb9ce12,0xc0aabec3,0xc0c0bfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x19bda59f,0x2b0ab237,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb06451b1,0xc0b1bdc0,0xb4d9acbc,0xbb2dd25,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xde0bb2de,0xb2de0bb2,0x26b4d90b,0xc190bcc7,0xc0c0b7bf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbfc0,0xab66652,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb06452b1,0xc9b1bdc0,0xb2dd7cb9,0xbb2de0f,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xde0bb2de,0xb2de0bb2,0xdb2dd0b,0xc35bb8d0,0xbfc0a9be,0xc0c0c0bf,0xc0c0c0c0,0xc0c0c0c0,0xbda39dc0,0xab23719,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb06553b1,0xbfb1bdc0,0xb5d7b7be,0xbb2dd32,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xde0bb2de,0xb2de0bb2,0xbb2dd0b,0xc723b3d9,0xbfc191bc,0xc0c0c0b8,0xc0c0c0c0,0xbcbbc0c0,0xb6614cbf,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1 ,0xab12b0a,0x2b0ab12b,0xb16654b1,0xc0b2bdc0,0xbcc8c0c0,0x14b2dc8d,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xde0bb2de,0xb2de0bb2,0xbb2de0b,0xd00eb2dd,0xbec35fb8,0xbfbfc0aa,0xc0c0c0c0,0x988fc0c0,0xb13313bc,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb12b0ab1,0xab12b0a,0x2b0ab12b,0xb16a59b1,0xc0b6bdbf,0xbfc0c0c0,0x53b7d2bd,0xdc0cb2dd,0xb2dc12b2,0x14b2dc17,0xdc14b2dc,0xb2dc14b2,0xdb2dd13,0xd90bb2de,0xbcc628b4,0xb8bfc196,0xb7c0c0c0,0x5740bfb8,0xb3462bb5,0x48b55841,0x5a43b65d,0xb65d48b5,0x56b76652,0x6854b769,0xb6644fb7,0x4fb6644f,0x6552b664,0xb69289b4,0xc0bebebe,0xc0c0c0c0,0xabbec3c0,0xce26b4d9,0xbdc666b9,0x9dbdc59a,0xc69dbdc5,0xb8d09bbd,0x3cb5d55e,0xdb3eb5d5,0xb8cf1cb3,0xadbec363,0xa0c0c0c0,0x7c6dbda6,0xb6604ab9,0x1eb3452a,0x3d20b23b,0xb98072b2,0xc0bfbab8,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc97fbbca,0xbfc087bb,0xc0c0c0bc,0xc6c0c0c0,0xb3db9bbd,0xdb2dd1c,0xd51bb3db,0xb6d43eb6,0x9bbdc645,0x90c0c0c0,0x3d20bc99,0xb12c0bb2,0xab12b0a,0x3313b12b,0xba8c81b1,0xbfbeb3b1,0xbebebfbf,0xbfbebebf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 @@ -563,6 +573,16 @@ ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xadb7bbbe,0x8aa88398,0x7587996d,0xc0a7aaac,0xbebfc0c0,0xbdbdbebe,0xc0bfbfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0xb9bcbabd,0xbbbcbdb6,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; static unsigned int delay_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xa1b8b8b8,0x97999f9f,0x97979a97,0x90939396,0x96978e8e,0xb6b6b696,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0xa1a1a3bf,0xc6adadb1,0xb9cc97bd,0x3bb8ce5a,0xc639b7cd,0xafb852b4,0x92939586,0xbf959596,0xc0c0bfbf,0xc0c0c0c0,0xbfc0c0c0,0x9091bfbf,0xaebdc390,0xe439b7cd,0xd0f108c4,0xad5f609,0xf10ad5f6,0xc3e309d0,0x36b7ce07,0x8ba0b2b7,0xbfbf8a8a,0xc0c0c0bf,0x8fc0c0c0,0x9ca18d8d,0x1bb4ce8f,0xfd09d0f1,0xe2ff0fdd,0x1de3ff18,0xfe1de3ff,0xddfc18e2,0x9cef00e,0xbd1cb9d4,0x9899a6b8,0xc0c0c098,0x6cb4b4b4,0x9db26a6a,0x9d0f12a,0xff13e0fe,0xe6ff24e4,0x31e7ff2d,0xff31e7ff,0xe4ff2de6,0x12e0fe23,0xd009cef0,0xa0a33aba,0xb7b7b7a0,0x838e8e8f,0xc1e0637d,0xfdefd07,0xff24e4ff,0xe8ff32e7,0x3be8ff39,0xff3be8ff,0xe7ff38e8,0x23e4ff32,0xe30eddfc,0xc2ca07c3,0x9d9d9e9a,0xa789898b,0xd1f24f99,0x19e2ff09,0xff2ee6ff,0xe7fe39e8,0x3ec1d23d,0xbd3eaebe,0xaebd3dae,0x32adbd3a,0xe823b0c5,0xc3d40bc8,0x99999c64,0xb39b9b9d,0xd7f83fa2,0x1ee3ff0a,0xff32e7ff,0xbfd23be8,0x181c1c37,0x19181919,0x19191819,0x17191918,0xc82a3030,0xbfd517af,0xa1a1a345,0xb3a5a5a8,0xd7f842a2,0x1fe3ff0b,0xff32e7ff,0xa7b73be8 ,0x404042e,0x771f3f44,0x6d771f6c,0x186c771d,0xf21b8f9f,0xbcd10bd1,0x9b9b9d42,0xb2a7a7a9,0xcded61a4,0x1ae2ff09,0xff2ee6ff,0xa7b739e8,0x808082e,0xfe3f858f,0xe8ff3de7,0x2de6ff39,0xf118e2ff,0xb0c109d0,0x89898b54,0xbcaaaaac,0xb0cda0b5,0x10defd07,0xff25e5ff,0xa7b733e7,0x808082b,0xfe3e858f,0xe7ff39e7,0x24e4ff32,0xe30fddfd,0x8a9207c3,0x8e8e8f66,0xb9bababb,0x9fb0b6b6,0x9c9e944,0xff15e1fe,0xa6b725e5,0x8080823,0xfe3a858f,0xe4ff2ee6,0x13e0fe24,0xb209d0f1,0x6567239d,0xb4b4b465,0xacc0c0c0,0xc8ccaaaa,0x249cb1c1,0xfd09c9e9,0xa3b710de,0x8080814,0xfe308a96,0xdefd19e2,0x9d0f10f,0x8c19aec8,0x8a8b7a88,0xc0c0c08a,0xbfc0c0c0,0xa6a7bfbf,0xc4cbcfa6,0xcc47a1b1,0xb6d207b0,0xc5c6909,0xf211c1de,0xbfdf09d1,0x38a7bc07,0x8a99a5aa,0xbfbf8888,0xc0c0c0bf,0xc0c0c0c0,0xbfbfc0c0,0xababacbf,0xc6bcbcbf,0xacb8acc1,0x49a6b76b,0xb847a7b9,0xafb663aa,0xa6a6a997,0xbfa1a1a3,0xc0c0bfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xadbbbbbb,0xaaacabab,0xaeaeb0aa,0xa8ababae,0xa9aaa6a6,0xbababaa9,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int delete_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xbfbfbfbf,0xc0c0bfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdbec0c0,0xbababbbd,0xb8b7b7b8,0xb6b8b6b6,0xb6b6b8b6,0xb8b6b6b8,0xb6b8b6b6,0xb6b6b8b6,0xb8b6b6b8,0xb6b8b6b6,0xb6b6b8b6,0xb8b6b6b8,0xb6b8b6b6,0xb6b6b8b6,0xb8b6b6b8,0xb6b8b6b6,0xb6b6b8b6,0xb8b6b6b8,0xb6b8b6b6,0xb7b7b8b6,0xbebababb,0xc0c0bdbd,0xc0c0c0c0,0xbdc0c0c0,0xa3a4bbbb,0x85858da3,0x82787883,0x77827777,0x77778277,0x82777782,0x77827777,0x77778277,0x82777782,0x77827777,0x77778277,0x82777782 +,0x77827777,0x77778277,0x82777782,0x77827777,0x77778277,0x82777782,0x77827777,0x78788377,0xa787878f,0xbbbda7a7,0xc0c0c0bb,0xb5bebebf,0x6988b3b3,0x3737b069,0xbb3434bb,0x34bb3434,0x3434bb34,0xbb3434bb,0x34bb3434,0x3434bb34,0xbb3434bb,0x34bb3434,0x3434bb34,0xbb3434bb,0x34bb3434,0x3434bb34,0xbb3434bb,0x34bb3434,0x3434bb34,0xbb3434bb,0x34bb3434,0x3535bb34,0x893939ac,0xb5b77676,0xbfbfbfb5,0xabbdbdbe,0x4894aaaa,0x2222dd48,0xdc2222de,0x22de2222,0x2222de22,0xdc2222dc,0x22de2222,0x2222dc22,0xdc2222de,0x22de2222,0x2222dc22,0xdc2222de,0x22de2222,0x2222dc22,0xde2222de,0x22dc2222,0x2222de22,0xde2222dc,0x22dc2222,0x2222de22,0x882323d9,0xaeaf5858,0xbebebfae,0xa7bdbdbe,0x4a96a7a7,0x1b1bd14a,0xce1818ce,0x18ce1818,0x1818ce18,0xce1818ce,0x18ce1818,0x1818ce18,0xce1818ce,0x18ce1818,0x1818ce18,0xce1818ce,0x18ce1818,0x1818ce18,0xce1818ce,0x18ce1818,0x1818ce18,0xce1818ce,0x18ce1818,0x1818ce18,0x891d1dcf,0xabac5656,0xbdbdbeab,0xa7bdbdbe,0x4d98a7a7,0x2727e14d,0xe02525e1,0x25e12525,0x2525e125,0xe02525e0,0x25e12525,0x2525e025,0xe02525e1,0x25e12525,0x2525e025,0xe02525e1,0x25e12525,0x2525e025,0xe12525e1,0x25e02525 +,0x2525e125,0xe12525e0,0x25e02525,0x2525e125,0x8b2929df,0xacad5858,0xbdbdbeac,0xabbdbdbe,0x4d95aaaa,0x3838e34d,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0xe43a3ae4,0x3ae43a3a,0x3a3ae43a,0x893737e0,0xafb15c5c,0xbebebfaf,0xb6bfbfbf,0x7288b4b4,0x42429e72,0xa63f3fa6,0x3ea63e3e,0x3e3ea63e,0xa63e3ea6,0x3ea63e3e,0x3e3ea63e,0xa63e3ea6,0x3ea63e3e,0x3e3ea63e,0xa63e3ea6,0x3ea63e3e,0x3e3ea63e,0xa63e3ea6,0x3ea63e3e,0x3e3ea63e,0xa63e3ea6,0x3ea63e3e,0x3f3fa63e,0x8b43439b,0xb6b87d7d,0xbfbfbfb6,0xbdc0c0c0,0xa9aabbbb,0x939397a9,0x8c88888d,0x878c8888,0x87878c87,0x8c87878c,0x878c8787,0x87878c87,0x8c87878c,0x878c8787,0x87878c87,0x8c87878c,0x878c8787,0x87878c87,0x8c87878c,0x878c8787,0x87878c87,0x8c87878c,0x888c8787,0x89898e88,0xad969698,0xbcbeacac,0xc0c0c0bc,0xc0c0c0c0,0xbebfc0c0,0xbbbbbdbe,0xbabababb,0xb9bab9b9,0xb9b9bbb9,0xbbb9b9bb,0xb9bbb9b9,0xb9b9bbb9,0xbbb9b9bb,0xb9bbb9b9,0xb9b9bbb9,0xbbb9b9bb,0xb9bbb9b9,0xb9b9bbb9,0xbbb9b9bb,0xb9bbb9b9,0xb9b9bbb9,0xbab9b9bb,0xb9bab9b9,0xbababbb9 +,0xbfbcbcbd,0xc0c0bebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 +,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int delete2_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdc0c0c0,0xbababdbd,0xbabababa,0xbabababa,0xbabababa,0xbabababa,0xbabababa,0xbabababa,0xbabababa,0xbbbababa,0xbdbdbbbb,0xc0c0c0bd,0x8abababa,0x518b6f6f,0x51518b51,0x8b51518b,0x518b5151,0x51518b51,0x8b51518b,0x518b5151,0x51518b51,0x8b51518b,0x748b5252,0xbcbcbc74,0xb0b3b3b3,0x1ed73333,0x1e1ed71e,0xd71e1ed7,0x1ed71e1e,0x1e1ed71e,0xd71e1ed7,0x1ed71e1e,0x1e1ed71e,0xd71e1ed7,0x3aa31e1e,0xb5b5b53a,0xb5b3b3b3,0x30e43c3c,0x3030e430,0xe43030e4,0x30e43030 +,0x3030e430,0xe43030e4,0x30e43030,0x3030e430,0xe43030e4,0x42a83030,0xb5b5b542,0x8bbbbbbb,0x5e867979,0x5e5e865e,0x865e5e86,0x5e865e5e,0x5e5e865e,0x865e5e86,0x5e865e5e,0x5e5e865e,0x865e5e86,0x7d8d5e5e,0xbcbcbc7d,0xbec0c0c0,0xbcbdbebe,0xbcbcbcbc,0xbcbcbcbc,0xbcbcbcbc,0xbcbcbcbc,0xbcbcbcbc,0xbcbcbcbc,0xbcbcbcbc,0xbdbcbcbc,0xbebebcbc,0xc0c0c0be,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; static unsigned int editcopy_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0x94a09f9f,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0xba9a9a9a,0xc0c0bbba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9b6b5c0,0xa1d2a094,0xa89fd6aa,0xd3a59ed5,0x9ad2a29c,0x9d98d0a0,0xcd9a95cf,0x8fcc9693,0x8f8dcb93,0xc78c8ac9,0x84c58887,0x8181c485,0xc17c7dc2,0xb2826566,0xc0c0b4b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbab6b5c0,0xecefc7be,0xfde9fefe,0xfdfbe5fd,0xdefdf9e2,0xf6dbfdf7,0xfdf3d7fe,0xd0fdf1d4,0xedccfdf0,0xfdebc8fe,0xbffde9c3,0xe5bbfde7,0xfecfb2fd,0xb28a6667,0xc0c0b3b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbb8b7c0,0xeff0c8c0,0xfdecfefe,0xfdfde9fd,0xe2fdfae5,0xf8defdf9,0xfdf6dbfe,0xd4fdf3d7,0xf0d0fdf1,0xfdedccfe,0xc3fdebc8,0xe7bffde9,0xfed0b5fd,0xb28c6868,0xc0c0b4b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcb8b7c0,0xf2f1cac0,0xfeeffefe,0xfde5dbfe,0xcffbd9d2,0xd5ccfad7,0xf5d2c8f8,0xc2f3d0c5,0xcbbff1cd,0xedc9bbef,0xc8efcebc,0xeac3feec,0xfed2b8fe,0xb28e6a69,0xc0c0b4b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcb8b7c0,0xf5f2cbc1,0xfdf2fefe,0xfdfdeffd,0xe9fdfdec,0xfbe5fdfd,0xfdf9e2fe,0xdbfdf7de,0xf3d7fdf6,0xfdf1d4fe,0xccfdefd0,0xebc8fded,0xfed4bbfd,0xb28f6b6a,0xc0c0b4b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcb9b7c0,0xf8f3ccc2,0xfdf5fefe,0xfde4defd,0xd1fbd9d4,0xd6cff9d8,0xf5d4cbf7,0xc5f3d1c8,0xcdc2f1cf,0xedcabfef,0xd0efd0c0,0xedccfdef,0xfed5befd,0xb2906c6b,0xc0c0b5b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbbb8b6c0,0xfaf4cdc3,0xfdf7fefe,0xfdfdf5fd,0xeffdfdf1,0xfeecfdfd,0xfdfde9fe,0xe2fdfbe5,0xf8defdf9,0xfdf6dbfe,0xd4fdf3d7,0xefd0fdf1,0xfed6c0fd,0xb2926e6c,0xc0c0b5b2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9b6b5c0 ,0xfdf5cec4,0xfdfafefe,0xfde4e2fd,0xd4fbd9d7,0xd7d2f9d8,0xf5d5cef7,0xc8f3d3cc,0xcec5f0d0,0xedccc2ef,0xd7efd2c4,0xf1d4fdf3,0xfed8c3fd,0xb294706d,0xc0c0b5b2,0xc0c0c0c0,0xc0c0c0c0,0xbebec0c0,0xa09f9fbf,0x94949494,0x94949494,0x94949494,0x94949494,0x94949494,0x93919094,0xfef6d0c5,0xfefdfefe,0xfefefafe,0xf5fefef8,0xfef2fefe,0xfefeeffe,0xe9fefeec,0xfbe6fefd,0xfef9e2fe,0xdbfef8de,0xf3d7fef6,0xfed9c6fe,0xb295716e,0xc0c0b5b2,0xc0c0c0c0,0xc0c0c0c0,0xb6b5c0c0,0xd2a094b9,0x9fd6aaa1,0xa59ed5a8,0xd2a29cd3,0x98d0a09a,0x9a95cf9d,0xd09e98cd,0xfef8d2c7,0xfefefefe,0xfde5e6fe,0xd7fcdada,0xd7d5fad8,0xf5d5d1f8,0xcbf3d3ce,0xd0c8f1d1,0xedcec5ef,0xdeefd4c9,0xf6dbfdf7,0xfedac8fd,0xb296736f,0xc0c0b5b3,0xc0c0c0c0,0xc0c0c0c0,0xb6b5c0c0,0xefc7beba,0xe9fefeec,0xfbe5fdfd,0xfdf9e2fd,0xdbfdf7de,0xf3d7fef6,0xfceed1fd,0xfef9d3c8,0xfefefefe,0xfefefefe,0xfbfefefd,0xfef8fefe,0xfefdf5fe,0xeffdfdf1,0xfeecfdfd,0xfdfde9fe,0xe2fdfae5,0xf7defdf9,0xfedccbfd,0xb2987470,0xc0c0b5b3,0xc0c0c0c0,0xc0c0c0c0,0xb8b7c0c0,0xf0c8c0bb,0xecfefeef,0xfde9fdfd,0xfdfae5fd,0xdefdf9e2,0xf6dbfef8,0xfcefd4fd,0xfefad4c8,0xfefefefe,0xfde5e6fe,0xdafcdadb @@ -619,6 +639,8 @@ ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf8a1b0be,0xffff77bb,0x9affffc6,0xff9affff,0xffff9aff,0x9affff9a,0xff9affff,0xffff9fff,0xe3ffffd0,0xffe3ffff,0xffffe3ff,0xe3ffffe3,0xffe3ffff,0xffffe3ff,0xe3ffffe3,0xffe3ffff,0xffffe3ff,0xe3ffffe3,0xebdefcfe,0x9c9d3797,0xc0c0c09a,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf8a1b0be,0xffff77bb,0xb6ffffd6,0xffb6ffff,0xffffb6ff,0xb6ffffb6,0xffb6ffff,0xbbf8e5ff,0x3898ee76,0xee3a98ee,0x98ee3a98,0x3a98ee3a,0xee3a98ee,0x98ee3a98,0x3a98ee3a,0xee3a98ee,0x98ee3a98,0x3a98ee3a,0xae3696ed,0xbbbc6a8e,0xc0c0c0b9,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf89fb0be,0xffff77bb,0xd9ffffe9,0xffd9ffff,0xffffd9ff,0xd9ffffd9,0xfdd9ffff,0x84d0e2f3,0xa5a7a931,0xbfbebebf,0xbfbfbebf,0xbebfbfbe,0xbfbebfbf,0xbfbfbebf,0xbebfbfbe,0xbfbebfbf,0xbfbfbebf,0xbebfbfbe,0xbfbebebf,0xc0c0bfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf5adb7c1,0xd5fb46a2,0xadd6fbab,0xfbadd6fb,0xd6fbadd6,0xadd6fbad,0xf9add6fb,0x83b98bc5,0xb5b7b947,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc6c0c0c0 ,0xa0c19db3,0x7ea1c17d,0xc17fa2c1,0xa2c17fa2,0x7fa2c17f,0xbc7ea1c1,0xb4b8809f,0xc0c0c0af,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int fileopen2_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xfb84b4df,0xc2fc6ac7,0x25c1fc27,0xfc23c0fc,0xbefc22bf,0x1ebefc20,0xfc1cbdfc,0xbbfc1abc,0x17bafc18,0xb31ab2fa,0xc0c0849d,0xc0c0c0c0,0xfa94c0e6,0xd9ff89ca,0x39d7ff3d,0xff37d6ff,0xd4ff35d5,0x31d3ff33,0xff2fd2ff,0xd0ff2dd1,0x29cfff2b,0xbe2bc9fc,0xc0c04a8f,0xc0c0c0c0,0xfa9bc3e6,0xe9fe6fc1,0x4ee2ff7b,0xff4ce1ff,0xdfff4ae0,0x47deff49,0xff45ddff,0xdbff43dc,0x3fdaff41,0xde42d5fc,0xc0c042ab,0xc0c0c0c0,0xfc9bc3e6,0xe1fd43be,0x5feaff94,0xff5ee9ff,0xe8ff5ce9,0x5ae7ff5b,0xff58e7ff,0xe5ff57e6,0x53e4ff55,0xda56dffc,0x9db361c6,0xc0c0c084,0xfe9bc3e6,0xc8fa3fcc,0x76efff7f,0xff71efff,0xeeff6fee,0x6beeff6d,0xff69eeff,0xedff67ee,0x65edff66,0xd667e7fc,0x96c078d4,0xc0c0c055,0xff9bc3e6,0xbafa56d9,0xc5f7fe46,0xffb7f6ff,0xf6ffb5f6,0xa3f5ffb3,0xff8df3ff,0xf3ff8af3,0x84f3ff87,0xd681ebfc,0xb8e08cd6,0xc0c0c063,0xff9bc3e6,0xd7fd70e6,0x41c0fa46,0xfa43c1fa,0xc1fa43c1 +,0x75c4fa43,0xffcff9fe,0xf9ffc9f9,0xc5f9ffc7,0xe3c1f3fd,0xdce6c4e3,0x87a0b6b5,0xff9bc3e6,0xf0ff8af3,0x69f0ff69,0xff69f0ff,0xf0ff69f0,0x60e2fd69,0xfa57c9fa,0xcafa59ca,0x59cafa59,0xd149b4f5,0xc6e690b2,0xc0c0c0a4,0xff9bc3e6,0xfdffa7fe,0x8efdff8e,0xff90fdff,0xfdffaefd,0xb3fdffb3,0xffb3fdff,0xfdffb3fd,0xb3fdffb3,0xc073cbf5,0xc0c0c0c0,0xc0c0c0c0,0xff9ac3e7,0xffffd4ff,0xc8ffffc8,0xd1d5fcfe,0xc0c06ea2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xe6c0c0c0,0xc1e698c0,0x99c1e699,0xc091bde4,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; static unsigned int fileopenmesh_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0xbabbbfbf,0xb6b8b9b9,0xb9b6b8b9,0xb8b9b6b8,0xb6b8b9b6,0xb9b6b8b9,0xb8b9b6b8,0xb6b8b9b6,0xb9b6b8b9,0xb8b9b6b8,0xb6b8b9b6,0xb9b6b8b9,0xb8b9b6b8,0xb6b8b9b6,0xb9b6b8b9,0xb8b9b6b8,0xb6b8b9b6,0xb9b6b7b9,0xbebeb8b9,0xc0c0c0bd,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x9fbebfbf,0x7ca18e97,0x4c78a052,0xa04b78a0,0x78a04b78,0x4b78a04b,0xa04b78a0,0x78a04b78,0x4b78a04b,0xa04b78a0,0x78a04b78,0x4b78a04b,0xa04b78a0,0x78a04b78,0x4b78a04b,0xa04b78a0,0x78a04b78,0x4b78a04b,0x904c78a0,0x8e8e5675,0xbcbcbd8d,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf0aab2b9,0xc1f92a91,0x30b4f683,0xda3da4db,0xa3da3da3 ,0x3ba3da3c,0xda3aa3da,0xa2da3aa2,0x39a1da3a,0xda39a1da,0xa0da38a1,0x36a0da37,0xda35a0da,0x9fda359f,0x339eda34,0xda329eda,0x9dda329e,0x319dda31,0xe4309dda,0x75a02d97,0xa9aaab45,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xf59bacbb,0xc5f93198,0x88cfdf8c,0xbf5eaebf,0xadbf5dae,0x5bacbf5b,0xbf59acbf,0xabbf58ab,0x56aabf57,0xbf55aabf,0xa9bf54a9,0x52a8bf52,0xbf51a8bf,0xa6bf4fa7,0x4da6bf4f,0xbf4ca5bf,0xa4bf4ba5,0x49a4bf4a,0xc248a3bf,0x8bde45a2,0x8b8c8c2c,0xc0bebfbf,0xc0c0c0c0,0xc0c0c0c0,0xf79daebe,0xa3f664b2,0xcbe5e946,0xd26ab4bf,0xc6e25abf,0x4cc6e24d,0xe24bc5e2,0xc4e24ac5,0x48c4e248,0xe246c3e2,0xafbf45c2,0x5dafc15f,0xe242c1e2,0xc0e241c0,0x3fbfe240,0xe23ebfe2,0xbee23cbe,0x3abde23c,0xbf4db0c9,0x99e653a9,0x65758431,0xc0b9babb,0xc0c0c0c0,0xc0c0c0c0,0xf89fafbe,0xaef777bb,0xcde6fa5c,0xe27abcc1,0xdaff58cc,0x3edaff3f,0xff3dd9ff,0xd9ff3cd9,0x3ad8ff3b,0xff3ad8ff,0xb5bf39d7,0x68b7c26b,0xff36d6ff,0xd4ff35d5,0x33d4ff33,0xff32d3ff,0xd2ff30d3,0x2ed2ff30,0xbf52bad2,0xa6da5faf,0x4277a73d,0xc0a9aaab,0xc0c0c0c0,0xc0c0c0c0,0xf8a0b0be,0xc8fb77bb,0x8cc5f97d,0xe2aad4d5,0xdfff63d1,0x48dfff49,0xff48deff,0xdeff47de,0x45ddff46 ,0xff44ddff,0xbabf43dc,0x73bcc275,0xff40dbff,0xdaff3fda,0x3ddaff3e,0xff3dd9ff,0xd8ff3cd9,0x3ad8ff3b,0xbf5ec0d2,0xb7d06bb5,0x2c8bdf51,0xbf8b8c8c,0xc0c0bebf,0xc0c0c0c0,0xf8a1b0be,0xd4fe77bb,0x43a1f672,0xe2d7ebea,0xe4ff6cd6,0x53e4ff53,0xff52e3ff,0xe2ff51e3,0x4fe2ff50,0xff4ee2ff,0xbfbf4de1,0x7dc1c27f,0xff4be0ff,0xdfff4adf,0x48dfff48,0xff47deff,0xddff46de,0x44ddff45,0xbf68c6d2,0xc0ce75ba,0x35a0eb5c,0xbb657584,0xc0c0b9ba,0xc0c0c0c0,0xf8a1b0be,0xd8ff77bb,0x1d9df76f,0xe6cbe5fa,0xe9ff7bde,0x5be8ff5c,0xff5ae8ff,0xe7ff5ae7,0x58e7ff59,0xff57e6ff,0xc4bf57e6,0x87c6c289,0xff54e5ff,0xe4ff54e4,0x52e3ff53,0xff51e3ff,0xe2ff50e2,0x4ee2ff4f,0xbf73cad2,0xc4ce80bf,0x4ab3e067,0xab4277a7,0xc0c0a9aa,0xc0c0c0c0,0xf8a1b0be,0xd8ff77bb,0x279bde6f,0xf887c3f9,0xecffa2ef,0x62ebff63,0xff61ebff,0xebff61eb,0x60eaff60,0xff5feaff,0xc8bf5fea,0x8fcac291,0xff5ce9ff,0xe8ff5ce9,0x5be8ff5b,0xff5ae8ff,0xe7ff59e7,0x58e6ff58,0xbf7ccfd2,0xc9ce89c4,0x66c8d671,0x8c2d8bdf,0xbfbf8b8c,0xc0c0c0be,0xf8a1b0be,0xd9ff77bb,0x5c7e9070,0xfe439df1,0xeeffd1f9,0x69eeff6b,0xff68eeff,0xeeff68ee,0x66edff67,0xff66edff,0xcbbf65ed,0x96cdc297,0xff64ecff @@ -3047,6 +3069,10 @@ ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xa9c0c0c0,0xd45aacc0,0x6ae74e6d,0x4667e74a,0xe64263e6,0x5de53e60,0x365ae53b,0xe43256e4,0x4fe32e53,0x264be32a,0xe12248e2,0x41d52245,0x89579d4b,0xca298da8,0x37c01844,0x1935ba18,0x6c5537c0,0xb4b6b456,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfafc0c0,0x77c669b1,0x4a6be551,0xe64667e7,0x60e64264,0x3b5de53e,0xe4365ae5,0x53e43256,0x3151e330,0xae494fdb,0x90a58d59,0xc0bbbeba,0xb886c0c0,0x3dcb1e8d,0x1e37bf18,0x827934a3,0xbcbdbc79,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcc0bcc0,0x649bbc95,0xda5272c6,0x64e04a69,0x4363e246,0xda435fe0,0x5dc9485d,0x9772a869,0xbeba9bb2,0xc0c0c0ba,0xc0c0c0c0,0xbfbfc0c0,0x6dbe5fbf,0x2e3bcc1b,0x9d9a3b88,0xc0c0c09a,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfc0c0c0,0xc0b4bfc0,0xaabaa7b6,0xa3a6b9a3,0xbbada6b9,0xbcbfbcaf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9beb7c0,0x5d55c341,0xb8b56182,0xc0c0c0b5,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb5b1baaf,0xc0c0b5ba,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int remove_png[] = {0xc0c0c0c0,0xbfc0c0c0,0xbebebfbf,0xc0bfbfc0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0xc0bebebf,0xc0c0bfbf,0xc0c0c0c0,0xbec0c0c0,0x9699bcbc,0x6b6b8996,0xbe98989c,0xc0c0bdbd,0xc0c0c0c0,0xc0c0c0c0,0xbcbec0c0,0x96969abc,0x9c6b6b89,0xbdbe9898,0xc0c0c0bd,0x9abfbfc0,0x4ecc9696,0x6767ef4e,0x934e4ec3,0xbcbe8d8d,0xc0c0c0bc,0xbec0c0c0,0x8a91bcbc,0x4e4ec78a,0xc56767ef,0x9ea24e4e,0xc0c0c09e,0x8cbebebf,0x58ee6d6d,0x5959ee58,0xc45858ee,0x8d934747,0xbcbcbf8d,0x92bcbcbf,0x47ca8989,0x5858ee47,0xed5959ee,0x768d5656,0xbfbfc076,0xa2c0c0c0,0x45c19e9e,0x4545ec45,0xec4545ec,0x3fc84545,0x8888903f,0xcd85858f,0x45ec3f3f,0x4545ec45,0xbd4545ec,0xa3a64545,0xc0c0c0a3,0xbfc0c0c0,0x9499bdbd,0x3d3dc394,0xea2e2eea,0x2eea2e2e,0x3232cc2e,0xea3131cf,0x2eea2e2e,0x2e2eea2e,0x9b3e3ec0,0xbdbf9696,0xc0c0c0bd,0xc0c0c0c0,0xbdbfc0c0,0x949499bd,0xe83535c4,0x19e81919,0x1919e819,0xe81919e8,0x19e81919,0x3a3ac019,0xbf96969b,0xc0c0bdbd,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbdbdbfc0,0xc8909096,0x18e83232,0x1818e818,0xe81818e8,0x38c31818,0x93939738,0xc0bdbdbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcbcbfc0,0xd1878791,0x2ae93c3c +,0x2a2ae92a,0xe92a2ae9,0x41cb2a2a,0x8d8d9341,0xc0bcbcbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbcbec0c0,0x8b8b94bc,0xeb4949d3,0x40eb4040,0x4040eb40,0xeb4040eb,0x40ec4040,0x4c4ccb40,0xbe8f8f95,0xc0c0bcbc,0xc0c0c0c0,0xbec0c0c0,0x8a93bcbc,0x4b4bd38a,0xed4d4ded,0x4ded4d4d,0x4949c34d,0xed4949c4,0x4dee4d4d,0x4d4ded4d,0x964e4ecc,0xbdbe8f8f,0xc0c0c0bd,0x9bbfbfc0,0x4fcf9696,0x5959ee4f,0xee5959ee,0x4bbd5959,0x9393984b,0xc1919196,0x59ee4c4c,0x5959ee59,0xcb5959ee,0x9da24d4d,0xc0c0c09d,0x8cbebebf,0x64ef6d6d,0x6565ef64,0xb86464ef,0x979b4c4c,0xbebebf97,0x98bebebf,0x4cbc9393,0x6464ef4c,0xee6565ef,0x768d6161,0xbfbfc076,0xa0bfbfc0,0x4fc09c9c,0x6969ee4f,0x9a4d4db3,0xbebf9797,0xc0c0c0be,0xbfc0c0c0,0x9498bebe,0x4f4fb694,0xb66868ee,0xa3a64e4e,0xc0c0c0a3,0xbec0c0c0,0xa0a3bdbd,0x77778aa0,0xbfa3a3a5,0xc0c0bebe,0xc0c0c0c0,0xc0c0c0c0,0xbebfc0c0,0xa1a1a4be,0xa779798a,0xbebfa4a4,0xc0c0c0be,0xc0c0c0c0,0xc0c0c0c0,0xbfbfc0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0bfbfc0,0xc0c0c0c0,0xc0c0c0c0}; +static unsigned int remove2_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x53d1c0c0,0x6767ef53,0xc05454c9,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x5454cdc0,0xcc6767ef,0xc0c05454,0xc0c0c0c0,0xc0c0c0c0,0x58eec0c0,0x5959ee58,0xcb5858ee,0xc0c04d4d,0xc0c0c0c0,0xc0c0c0c0,0x4ccfc0c0,0x5858ee4c,0xed5959ee,0xc0c05656,0xc0c0c0c0,0xc0c0c0c0,0x4ec9c0c0,0x4545ec4e,0xec4545ec,0x46cf4545,0xc0c0c046,0xd2c0c0c0,0x45ec4545,0x4545ec45,0xc74545ec,0xc0c04e4e,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x4545cbc0,0xea2d2dea,0x2dea2d2d,0x3737d12d,0xea3535d4,0x2dea2d2d,0x2d2dea2d,0xc04747c9,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xe83d3dcd,0x18e81818,0x1818e818,0xe81818e8,0x18e81818,0x4343c918,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xcfc0c0c0,0x17e83939,0x1717e817,0xe81717e8,0x40cb1717,0xc0c0c040,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xd6c0c0c0,0x29e94141 +,0x2929e929,0xe92929e9,0x47d12929,0xc0c0c047,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xeb4f4fd9,0x3feb3f3f,0x3f3feb3f,0xeb3f3feb,0x3fec3f3f,0x5353d23f,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x5151d8c0,0xed4d4ded,0x4ded4d4d,0x5151cc4d,0xed5050cc,0x4dee4d4d,0x4d4ded4d,0xc05454d2,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x55d5c0c0,0x5959ee55,0xee5959ee,0x54c75959,0xc0c0c054,0xc9c0c0c0,0x59ee5454,0x5959ee59,0xd25959ee,0xc0c05454,0xc0c0c0c0,0xc0c0c0c0,0x64efc0c0,0x6565ef64,0xc26464ef,0xc0c05555,0xc0c0c0c0,0xc0c0c0c0,0x54c4c0c0,0x6464ef54,0xee6565ef,0xc0c06161,0xc0c0c0c0,0xc0c0c0c0,0x56c7c0c0,0x6969ee56,0xc05757bd,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x5858bec0,0xbf6868ee,0xc0c05858,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0}; static unsigned int script_check_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb7bcbbbb,0xb7b7b8b7,0xb8b7b7b8,0xb7b8b7b7,0xb7b7b8b7,0xb8b7b7b8,0xb7b8b7b7,0xb7b7b8b7,0xb8b7b7b8,0xb7b8b7b7,0xb7b7b8b7,0xb8b7b7b8,0xb7b8b7b7,0xb7b7b8b7,0xb8b7b7b8,0xb7b8b7b7,0xb7b7b7b7,0xbababab7,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0x6591786f,0x6d64896f,0x886c6388,0x62866b62,0x6862856a,0x83676184,0x5f826660,0x645f8165,0x7e625e7f,0x5d7e625e,0x5f5d7c60,0x7a5e5c7b,0x5a795d5b,0x5a59785c,0x75595976,0x58755959,0x57577357,0x827d7e72,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xcfdea293,0xd5cff9d4,0xf9d4cef9,0xcbf8d3cc,0xcfc9f8d1,0xf7cec6f8,0xc3f7ccc5,0xc7c0f6ca,0xf5c5bef6,0xb8f5c2bb,0xbdb5f5c0,0xf4bbb3f4,0xacf4b8b0,0xb2aaf3b5,0xf3afa6f3,0xa0f2aca3,0x7779f2aa,0x7a6f6fca,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xe9e2a99a,0xffecfff5,0xfffeeaff,0xe5fffce7,0xfae3fffb,0xfff9e0ff,0xdbfff8de,0xf4d8fff6,0xfff3d6ff,0xd1fff2d3,0xeecdfff0,0xffedcbff,0xc4ffecc8,0xe9c1ffeb,0xffe7beff,0xb8ffe6bb,0x7f82ffe4,0x7a7070d4,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xebe4aa9b,0xffeefff5 ,0xffffecff,0xe7fffeea,0xfbe5fffc,0xfffae3ff,0xdefff9e0,0xf6dbfff8,0xfff4d8ff,0xd3fff3d6,0xf0d1fff2,0xffeecdff,0xc8ffedcb,0xebc4ffec,0xffe9c1ff,0xbbffe7be,0x8182ffe6,0x7a7070d5,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xece5ac9c,0xfff1fff5,0xffffeeff,0xdffefae9,0xecddfeed,0xfdeadbfd,0xd6fce9d9,0xe6d4fbe8,0xfae5d1fb,0xccf9e3ce,0xe0c9f8e1,0xf7dec7f8,0xc2f7dcc4,0xecc8f6db,0xffebc4ff,0xbeffe9c1,0x8283ffe7,0x7b7070d6,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xeee7ad9d,0xfff3fff5,0xfffff1ff,0xd6fef6e8,0xddd4fdde,0xfbdbd2fc,0xc2fad9d0,0xadb0e7c7,0xe1c1b7cb,0xc4f3d2c6,0xcfc2f2d1,0xf0cdbff1,0xbbefccbd,0xedcbeeca,0xffecc8ff,0xc1ffebc4,0x8384ffe9,0x7c7170d7,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xf0e8af9e,0xfff4fff5,0xfffff3ff,0xeefffff1,0xffecffff,0xfefeeaff,0xf8d0cee4,0x2ffd2f2f,0x6f6cd02f,0xdbece6ce,0xf4d8fff6,0xfff3d6ff,0xd1fff2d3,0xeecdfff0,0xffedcbff,0xc4ffecc8,0x8484ffeb,0x7c7170d9,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xf1e9b19f,0xfff7fff5,0xfffff4ff,0xd8fef6ec,0xddd6fdde,0xdbc5d6fc ,0xfe2323f9,0x1efe0c0c,0x3030fc1e,0xc4a694b1,0xd0c4efd0,0xf0cec1f1,0xbdefcdc0,0xf0d1eecb,0xffeecdff,0xc8ffedcb,0x8585ffec,0x7c7271da,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbebec0,0xf2ebb2a0,0xfff9fff5,0xfffff7ff,0xe6fefaf1,0xd1defeee,0x332df3e1,0xfd0000fd,0xcfe0202,0x1e1efe0c,0xbb4843e0,0xe4d2dccb,0xf7e3cff8,0xcbf7e1cd,0xf2d3f6e0,0xfff0d1ff,0xcbffeecd,0x8686ffed,0x7d7271db,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbec0,0xf4ecb4a0,0xfffbfff5,0xfffff9ff,0xeffefef7,0x42f8dbdb,0xc0cfe42,0xfd0303fd,0x2fd0000,0xc0cfe02,0xc51e1efe,0xf1da8e8b,0xfff8def7,0xd8fff6db,0xf3d6fff4,0xfff2d3ff,0xcdfff0d1,0x8787ffee,0x7d7272dd,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbec0,0xf5edb6a1,0xfffdfff5,0xfefefbff,0xfadad5ef,0x2afe5251,0x1a1afe2a,0xfd0c0cfe,0xfd0303,0x202fd00,0xf00c0cfe,0x9da12d2b,0xe8bcb8c0,0xb4e7bbb6,0xf4d8e6b9,0xfff3d6ff,0xd1fff2d3,0x8988fff0,0x7e7372de,0xc0bebebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbec0,0xf6efb8a2,0xfffefff5,0xe5e5fbff,0xfe6363fc,0x3cfe4747,0x2a2afe3c,0xfb1a1afe,0x8fd2929,0xfd08,0xfe0202fd @@ -3111,6 +3137,14 @@ ,0xeaffffff,0xa0aeaea,0x505050a,0x9030303,0xebeb0909,0xffffffeb,0x89fbfaf9,0x8470c792,0xcb816ccc,0x64ca7e68,0x7760c87a,0xc5745cc6,0x57c4725a,0x6354c46f,0xcab4b2b4,0x68dfcbc9,0x6f57c179,0xc47159c3,0x5fc5745c,0x7963c676,0xc97d67c7,0x6eca806a,0x5e56cb83,0xe3e1e1a1,0xeaffffff,0xa0aeaea,0x505050a,0x9030303,0xebeb0909,0xffffffeb,0x7bf7f3f2,0x8671c487,0xcb836ecd,0x67ca806a,0x7a64ca7d,0xc77860c8,0x52c5755d,0xb0aeb261,0xf9f7f7c5,0xcdfdfcfc,0x7767e2d0,0xc5755dbe,0x63c67760,0x7c66c779,0xca7f69c9,0x71cb826d,0x5d52cd85,0xd3cecdab,0xeaffffff,0xa0aeaea,0x505050a,0x9030303,0xebeb0909,0xffffffeb,0x71efe7e7,0x8873c480,0xcd8671ce,0x6bcb836e,0x7e68ca80,0xc97b65ca,0x52c26a56,0xb6b59659,0xf7f7f7c2,0xd8fefefe,0x766fe3d9,0xc3705bac,0x67c87b65,0x7f69ca7d,0xcb826dca,0x73cc8470,0x6457ce87,0xbeb3b3b6,0xeaffffff,0xa0aeaea,0x505050a,0x9030303,0xebeb0909,0xffffffeb,0x6fe4d6d4,0x8a76c880,0xce8873cf,0x6fcd8571,0x816ccb83,0xca7f69cb,0x4ec97d67,0x6560b95e,0xd6d0d095,0x89f2edec,0x6857b78e,0xc97d66bc,0x6bca7e68,0x826eca80,0xcc8571cb,0x75cd8772,0x6f60ce89,0xac9796c3,0xeaffffff,0xb0beaea,0x505050b,0x9030303 ,0xebeb0909,0xffffffeb,0x77d8bebb,0x8c79ce88,0xcf8a76d0,0x72ce8874,0x8470cd86,0xcb816dcc,0x63c87b67,0x6259c376,0xd6cbcab2,0x72f2e9e9,0x7966c17c,0xc97c68c5,0x6fcb816d,0x8571cc84,0xce8873cd,0x79cf8a75,0x7f6ed08c,0xa17c79cc,0xeaffffff,0xb0beaea,0x404040b,0x9030303,0xebeb0909,0xffffffeb,0x7cd5afaa,0x8776d18d,0xc78070ce,0x7cc37f71,0x938bc588,0xcda49fc8,0xd4d7bcb9,0xeeeee4d5,0xfdfdfdf3,0xf2fefefe,0xdddbf8f3,0xddc4c1ea,0x92d4ada7,0x8e82cd9b,0xc78677c9,0x77c98272,0x8978cf89,0xa16d69cf,0xeaffffff,0xb0beaea,0x404040b,0x9030303,0xebeb0909,0xffffffeb,0xadeedcdb,0xbebbd7b2,0xe4d5d4d9,0xf4efe8e7,0xfafaf8f4,0xfefdfdfc,0xfffefefe,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xfefefeff,0xfbfefdfd,0xf5f5fcfb,0xf3ebeaf9,0xc2e9dbda,0xb4afdec5,0xdcc5c3d8,0xeaffffff,0xb0beaea,0x404040b,0x9020202,0xebeb0909,0xffffffeb,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xffffffff,0xeaffffff,0xb0beaea,0x303030b,0x8020202,0xd4d40808,0xe8e8e8d4,0xe8e8e8e8,0xe8e8e8e8 ,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xe8e8e8e8,0xd4e8e8e8,0x909d4d4,0x3030309,0x60606,0x6060000,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x6060606,0x606,0x7070700,0x7474747,0x3030707,0x3030303,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x4040404,0x3030303,0x6060303,0x4c4c4c06}; +static unsigned int together_png[] = {0xf032208,0x4e11044a,0x64e1205,0x12074f12,0x4f13074f,0x74f1307,0x13074f13,0x4f13074f,0x64d1107,0xb044c10,0x42d,0x0,0x0,0x32d0000,0x3035603,0x59040459,0x6590505,0x6065a06,0x5a060659,0x6590606,0x6065a06,0x59060659,0x4560505,0x4042f04,0x2a03450e,0xa6551887,0x44a65544,0x5645a756,0xa75745a7,0x47a75746,0x5847a758,0xa85947a7,0x49a75948,0x14248e36,0x759,0x0,0x0,0x35c0000,0x1d1e9a03,0xb44446b4,0x47b44447,0x4647b445,0xb44648b4,0x48b44748,0x4949b448,0xb4494ab4,0x209a4a4a,0x5055e20,0x4d04470f,0xf0823ca1,0x5cef7d63,0x8160f080,0xf28563f0,0x6af38867,0x8c6ef289,0xf49071f2,0x7af59374,0x1657b568,0x95c,0x0,0x0,0x55f0000,0x484cb905,0xfe6676fe,0x76fd6473,0x6c78fe69,0xfe707afd,0x7efd737c,0x7c81fe78,0xfe7f82fd,0x52b98789,0x7076152,0x4d054810,0xed793ba0,0x4dec7157,0x7652ed74,0xee7a55ee,0x5cef7c59,0x8160f07f,0xf28463f1,0x6ef38967,0x1855b366,0xa5d,0x0,0x0,0x65f0000,0x474bb805,0xfd596cfd,0x6afd5567,0x5d6cfd59,0xfd616ffd,0x73fd6571,0x6d75fd6a,0xfd7278fd,0x51b97a7f,0x8096250,0x4c064910,0xec743aa0,0x47ea6c51,0x714aec6f,0xee744eec +,0x54ef7651,0x7c58ee79,0xf17f5bef,0x66f28360,0x1854b465,0xb5e,0x0,0x0,0x7600000,0x454ab906,0xff5067ff,0x65fd4c62,0x5467ff51,0xff5869fd,0x6efd5c6b,0x6470ff60,0xff6873fd,0x50b9717a,0x909634e,0x4b054910,0xea7039a0,0x41e9684c,0x6d45ea6a,0xeb6f48eb,0x4eed724c,0x7752ed75,0xef7a55ee,0x60f07f59,0x1852b364,0xb5e,0x0,0x0,0x7600000,0x4449b806,0xfd4b63fd,0x61fd465f,0x4d63fd4a,0xfd5165fd,0x6afd5567,0x5d6cfd59,0xfd616efd,0x4fb96b76,0x909634d,0x4b054910,0xea6d39a0,0x3be86347,0x673fea65,0xeb6a41e9,0x48eb6c44,0x724beb6f,0xee744eec,0x59ee7a52,0x1850b362,0xa5e,0x0,0x0,0x7600000,0x4349b906,0xff4460ff,0x5cfd3f5a,0x455eff43,0xff4960fd,0x64fd4c62,0x5466ff51,0xff5869fd,0x4eb96271,0x809634b,0x4b054910,0xe86a38a0,0x37e76043,0x643ae862,0xea663ce8,0x42eb6840,0x6d46ea6b,0xec7048eb,0x53ed764c,0x184fb361,0xa5e,0x0,0x0,0x7600000,0x4248b906,0xff3f5dff,0x59fd3a57,0x3f5bff3d,0xff435dfd,0x61fd465f,0x4d63ff4a,0xff5165fd,0x4db95b6d,0x8096349,0x4a054810,0xe666379f,0x32e55c3e,0x6034e65e,0xe76237e6,0x3ce86339,0x683fe966,0xea6b42e9,0x4ceb7045 +,0x174db160,0x95e,0x0,0x0,0x6600000,0x4148b805,0xfd3a5afd,0x56fd3454,0x3957fd37,0xfd3c58fd,0x5cfd3f5a,0x455efd42,0xfd4960fd,0x4cb95368,0x7086248,0x4a04470e,0xe86f379f,0x40e7674a,0x6a42e769,0xe86c44e7,0x48e96d46,0x714be96f,0xea744dea,0x55eb7850,0x164cb15f,0x85c,0x0,0x0,0x55f0000,0x4148b805,0xfd4362fd,0x5efd3e5d,0x415ffd3f,0xfd4460fd,0x64fd4662,0x4b65fd49,0xfd4f67fd,0x4bb9566d,0x6076146,0x2603450e,0x9d451384,0x339c4533,0x46339d46,0x9d46339c,0x349d4734,0x46349c46,0x9d47349c,0x359c4735,0x131b892d,0x657,0x0,0x0,0x35c0000,0x191b9903,0xb2393eb2,0x3eb0393e,0x393eb239,0xb23a3eb0,0x3eb03a3e,0x3a3fb23a,0xb23b3fb0,0x1c9a3b40,0x4055e1b,0xe05230b,0x450f0442,0x5451004,0x11064510,0x57210743,0x18582317,0x11084211,0x46100745,0x5450f06,0xa04430f,0x427,0x0,0x0,0x32c0000,0x4045303,0x56040555,0x7560506,0x7085306,0x66141564,0x8521515,0x7075508,0x56060756,0x4530505,0x3042d04,0x0,0x0,0x0,0x0,0x332a0000,0x2b352d29,0x0,0x0,0x0,0x0,0x0,0x0,0x0 +,0x0,0x0,0x0,0x0,0x0,0x37292934,0x2b2b,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2f2c0000,0x2e312e2b,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x322b2b2f,0x2e2e,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2d2d0000,0x4040402d,0x34343434,0x35353434,0x34343435,0x34353535,0x35353434,0x34343435,0x34353535,0x35353434,0x34343435,0x35353535,0x34343535,0x35353534,0x2f3f3f3f,0x2f2f,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x14140000,0x27272714,0x29292929,0x29292929,0x29292929,0x29292929,0x29292929,0x3a3a3a29,0x293b3b3b,0x29292929,0x29292929,0x29292929,0x29292929,0x29292929,0x15272727,0x1515,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2020000,0x2b2b2b02,0x22e2e2e,0x302,0x0,0x0,0x0 +,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2020000,0x2b2b2b03,0x22d2d2d,0x302,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2020000,0x2d2a2a03,0x22f2c2c,0x402,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2020000,0x32282604,0x2352928,0x402,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x9030000,0x67100531,0x86a1206,0x14086b14,0x6b14086b,0x86b1508,0x150a6a15,0x731c1167,0xa751d11,0x16096615,0x6b150969,0x96b1609,0x15086b16,0x6a14076b,0x5661105,0x320a,0x0 +,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xe040000,0xa3301e58,0x4bc2614a,0x624cc261,0xc2624cc3,0x4ec3634e,0x6450c263,0xc26550c3,0x52c36551,0x6753c266,0xc26754c3,0x56c36855,0x6956c369,0xc36a57c2,0x6a33322,0x5910,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xf040000,0xb7513d5b,0x4cfd8a53,0x8850fd85,0xfd8a54fd,0x5cfd8d58,0x9360fd8f,0xfd9563fd,0x6bfd9868,0x9e70fd9a,0xfda074fd,0x7bfda278,0xa77ffda5,0xfdae88fd,0x7b75846,0x5c11,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x10050000,0xb8513c5b,0x43fd854b,0x8347fd7f,0xfd844aff,0x52ff884e,0x8d56fd89,0xfd8f5aff,0x62ff935f,0x9867fd94,0xfd9a6bff,0x73ff9e6f,0xa277ffa0,0xfeab82fd,0x8b75846,0x5c13,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x10050000,0xb7503b5b,0x3efd8247,0x7f41fd7d,0xfd8045fd,0x4cfd8348,0x8850fd85,0xfd8a54fd,0x5cfd8d58,0x9361fd90,0xfd9564fd,0x6dfd9969,0x9e71fd9b,0xfda67dfd,0x8b75745,0x5d13,0x0,0x0,0x0,0x0,0x0 +,0x0,0x0,0x0,0x10060000,0xb8503b5b,0x3afd7f44,0x7d3dfd7a,0xfd7f40ff,0x48ff8144,0x864cfd82,0xfd874fff,0x57ff8b54,0x915cfd8d,0xfd9260ff,0x68ff9664,0x9b6dff99,0xfea479fd,0x8b75744,0x5d13,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x10050000,0xb7503a5b,0x36fd7e3f,0x7939fd77,0xfd7b3bfd,0x42fd7d3f,0x8146fd7f,0xfd8349fd,0x51fd864e,0x8c56fd88,0xfd8e59fd,0x62fd915e,0x9766fd94,0xfd9f72fd,0x8b75643,0x5d13,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x10060000,0xb84f3a5b,0x33fd7c3d,0x7736fd76,0xfd7938ff,0x3eff7b3b,0x8042fd7d,0xfd8145ff,0x4dff8449,0x8951fd86,0xfd8b55ff,0x5dff8f59,0x9461ff92,0xfe9d6efd,0x8b75543,0x5d13,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x10050000,0xb74f3a5b,0x30fd7b3b,0x7532fd73,0xfd7634fd,0x39fd7837,0x7c3dfd7a,0xfd7e40fd,0x47fd8044,0x854bfd82,0xfd874efd,0x57fd8a53,0x8f5bfd8c,0xfd9868fd,0x8b75542,0x5c13,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xf040000 +,0xb84f3a5b,0x37fd7f41,0x7939fd79,0xfd7b3afe,0x3ffe7c3d,0x8042fd7e,0xfd8045fe,0x4bfe8448,0x884ffd85,0xfd8952fe,0x5afe8d56,0x915efe8f,0xfe9a69fd,0x7b75441,0x5c11,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0xe040000,0xa12c1958,0x3fbc563f,0x563fbc56,0xbc563fbd,0x40bd5740,0x5741bc57,0xbc5741bd,0x42bd5842,0x5943bc58,0xbc5944bd,0x45bd5a44,0x5b46bd5a,0xbd5b47bc,0x5a12d1b,0x590f,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x9040000,0x6010052d,0x7631105,0x14086413,0x64130765,0x7651408,0x14086413,0x64130865,0x8651408,0x14086414,0x64140865,0x8651408,0x14086514,0x63130764,0x5601006,0x2e0a,0x0,0x0,0x0,0x0}; static unsigned int undo_png[] = {0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0 ,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbfbfbfc0,0xbdbebebe,0xbdbdbebd,0xbebdbdbe,0xbdbebdbd,0xbdbdbebd,0xbebdbdbe,0xbdbebdbd,0xbdbdbebd,0xbebdbdbe,0xbdbebdbd,0xbebebebd,0xbfbfbfbe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xbabac0c0,0x9f9a99bc,0x888f8989,0x88888d88,0x8d88888d,0x888d8888,0x88888d88,0x8d88888d ,0x888d8888,0x88888d88,0x8d88888d,0x888d8888,0x8c8c8d88,0xa9a7a791,0xc0bfbebe,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x9186c0c0,0x96452fae,0x25953e26,0x3c24953d,0x933b2395,0x21933a22,0x391f9239,0x8f381f91,0x1e8e371e,0x361e8d36,0x8a361e8b,0x1e8a351e,0x392e8a35,0x98939372,0xc0bfbfbf,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0x9d8ec0c0,0xfa6f3dc9,0x2efd6934,0x622afd65,0xfd5d23fd,0xefd5519,0x4604fd4e,0xf84200fd,0xf24000,0x3e00ed3e,0xe93d00e9,0x2eb3d00,0x5e56e23b,0xb8b6b583,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xaea8c0c0,0xf27147c2,0x33fe6d39,0x652dfe69,0xfe6129fe,0x17fe5c22,0x4c0cfe54,0xfd4503fe,0xf84100,0x3e00f140,0xe83d00eb,0x35ea3d00,0xa9a78f47,0xc0c0c0ae,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xc0c0c0c0,0xb9b9c0c0,0xb8b8b7b9,0xc0c0c0c0,0xbcbac0c0,0xdf7757c0,0x39fe713e,0x6933fe6d,0xfe642dfe,0x22fe6129,0x5417fe5c,0xfe4c0cfe,0xfd4502,0x3f00f841,0xef3f00f1,0x95af3e1c @@ -3339,6 +3373,8 @@ {3,32,32,"close.png",close_png}, {3,32,32,"comline.png",comline_png}, {3,32,32,"contract.png",contract_png}, +{3,32,32,"create.png",create_png}, +{3,16,16,"create2.png",create2_png}, {3,32,32,"cycle.png",cycle_png}, {3,32,32,"data.png",data_png}, {3,32,32,"dataexp.png",dataexp_png}, @@ -3348,6 +3384,8 @@ {3,32,32,"debug_linestep.png",debug_linestep_png}, {3,32,32,"debug_setbrpnt.png",debug_setbrpnt_png}, {3,16,16,"delay.png",delay_png}, +{3,32,32,"delete.png",delete_png}, +{3,16,16,"delete2.png",delete2_png}, {3,32,32,"editcopy.png",editcopy_png}, {3,32,32,"editcut.png",editcut_png}, {3,32,32,"editpaste.png",editpaste_png}, @@ -3355,6 +3393,7 @@ {3,32,32,"expand.png",expand_png}, {3,32,32,"filenew.png",filenew_png}, {3,32,32,"fileopen.png",fileopen_png}, +{3,16,16,"fileopen2.png",fileopen2_png}, {3,32,32,"fileopenmesh.png",fileopenmesh_png}, {3,32,32,"fileopenpart.png",fileopenpart_png}, {3,32,32,"fileopentens.png",fileopentens_png}, @@ -3409,6 +3448,8 @@ {3,16,16,"ready.png",ready_png}, {3,32,32,"recorder.png",recorder_png}, {3,32,32,"redo.png",redo_png}, +{3,16,16,"remove.png",remove_png}, +{3,16,16,"remove2.png",remove2_png}, {3,32,32,"script_check.png",script_check_png}, {3,32,32,"script_run.png",script_run_png}, {3,32,32,"scted.png",scted_png}, @@ -3417,6 +3458,7 @@ {3,32,32,"singleline.png",singleline_png}, {3,32,32,"surf.png",surf_png}, {3,32,32,"tens.png",tens_png}, +{3,32,32,"together.png",together_png}, {3,32,32,"undo.png",undo_png}, {3,32,32,"vect.png",vect_png}, {3,32,32,"view.png",view_png}, @@ -3429,5 +3471,5 @@ {3,32,32,"wins.png",wins_png}, {3,32,32,"xsec.png",xsec_png}}; const bool isBigEndianData = false; -const int num = 113; +const int num = 121; #endif diff -Nru ifrit-3.3.4/help/iimagefactorydata1.h.stub ifrit-3.4.2/help/iimagefactorydata1.h.stub --- ifrit-3.3.4/help/iimagefactorydata1.h.stub 2011-01-27 17:50:37.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata1.h.stub 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -//LICENSE A -#include "../Work/help/iimagefactorydataempty.h" diff -Nru ifrit-3.3.4/help/iimagefactorydata2.cpp ifrit-3.4.2/help/iimagefactorydata2.cpp --- ifrit-3.3.4/help/iimagefactorydata2.cpp 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata2.cpp 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -26,6 +26,7 @@ =========================================================================*/ +#include "iconsole.h" #include "iimagefactory.h" #include "istring.h" @@ -45,6 +46,7 @@ if(num == 0) { CreateData("Work/docs/images","Code/help/iimagefactorydata2.h","az"); + iConsole::Display(iConsole::_Warning,"IFrIT is creating compressed help data...\nPlease compile again and re-run."); exit(0); } diff -Nru ifrit-3.3.4/help/iimagefactorydata2.h ifrit-3.4.2/help/iimagefactorydata2.h --- ifrit-3.3.4/help/iimagefactorydata2.h 2011-01-27 17:52:01.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata2.h 2013-07-11 01:23:45.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -25,7 +25,7 @@ =========================================================================*/ #if 0 -#include "iimagefactorydataempty.h" +#include "../../Work/help/iimagefactorydataempty.h" #else static unsigned int art_png[] = {0x0,0x0,0x0,0x0,0x0,0x7e7c7b,0x25fcece0,0x36fce4d1,0xfbddc6,0xa69f9a,0xf0f0f,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x7e7d7c,0x8fcebdf,0xb0fac59d,0x76f4bb9a,0x5f6cbb3,0xccc0b8,0x272727,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x171717,0xddd5ce,0x1dfadcc9,0xe6e57946,0xa2ec9c74,0xcf5cdb7,0xe4d6ce,0x272727,0x0,0x0,0x0,0x0,0x0,0x0,0x2b2b2b,0x535252,0x7f7d7b,0xb6b3b0,0xfbe7da,0x72f8cbb0,0xfed03b05,0xb3ea976e,0xbf5cab4,0xccc0b8,0xb0b0b,0x0,0x0,0x0,0x3b3b3a,0xc1bab4,0xfae1d2,0xefae3d5,0x3efad7c0,0x51fad0b2,0x51fad0b2,0x5cfbddc9,0xf7de612c,0xfecd3300,0x9ceda17a,0x3f5cab3,0xa29e9a,0x0,0x0,0x575655,0xfae6d9,0x2af8d6c2,0xa2eea682,0xecdd622f,0xfdd2400a,0xffcf3702,0xffcf3601,0xffd23e08,0xffcf3803,0xffcd3300,0xfdd03c07,0x5ff4c0a3,0xf1d5c4,0x232323,0x0,0xf0e5de,0x40f7d1bb,0xecdc602d,0xffcd3300,0xffcd3300 ,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xd7e17243,0x9f6ccb5,0x7b7977,0x0,0xffceee6,0xd6e78c64,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xfed13c06,0x28f7d0b9,0x7e7b78,0x0,0xefdf3ec,0xebe17649,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xfdd3430e,0x25f7d3be,0x7e7b79,0x0,0xfbeadf,0x98f5c5aa,0xffcf3703,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3401,0xb3eda37e,0x4f7d2be,0x7b7978,0x0,0xd2cecb,0x10f9decf,0xcaec9d77,0xfecd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xffcd3300,0xf9d74f1a,0xa2f0ad8a,0x13f5cdb9,0xf4e5dc,0x1f1f1f,0x0,0x272727,0xf1e7e0,0x1cf8d8c7,0xccec9a72,0xffce3602,0xffd23f08,0xdbeb956a,0xd0eb976f,0xbbefa987,0x80f4bc9d,0x33f8d8c5,0x2f7d2bd,0xe8ddd5,0x434343,0x0,0x0,0x0,0x3b3b3b,0xf0e5de,0x13f8dccc,0xa3f3bb9d,0xfcd64b16,0xa5ec9365,0x6f5c5a9,0xafadfce diff -Nru ifrit-3.3.4/help/iimagefactorydata2.h.stub ifrit-3.4.2/help/iimagefactorydata2.h.stub --- ifrit-3.3.4/help/iimagefactorydata2.h.stub 2011-01-27 17:50:41.000000000 +0000 +++ ifrit-3.4.2/help/iimagefactorydata2.h.stub 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -//LICENSE A -#include "../Work/help/iimagefactorydataempty.h" diff -Nru ifrit-3.3.4/shells/base/.#ibgframesubject.h.1.1.1.1 ifrit-3.4.2/shells/base/.#ibgframesubject.h.1.1.1.1 --- ifrit-3.3.4/shells/base/.#ibgframesubject.h.1.1.1.1 2011-01-27 17:50:42.000000000 +0000 +++ ifrit-3.4.2/shells/base/.#ibgframesubject.h.1.1.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,105 +0,0 @@ -//LICENSE A - -// -// A base class for toolkit-dependent frame implementor -// - -#ifndef IBGFRAMESUBJECT_H -#define IBGFRAMESUBJECT_H - - -#include "ibgwidgetsubject.h" - - -class iImage; -class iString; - -class iggFrame; -class iggFrameBook; -class iggFrameFlip; -class iggFrameScroll; - - -class ibgFrameSubject : public ibgWidgetSubject -{ - - friend class ibgShell; - friend class ibgWindowHelper; - -public: - - inline iggFrame* GetFrame() const { return mFrameOwner; } - - virtual void SetTitle(const iString &title) = 0; - virtual void ShowFrame(bool s) = 0; - - virtual void SetPadding(bool s) = 0; - virtual void SetColStretch(int col, int s) = 0; - virtual void SetRowStretch(int row, int s) = 0; - virtual void PlaceWidget(int col, int row, ibgWidgetSubject *child, int nc, bool expand) = 0; - - virtual void GetFrameGeometry(int wg[4]) const = 0; - - inline static int GetPaddingWidth(){ return mPaddingWidth; } - -protected: - - ibgFrameSubject(iggFrame *owner, int cols); - - iggFrame *mFrameOwner; - static int mPaddingWidth; -}; - - -class ibgFrameBookSubject : public ibgWidgetSubject -{ - -public: - - virtual void OpenPage(int i) = 0; - virtual void AddPage(const iString &title, const iImage *image, iggFrame *frame) = 0; - virtual void SetTabMode(int n, int m, const iString &title, const iImage *image) = 0; - virtual int GetTabMode() = 0; - virtual void ChangeIcon(int n, const iImage &image) = 0; - virtual void Flip() = 0; - -protected: - - ibgFrameBookSubject(iggFrameBook *owner, int flags); -}; - - -class ibgFrameFlipSubject : public ibgWidgetSubject -{ - -public: - - inline int Count() const { return mCount; } - - virtual void ShowLayer(int i) = 0; - void AddLayer(iggFrame *layer); - -protected: - - ibgFrameFlipSubject(iggFrameFlip *owner, bool expanding); - - virtual void AddLayerBody(iggFrame *layer) = 0; - - int mCount; -}; - - -class ibgFrameScrollSubject : public ibgWidgetSubject -{ - -public: - - virtual void AttachContents(iggFrame *contents) = 0; - -protected: - - ibgFrameScrollSubject(iggFrameScroll *owner, bool withHor); -}; - -#endif // IBGFRAMESUBJECT_H - diff -Nru ifrit-3.3.4/shells/base/ibgdialogsubject.cpp ifrit-3.4.2/shells/base/ibgdialogsubject.cpp --- ifrit-3.3.4/shells/base/ibgdialogsubject.cpp 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgdialogsubject.cpp 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgdialogsubject.h ifrit-3.4.2/shells/base/ibgdialogsubject.h --- ifrit-3.3.4/shells/base/ibgdialogsubject.h 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgdialogsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgelement.cpp ifrit-3.4.2/shells/base/ibgelement.cpp --- ifrit-3.3.4/shells/base/ibgelement.cpp 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgelement.cpp 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgelement.h ifrit-3.4.2/shells/base/ibgelement.h --- ifrit-3.3.4/shells/base/ibgelement.h 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgelement.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgextensionwindowsubject.cpp ifrit-3.4.2/shells/base/ibgextensionwindowsubject.cpp --- ifrit-3.3.4/shells/base/ibgextensionwindowsubject.cpp 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgextensionwindowsubject.cpp 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgextensionwindowsubject.h ifrit-3.4.2/shells/base/ibgextensionwindowsubject.h --- ifrit-3.3.4/shells/base/ibgextensionwindowsubject.h 2011-01-27 17:52:03.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgextensionwindowsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgframesubject.cpp ifrit-3.4.2/shells/base/ibgframesubject.cpp --- ifrit-3.3.4/shells/base/ibgframesubject.cpp 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgframesubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -50,6 +50,16 @@ } +bool ibgFrameSubject::BeforeShow() +{ + if(mFrameOwner != 0) + { + if(mFrameOwner->NeedsRedoLayout()) return true; + } + return false; +} + + // // FrameBook class // diff -Nru ifrit-3.3.4/shells/base/ibgframesubject.h ifrit-3.4.2/shells/base/ibgframesubject.h --- ifrit-3.3.4/shells/base/ibgframesubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgframesubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -71,6 +71,8 @@ ibgFrameSubject(iggFrame *owner, int cols); + virtual bool BeforeShow(); + iggFrame *mFrameOwner; static int mPaddingWidth; }; diff -Nru ifrit-3.3.4/shells/base/ibgmainwindowsubject.cpp ifrit-3.4.2/shells/base/ibgmainwindowsubject.cpp --- ifrit-3.3.4/shells/base/ibgmainwindowsubject.cpp 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgmainwindowsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgmainwindowsubject.h ifrit-3.4.2/shells/base/ibgmainwindowsubject.h --- ifrit-3.3.4/shells/base/ibgmainwindowsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgmainwindowsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgmenuwindowsubject.cpp ifrit-3.4.2/shells/base/ibgmenuwindowsubject.cpp --- ifrit-3.3.4/shells/base/ibgmenuwindowsubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgmenuwindowsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgmenuwindowsubject.h ifrit-3.4.2/shells/base/ibgmenuwindowsubject.h --- ifrit-3.3.4/shells/base/ibgmenuwindowsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgmenuwindowsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgrenderwindowsubject.cpp ifrit-3.4.2/shells/base/ibgrenderwindowsubject.cpp --- ifrit-3.3.4/shells/base/ibgrenderwindowsubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgrenderwindowsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgrenderwindowsubject.h ifrit-3.4.2/shells/base/ibgrenderwindowsubject.h --- ifrit-3.3.4/shells/base/ibgrenderwindowsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgrenderwindowsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -62,13 +62,15 @@ virtual void SetFullScreen(bool) = 0; virtual void MakeCurrent() = 0; - virtual void* GetDisplayId() const = 0; + virtual void* GetDisplay() const = 0; + virtual void* GetContext() const = 0; virtual void* GetWindowId() const = 0; virtual void SetWindowName(const iString &s) = 0; virtual void RenderIntoMemory(iImage &) = 0; virtual bool IsReadyForDumpingImage() = 0; + virtual bool IsDirect() const = 0; virtual bool IsCurrent() const = 0; virtual void RequestStereo(bool s) = 0; diff -Nru ifrit-3.3.4/shells/base/ibgshellsubject.cpp ifrit-3.4.2/shells/base/ibgshellsubject.cpp --- ifrit-3.3.4/shells/base/ibgshellsubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgshellsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgshellsubject.h ifrit-3.4.2/shells/base/ibgshellsubject.h --- ifrit-3.3.4/shells/base/ibgshellsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgshellsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetareasubject.cpp ifrit-3.4.2/shells/base/ibgwidgetareasubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetareasubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetareasubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetareasubject.h ifrit-3.4.2/shells/base/ibgwidgetareasubject.h --- ifrit-3.3.4/shells/base/ibgwidgetareasubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetareasubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetbuttonsubject.cpp ifrit-3.4.2/shells/base/ibgwidgetbuttonsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetbuttonsubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetbuttonsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetbuttonsubject.h ifrit-3.4.2/shells/base/ibgwidgetbuttonsubject.h --- ifrit-3.3.4/shells/base/ibgwidgetbuttonsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetbuttonsubject.h 2013-07-11 01:23:46.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetcolorselectionsubject.cpp ifrit-3.4.2/shells/base/ibgwidgetcolorselectionsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetcolorselectionsubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetcolorselectionsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -33,7 +33,7 @@ #include "ibgwidgetcolorselectionsubject.h" -ibgWidgetColorSelectionSubject::ibgWidgetColorSelectionSubject(iggWidget *owner, bool /*horizontal*/) : ibgWidgetSubject(owner) +ibgWidgetColorSelectionSubject::ibgWidgetColorSelectionSubject(iggWidget *owner) : ibgWidgetSubject(owner) { } diff -Nru ifrit-3.3.4/shells/base/ibgwidgetcolorselectionsubject.h ifrit-3.4.2/shells/base/ibgwidgetcolorselectionsubject.h --- ifrit-3.3.4/shells/base/ibgwidgetcolorselectionsubject.h 2011-01-27 17:52:04.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetcolorselectionsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -53,7 +53,7 @@ protected: - ibgWidgetColorSelectionSubject(iggWidget *owner, bool horizontal); + ibgWidgetColorSelectionSubject(iggWidget *owner); }; #endif // IBGWIDGETKEYCOLORSELECTIONSUBJECT_H diff -Nru ifrit-3.3.4/shells/base/ibgwidgetentrysubject.cpp ifrit-3.4.2/shells/base/ibgwidgetentrysubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetentrysubject.cpp 2011-01-27 17:52:07.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetentrysubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -36,12 +36,10 @@ #include "iggwidgetrendermodebutton.h" -ibgWidgetEntrySubject::ibgWidgetEntrySubject(iggWidget *owner, bool /*slider*/, int numdig, const iString& /*label*/, iggWidgetRenderModeButton *rmb) : ibgWidgetSubject(owner) +ibgWidgetEntrySubject::ibgWidgetEntrySubject(iggWidget *owner, bool /*slider*/, int numdig, const iString& /*label*/) : ibgWidgetSubject(owner) { mNumDigitsFrozen = false; mNumDigits = numdig; - - if(rmb != 0) rmb->ClearLaidOutFlag(this); } diff -Nru ifrit-3.3.4/shells/base/ibgwidgetentrysubject.h ifrit-3.4.2/shells/base/ibgwidgetentrysubject.h --- ifrit-3.3.4/shells/base/ibgwidgetentrysubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetentrysubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -40,7 +40,7 @@ class iString; class iggWidget; -class iggWidgetRenderModeButton; +class ibgWidgetButtonSubject; class ibgWidgetEntrySubject : public ibgWidgetSubject @@ -48,12 +48,13 @@ public: - ibgWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb); + ibgWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label); virtual ~ibgWidgetEntrySubject(); virtual void FreezeNumberOfDigits(bool s); void IncrementNumDigits(int n){ if(mNumDigits>0 && mNumDigits+n>0) mNumDigits += n; } + virtual void AddButton(ibgWidgetButtonSubject* button) = 0; virtual void SetEditable(bool s) = 0; virtual void SetDelayedEdit(bool s) = 0; @@ -72,6 +73,8 @@ virtual void SetText(const iString &text) = 0; virtual void SelectText(int start, int len = -1) = 0; + virtual void ShowTail() = 0; + virtual void SetStretch(int label, int slider, int number = 0) = 0; protected: diff -Nru ifrit-3.3.4/shells/base/ibgwidgethelpbrowsersubject.cpp ifrit-3.4.2/shells/base/ibgwidgethelpbrowsersubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgethelpbrowsersubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgethelpbrowsersubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgethelpbrowsersubject.h ifrit-3.4.2/shells/base/ibgwidgethelpbrowsersubject.h --- ifrit-3.3.4/shells/base/ibgwidgethelpbrowsersubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgethelpbrowsersubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgethelper.cpp ifrit-3.4.2/shells/base/ibgwidgethelper.cpp --- ifrit-3.3.4/shells/base/ibgwidgethelper.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgethelper.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgethelper.h ifrit-3.4.2/shells/base/ibgwidgethelper.h --- ifrit-3.3.4/shells/base/ibgwidgethelper.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgethelper.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetprogressbarsubject.cpp ifrit-3.4.2/shells/base/ibgwidgetprogressbarsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetprogressbarsubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetprogressbarsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetprogressbarsubject.h ifrit-3.4.2/shells/base/ibgwidgetprogressbarsubject.h --- ifrit-3.3.4/shells/base/ibgwidgetprogressbarsubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetprogressbarsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetselectionboxsubject.cpp ifrit-3.4.2/shells/base/ibgwidgetselectionboxsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetselectionboxsubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetselectionboxsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetselectionboxsubject.h ifrit-3.4.2/shells/base/ibgwidgetselectionboxsubject.h --- ifrit-3.3.4/shells/base/ibgwidgetselectionboxsubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetselectionboxsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetsubject.cpp ifrit-3.4.2/shells/base/ibgwidgetsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgetsubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgetsubject.h ifrit-3.4.2/shells/base/ibgwidgetsubject.h --- ifrit-3.3.4/shells/base/ibgwidgetsubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgetsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgettexteditorsubject.cpp ifrit-3.4.2/shells/base/ibgwidgettexteditorsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgettexteditorsubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgettexteditorsubject.cpp 2013-07-11 01:23:48.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgettexteditorsubject.h ifrit-3.4.2/shells/base/ibgwidgettexteditorsubject.h --- ifrit-3.3.4/shells/base/ibgwidgettexteditorsubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgettexteditorsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwidgettrackballsubject.cpp ifrit-3.4.2/shells/base/ibgwidgettrackballsubject.cpp --- ifrit-3.3.4/shells/base/ibgwidgettrackballsubject.cpp 2011-01-27 17:52:08.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgettrackballsubject.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -64,7 +64,7 @@ // // Constructs a iTrackball. // -ibgWidgetTrackBallSubject::ibgWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb) : ibgWidgetSubject(owner), mFixedSize(64), mEarth(EarthData(256,128,GetData())) +ibgWidgetTrackBallSubject::ibgWidgetTrackBallSubject(iggWidget *owner, bool followCamera) : ibgWidgetSubject(owner), mFixedSize(64), mEarth(EarthData(256,128,GetData())) { mOldX = mOldY = mOldRad = 0; mFollowCamera = followCamera; @@ -79,8 +79,6 @@ mLightDirection[0] = 0.0; mLightDirection[1] = 0.0; mLightDirection[2] = sqrt(1.0-vtkMath::Dot2D(mLightDirection,mLightDirection)); - - if(rmb != 0) rmb->ClearLaidOutFlag(this); } diff -Nru ifrit-3.3.4/shells/base/ibgwidgettrackballsubject.h ifrit-3.4.2/shells/base/ibgwidgettrackballsubject.h --- ifrit-3.3.4/shells/base/ibgwidgettrackballsubject.h 2011-01-27 17:52:05.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwidgettrackballsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -38,7 +38,7 @@ class iColor; class iTransform; -class iggWidgetRenderModeButton; +class ibgWidgetButtonSubject; class ibgWidgetTrackBallSubject : public ibgWidgetSubject @@ -55,8 +55,9 @@ protected: - ibgWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb); + ibgWidgetTrackBallSubject(iggWidget *owner, bool followCamera); + virtual void AddButton(ibgWidgetButtonSubject* button) = 0; virtual void GetSizes(int &w0, int &h0, int &rad, int &cor) = 0; virtual void Repaint() = 0; diff -Nru ifrit-3.3.4/shells/base/ibgwindowhelper.cpp ifrit-3.4.2/shells/base/ibgwindowhelper.cpp --- ifrit-3.3.4/shells/base/ibgwindowhelper.cpp 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwindowhelper.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwindowhelper.h ifrit-3.4.2/shells/base/ibgwindowhelper.h --- ifrit-3.3.4/shells/base/ibgwindowhelper.h 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwindowhelper.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwindowsubject.cpp ifrit-3.4.2/shells/base/ibgwindowsubject.cpp --- ifrit-3.3.4/shells/base/ibgwindowsubject.cpp 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwindowsubject.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/base/ibgwindowsubject.h ifrit-3.4.2/shells/base/ibgwindowsubject.h --- ifrit-3.3.4/shells/base/ibgwindowsubject.h 2011-01-27 17:52:06.000000000 +0000 +++ ifrit-3.4.2/shells/base/ibgwindowsubject.h 2013-07-11 01:23:47.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/.#iclcommandinterpreter.cpp.1.3 ifrit-3.4.2/shells/cl/.#iclcommandinterpreter.cpp.1.3 --- ifrit-3.3.4/shells/cl/.#iclcommandinterpreter.cpp.1.3 2011-01-27 17:50:44.000000000 +0000 +++ ifrit-3.4.2/shells/cl/.#iclcommandinterpreter.cpp.1.3 1970-01-01 00:00:00.000000000 +0000 @@ -1,108 +0,0 @@ -//LICENSE A - - -#include "iconfigure.h" -#if ISHELL_INCLUDED(ISHELL_CL) - - -#include "iclcommandinterpreter.h" - - -#include "icontrolmodule.h" -#include "ishell.h" -#include "istring.h" - -#include - - -using namespace iParameter; - - -iclCommandInterpreter::iclCommandInterpreter(iShell *s) : iCommandInterpreter(s) -{ -} - - -iclCommandInterpreter::~iclCommandInterpreter() -{ -} - - -void iclCommandInterpreter::Initialize() -{ - this->DislayLineOfText("To execute entered commands, put a semi-colon at the end of the last one.",CommandInterpreterType::Result); - this->DisplayPrompt(); -} - - -void iclCommandInterpreter::Finalize() -{ -} - - -void iclCommandInterpreter::DisplayPrompt() const -{ - cout << endl; - cerr << ": "; -} - - -void iclCommandInterpreter::Exec() -{ - if(!mLine.IsEmpty()) - { - this->ExecLine(mLine); - mLine.Clear(); - this->DisplayPrompt(); - } -} - - -void iclCommandInterpreter::SetLine(const iString &line) -{ - mLine = line; -} - - -void iclCommandInterpreter::ReadLineOfText(iString &line) const -{ - line.Clear(); -} - - -void iclCommandInterpreter::DislayLineOfText(const iString &text, int) const -{ - cout << text.ToCharPointer() << endl; -} - - -void iclCommandInterpreter::AnalyseSpecialCommands(const iString &line) -{ - if(line.IsEmpty()) - { - // - // If the line is empty, render the visualization windows - // - this->GetShell()->GetControlModule()->Render(RenderOption::All); - return; - } - - // - // Are we done? - // - if(line=="exit" || line=="quit") - { - this->Break(1); - return; - } -} - - -void iclCommandInterpreter::CheckBreak() -{ - // - // Do nothing here, we check for break in AnalyseSpecialCommands - // -} - -#endif diff -Nru ifrit-3.3.4/shells/cl/.#iclshell.cpp.1.3 ifrit-3.4.2/shells/cl/.#iclshell.cpp.1.3 --- ifrit-3.3.4/shells/cl/.#iclshell.cpp.1.3 2011-01-27 17:50:44.000000000 +0000 +++ ifrit-3.4.2/shells/cl/.#iclshell.cpp.1.3 1970-01-01 00:00:00.000000000 +0000 @@ -1,291 +0,0 @@ -//LICENSE A - - -#include "iconfigure.h" -#if ISHELL_INCLUDED(ISHELL_CL) - - -#include "iclshell.h" - - -#include "icontrolmodule.h" -#include "ierror.h" -#include "iinteractoreventrecorder.h" -#include "ioutputchannel.h" -#include "iviewmodule.h" - -#include "iclcommandinterpreter.h" - -#include -#include -#include -#include -#include - - -#include - - -using namespace iParameter; - - -namespace iclShell_Private -{ - class OutputChannel : public iOutputChannel - { - - public: - - OutputChannel(iShell *s) : iOutputChannel(s) - { - } - - protected: - - virtual void DisplayBody(iConsole::MessageType type, const iString &message, const char *file, int line) - { - iString text = this->FormPlainTextMessage(type,message,file,line); - - switch(type) - { - case iConsole::_Info: - { - cout << text.ToCharPointer(); - break; - } - case iConsole::_Warning: - case iConsole::_LowError: - case iConsole::_HighError: - case iConsole::_FatalError: - { - cerr << text.ToCharPointer(); - break; - } - case iConsole::_Notification: - { - char c; - cout << text.ToCharPointer() << endl; - cout << "Proceed? (y/n)" << endl; - c = getchar(); - if(c != 'y') exit(0); - break; - } - } - } - }; - - class WindowObserver : public vtkCommand - { - - public: - - WindowObserver(iclCommandInterpreter *interpreter) - { - mInterpreter = interpreter; IERROR_ASSERT(mInterpreter); - mMutex = vtkCriticalSection::New(); IERROR_ASSERT(mMutex); - } - - ~WindowObserver() - { - mMutex->Delete(); - } - - virtual void Execute(vtkObject *caller, unsigned long event, void *data) - { - char c[2]; - c[1] = 0; - - int q = cin.eof(); - iConsole::PrintDebugMessage("="+iString::FromNumber(q)); - -// mMutex->Lock(); -// mInterpreter->Exec(); -// mMutex->Unlock(); - } - - private: - - iclCommandInterpreter *mInterpreter; - vtkCriticalSection *mMutex; - }; - - VTK_THREAD_RETURN_TYPE RunVM(void *data) - { - vtkMultiThreader::ThreadInfo *ti = static_cast(data); IERROR_ASSERT(ti); - iViewModule *vm = static_cast(ti->UserData); IERROR_ASSERT(vm); - - vm->GetInteractor()->Enable(); - vm->GetEventRecorder()->SetInteractor(0); // does not work with this shell - vm->GetInteractor()->Start(); - vm->GetInteractor()->Disable(); - - return 0; - } - - VTK_THREAD_RETURN_TYPE RunCI(void *data) - { - vtkMultiThreader::ThreadInfo *ti = static_cast(data); IERROR_ASSERT(ti); - iclCommandInterpreter *ci = static_cast(ti->UserData); IERROR_ASSERT(ci); - - ci->Exec(); - - return 0; - } - - VTK_THREAD_RETURN_TYPE RunLR(void *data) - { - iString line; - char c[2]; - c[1] = 0; - - vtkMultiThreader::ThreadInfo *ti = static_cast(data); IERROR_ASSERT(ti); - iclCommandInterpreter *ci = static_cast(ti->UserData); IERROR_ASSERT(ci); - - vtkCriticalSection *mutex = vtkCriticalSection::New(); - - while(ci->GetReturnState() == 0) - { - line.Clear(); - - while(((c[0]=getchar()) != EOF) && (c[0] != '\n')) - { - line += c; - } - - mutex->Lock(); - ci->SetLine(line); - mutex->Unlock(); - } - - mutex->Delete(); - return 0; - } -}; - - -using namespace iclShell_Private; - - -iclShell::iclShell(int argc, char **argv) : iShell("cl",argc,argv) -{ - mInterpreter = 0; // must be constructed when the shell is complete. - mContinue = false; -} - - -iclShell::~iclShell() -{ -} - - -void iclShell::DefineSpecificCommandLineOptions() -{ -} - - -void iclShell::PrepareForConstruction() -{ - cout << "IFrIT is being initialized...\r"; - cout.flush(); -} - - -void iclShell::ConstructorBody() -{ - mInterpreter = new iclCommandInterpreter(this); IERROR_ASSERT(mInterpreter); - iOutputChannel::SetInstance(new OutputChannel(this)); -} - - -void iclShell::DestructorBody() -{ - mInterpreter->Stop(); - mInterpreter->Delete(); -} - - -void iclShell::PrepareToLoadStateFile() -{ -} - - -void iclShell::Start() -{ - int i; - for(i=0; iGetControlModule()->GetNumberOfViewModules(); i++) - { - this->GetControlModule()->GetViewModule(i)->GetInteractor()->Disable(); - this->GetControlModule()->GetViewModule(i)->SetAntialiasing(true); - } - this->GetControlModule()->Render(RenderOption::All); // render all windows - mInterpreter->Start(); - - mContinue = true; -} - - -void iclShell::Exit() -{ - mContinue = false; -} - - -void iclShell::RunBody() -{ - // - // This is our event loop - // -// while(mContinue && mInterpreter->Exec()==0) - { - this->GetControlModule()->GetViewModule(0)->GetInteractor()->Enable(); - this->GetControlModule()->GetViewModule(0)->GetEventRecorder()->SetInteractor(0); // does not work with this shell - - this->GetControlModule()->GetViewModule(0)->GetInteractor()->AddObserver(vtkCommand::TimerEvent,new WindowObserver(mInterpreter)); - this->GetControlModule()->GetViewModule(0)->GetInteractor()->CreateRepeatingTimer(100); - - this->GetControlModule()->GetViewModule(0)->GetInteractor()->Start(); - this->GetControlModule()->GetViewModule(0)->GetInteractor()->Disable(); - } - -/* - vtkMultiThreader *t = vtkMultiThreader::New(); IERROR_ASSERT(t); - vtkMultiThreader::ThreadInfo ti; - - int tid = t->SpawnThread(RunCI,mInterpreter); - - ti.UserData = this->GetControlModule()->GetViewModule(); - RunVM(&ti); - - t->TerminateThread(tid); - t->Delete(); - */ -} - - -bool iclShell::AnalyseOneExtendedCommandLineOption(const struct Option&) -{ - return false; -} - - -// -// State saving -// -bool iclShell::LoadShellStateFromFileBody(iFile &) -{ - // - // Nothing to do here - // - return true; -} - - -bool iclShell::SaveShellStateToFileBody(iFile &) const -{ - // - // Nothing to do here - // - return true; -} - -#endif diff -Nru ifrit-3.3.4/shells/cl/iclcommandinterpreter.cpp ifrit-3.4.2/shells/cl/iclcommandinterpreter.cpp --- ifrit-3.3.4/shells/cl/iclcommandinterpreter.cpp 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcommandinterpreter.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclcommandinterpreter.h ifrit-3.4.2/shells/cl/iclcommandinterpreter.h --- ifrit-3.3.4/shells/cl/iclcommandinterpreter.h 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcommandinterpreter.h 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclcommoneventobservers.cpp ifrit-3.4.2/shells/cl/iclcommoneventobservers.cpp --- ifrit-3.3.4/shells/cl/iclcommoneventobservers.cpp 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcommoneventobservers.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclcommoneventobservers.h ifrit-3.4.2/shells/cl/iclcommoneventobservers.h --- ifrit-3.3.4/shells/cl/iclcommoneventobservers.h 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcommoneventobservers.h 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclcontrolscript.cpp ifrit-3.4.2/shells/cl/iclcontrolscript.cpp --- ifrit-3.3.4/shells/cl/iclcontrolscript.cpp 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcontrolscript.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclcontrolscript.h ifrit-3.4.2/shells/cl/iclcontrolscript.h --- ifrit-3.3.4/shells/cl/iclcontrolscript.h 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclcontrolscript.h 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclinputchannel.cpp ifrit-3.4.2/shells/cl/iclinputchannel.cpp --- ifrit-3.3.4/shells/cl/iclinputchannel.cpp 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclinputchannel.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclinputchannel.h ifrit-3.4.2/shells/cl/iclinputchannel.h --- ifrit-3.3.4/shells/cl/iclinputchannel.h 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclinputchannel.h 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclshell.cpp ifrit-3.4.2/shells/cl/iclshell.cpp --- ifrit-3.3.4/shells/cl/iclshell.cpp 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclshell.cpp 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/cl/iclshell.h ifrit-3.4.2/shells/cl/iclshell.h --- ifrit-3.3.4/shells/cl/iclshell.h 2011-01-27 17:52:09.000000000 +0000 +++ ifrit-3.4.2/shells/cl/iclshell.h 2013-07-11 01:23:49.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/configure/.#iggsubjectfactory.cpp.1.1.1.1 ifrit-3.4.2/shells/configure/.#iggsubjectfactory.cpp.1.1.1.1 --- ifrit-3.3.4/shells/configure/.#iggsubjectfactory.cpp.1.1.1.1 2011-01-27 17:50:44.000000000 +0000 +++ ifrit-3.4.2/shells/configure/.#iggsubjectfactory.cpp.1.1.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,723 +0,0 @@ -//LICENSE A - - -#include "iconfigure.h" - - -#include "icontrolmodule.h" -#include "ierror.h" -#include "ishell.h" -#include "istring.h" -#include "iviewmodule.h" - -#if defined(ISHELL) - -#include "iggsubjectfactory.h" - - -#include "iggdialog.h" -#include "iggextensionwindow.h" -#include "iggframe.h" -#include "iggmainwindow.h" -#include "iggrenderwindow.h" -#include "iggshell.h" -#include "iggwidgetarea.h" -#include "iggwidgettext.h" - -// -// Include Qt-specific headers -// -#if ISHELL_INCLUDED(ISHELL_QT) -#include "iqtdialogsubject.h" -#include "iqtextensionwindowsubject.h" -#include "iqtframesubject.h" -#include "iqtmainwindowsubject.h" -#include "iqtmenuwindowsubject.h" -#include "iqtrenderwindowsubject.h" -#include "iqtshellsubject.h" -#include "iqtwidgetareasubject.h" -#include "iqtwidgetbuttonsubject.h" -#include "iqtwidgetcolorselectionsubject.h" -#include "iqtwidgetentrysubject.h" -#include "iqtwidgethelpbrowsersubject.h" -#include "iqtwidgetprogressbarsubject.h" -#include "iqtwidgetselectionboxsubject.h" -#include "iqtwidgettexteditorsubject.h" -#include "iqtwidgettrackballsubject.h" -#endif - - -#if ISHELL_INCLUDED(ISHELL_FX) -#endif - - -const iString iggSubjectFactory::qt = "qt"; -const iString iggSubjectFactory::fx = "fx"; - -// -// Local macros for simplied creation -// -#define RETURN_SUBJECT0(_prefix_,_name_) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT1(_prefix_,_name_,arg1) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT2(_prefix_,_name_,arg1,arg2) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1,arg2); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT3(_prefix_,_name_,arg1,arg2,arg3) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1,arg2,arg3); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT4(_prefix_,_name_,arg1,arg2,arg3,arg4) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1,arg2,arg3,arg4); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT5(_prefix_,_name_,arg1,arg2,arg3,arg4,arg5) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1,arg2,arg3,arg4,arg5); \ - owner->AttachSubject(tmp); \ - return tmp - -#define RETURN_SUBJECT6(_prefix_,_name_,arg1,arg2,arg3,arg4,arg5,arg6) \ - i##_prefix_##_name_##Subject *tmp = new i##_prefix_##_name_##Subject(owner,arg1,arg2,arg3,arg4,arg5,arg6); \ - owner->AttachSubject(tmp); \ - return tmp - - -ibgDialogSubject* iggSubjectFactory::CreateDialogSubject(iggDialog *owner, const ibgWindowSubject *base, unsigned int mode, const iImage *icon, const iString &title) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT4(qt,Dialog,base,mode,icon,title); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT4(fx,Dialog,base,mode,icon,title); -#else - return 0; -#endif - } - - return 0; -} - - -ibgExtensionWindowSubject* iggSubjectFactory::CreateExtensionWindowSubject(iggExtensionWindow *owner) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - return new iqtExtensionWindowSubject(owner); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - return new ifxExtensionWindowSubject(owner); -#else - return 0; -#endif - } - - return 0; -} - - -ibgFrameSubject* iggSubjectFactory::CreateFrameSubject(iggFrame *owner, int cols) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,Frame,cols); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,Frame,cols); -#else - return 0; -#endif - } - - return 0; -} - - -ibgFrameBookSubject* iggSubjectFactory::CreateFrameBookSubject(iggFrameBook *owner, int flags) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,FrameBook,withFeedback,tabsOnTop); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,FrameBook,withFeedback,tabsOnTop); -#else - return 0; -#endif - } - - return 0; -} - - -ibgFrameFlipSubject* iggSubjectFactory::CreateFrameFlipSubject(iggFrameFlip *owner, bool expanding) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,FrameFlip,expanding); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,FrameFlip,expanding); -#else - return 0; -#endif - } - - return 0; -} - - -ibgFrameScrollSubject* iggSubjectFactory::CreateFrameScrollSubject(iggFrameScroll *owner, bool withHor, bool withVer) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,FrameScroll,withHor,withVer); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,FrameScroll,withHor,withVer); -#else - return 0; -#endif - } - - return 0; -} - - -ibgMainWindowSubject* iggSubjectFactory::CreateMainWindowSubject(iggMainWindow *owner, int cols) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - iqtMainWindowSubject *tmp = new iqtMainWindowSubject(owner); - owner->AttachSubject(tmp,cols); - return tmp; -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - ifxMainWindowSubject *tmp = new ifxMainWindowSubject(owner); - owner->AttachSubject(tmp,cols); - return tmp; -#else - return 0; -#endif - } - - return 0; -} - - -ibgMenuWindowSubject* iggSubjectFactory::CreateMenuWindowSubject(iggMenuWindow *owner, const iImage *icon, const iString &title) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - return new iqtMenuWindowSubject(owner,icon,title); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - return new ifxMenuWindowSubject(owner,icon,title); -#else - return 0; -#endif - } - - return 0; -} - - -ibgRenderWindowSubject* iggSubjectFactory::CreateRenderWindowSubject(iggRenderWindow *owner) -{ - if(owner->GetViewModule()->GetControlModule()->GetShell() == 0) return 0; - - if(owner->GetViewModule()->GetControlModule()->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - return new iqtRenderWindowSubject(owner); -#else - return 0; -#endif - } - - if(owner->GetViewModule()->GetControlModule()->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - return new ifxRenderWindowSubject(owner); -#else - return 0; -#endif - } - - return 0; -} - -ibgShellSubject* iggSubjectFactory::CreateShellSubject(iggShell *owner, int argc, char **argv) -{ - if(owner == 0) return 0; - - if(owner->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - return new iqtShellSubject(owner,argc,argv); -#else - return 0; -#endif - } - - if(owner->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - return new ifxShellSubject(owner,,argc,argv); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetButtonSubject* iggSubjectFactory::CreateWidgetButtonSubject(iggWidget *owner, int type, const iString &text, int slot) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT3(qt,WidgetButton,type,text,slot); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT3(fx,WidgetButton,type,text,slot); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetColorSelectionSubject* iggSubjectFactory::CreateWidgetColorSelectionSubject(iggWidget *owner, bool horizontal) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,WidgetColorSelection,horizontal); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,WidgetColorSelection,horizontal); -#else - return 0; -#endif - } - - return 0; -} - -ibgWidgetComboBoxSubject* iggSubjectFactory::CreateWidgetComboBoxSubject(iggWidget *owner, const iString &title, bool bold) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,WidgetComboBox,title,bold); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,WidgetComboBox,title,bold); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetDisplayAreaSubject* iggSubjectFactory::CreateWidgetDisplayAreaSubject(iggWidget *owner, const iString &text) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,WidgetDisplayArea,text); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,WidgetDisplayArea,text); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetDrawAreaSubject* iggSubjectFactory::CreateWidgetDrawAreaSubject(iggWidgetDrawArea *owner, bool interactive) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,WidgetDrawArea,interactive); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,WidgetDrawArea,interactive); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetEntrySubject* iggSubjectFactory::CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT4(qt,WidgetEntry,slider,numdig,label,rmb); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT4(fx,WidgetEntry,slider,numdig,label,rmb); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetHelpBrowserSubject* iggSubjectFactory::CreateWidgetHelpBrowserSubject(iggWidgetHelpBrowser *owner) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT0(qt,WidgetHelpBrowser); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT0(fx,WidgetHelpBrowser); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetMultiImageDisplayAreaSubject* iggSubjectFactory::CreateWidgetMultiImageDisplayAreaSubject(iggWidget *owner) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT0(qt,WidgetMultiImageDisplayArea); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT0(fx,WidgetMultiImageDisplayArea); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetProgressBarSubject* iggSubjectFactory::CreateWidgetProgressBarSubject(iggWidget *owner) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT0(qt,WidgetProgressBar); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT0(fx,WidgetProgressBar); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetRadioBoxSubject* iggSubjectFactory::CreateWidgetRadioBoxSubject(iggWidget *owner, int cols, const iString &title) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,WidgetRadioBox,cols,title); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,WidgetRadioBox,cols,title); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetSpinBoxSubject* iggSubjectFactory::CreateWidgetSpinBoxSubject(iggWidget *owner, int min, int max, const iString &title, int step) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT4(qt,WidgetSpinBox,min,max,title,step); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT4(fx,WidgetSpinBox,min,max,title,step); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetTextEditorSubject* iggSubjectFactory::CreateWidgetTextEditorSubject(iggWidgetTextEditor *owner, unsigned int mode) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,WidgetTextEditor,mode); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT0(fx,WidgetTextEditor,mode); -#else - return 0; -#endif - } - - return 0; -} - - -ibgWidgetTrackBallSubject* iggSubjectFactory::CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,WidgetTrackBall,followCamera,rmb); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,WidgetTrackBall,followCamera,rmb); -#else - return 0; -#endif - } - - return 0; -} - -#endif -/* - -ibgWidgetSubject* iggSubjectFactory::CreateWidgetSubject(iggWidget *owner, ) -{ - if(owner->GetShell() == 0) return 0; - - if(owner->GetShell()->Type() == qt) - { -#if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT(qt,Widget,); -#else - return 0; -#endif - } - - if(owner->GetShell()->Type() == fx) - { -#if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT(fx,Widget,); -#else - return 0; -#endif - } - - return 0; -} - -*/ diff -Nru ifrit-3.3.4/shells/configure/.#iggsubjectfactory.h.1.1.1.1 ifrit-3.4.2/shells/configure/.#iggsubjectfactory.h.1.1.1.1 --- ifrit-3.3.4/shells/configure/.#iggsubjectfactory.h.1.1.1.1 2011-01-27 17:50:44.000000000 +0000 +++ ifrit-3.4.2/shells/configure/.#iggsubjectfactory.h.1.1.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,97 +0,0 @@ -//LICENSE A - -// -// A factory that creates various toolkit-specific subjects -// - -#ifndef IGGSUBJECTFACTORY_H -#define IGGSUBJECTFACTORY_H - - -class iImage; -class iShell; -class iString; - -class iggDialog; -class iggExtensionWindow; -class iggFrame; -class iggFrameBook; -class iggFrameFlip; -class iggFrameScroll; -class iggMainWindow; -class iggMenuWindow; -class iggRenderWindow; -class iggShell; -class iggWidget; -class iggWidgetDrawArea; -class iggWidgetHelpBrowser; -class iggWidgetRenderModeButton; -class iggWidgetTextEditor; - -class ibgDialogSubject; -class ibgExtensionWindowSubject; -class ibgFrameSubject; -class ibgFrameBookSubject; -class ibgFrameFlipSubject; -class ibgFrameScrollSubject; -class ibgMainWindowSubject; -class ibgMenuWindowSubject; -class ibgRenderWindowSubject; -class ibgShellSubject; -class ibgWidgetButtonSubject; -class ibgWidgetColorSelectionSubject; -class ibgWidgetComboBoxSubject; -class ibgWidgetDisplayAreaSubject; -class ibgWidgetDrawAreaSubject; -class ibgWidgetEntrySubject; -class ibgWidgetHelpBrowserSubject; -class ibgWidgetMultiImageDisplayAreaSubject; -class ibgWidgetProgressBarSubject; -class ibgWidgetRadioBoxSubject; -class ibgWidgetSpinBoxSubject; -class ibgWidgetTrackBallSubject; -class ibgWidgetTextEditorSubject; -class ibgWindowSubject; - - -class iggSubjectFactory -{ - -public: - - static ibgDialogSubject* CreateDialogSubject(iggDialog *owner, const ibgWindowSubject *base, unsigned int mode, const iImage *icon, const iString &title); - - static ibgExtensionWindowSubject* CreateExtensionWindowSubject(iggExtensionWindow *owner); - - static ibgFrameSubject* CreateFrameSubject(iggFrame *owner, int cols); - static ibgFrameBookSubject* CreateFrameBookSubject(iggFrameBook *owner, int flags); - static ibgFrameFlipSubject* CreateFrameFlipSubject(iggFrameFlip *owner, bool expanding); - static ibgFrameScrollSubject* CreateFrameScrollSubject(iggFrameScroll *owner, bool withHor, bool withVer); - - static ibgMainWindowSubject* CreateMainWindowSubject(iggMainWindow *owner, int cols); - static ibgMenuWindowSubject* CreateMenuWindowSubject(iggMenuWindow *owner, const iImage *icon, const iString &title); - - static ibgRenderWindowSubject* CreateRenderWindowSubject(iggRenderWindow *owner); - - static ibgShellSubject* CreateShellSubject(iggShell *owner, int argc, char **argv); - - static ibgWidgetButtonSubject* CreateWidgetButtonSubject(iggWidget *owner, int type, const iString &text, int slot); - static ibgWidgetColorSelectionSubject* CreateWidgetColorSelectionSubject(iggWidget *owner, bool horizontal); - static ibgWidgetComboBoxSubject* CreateWidgetComboBoxSubject(iggWidget *owner, const iString &title, bool bold = false); - static ibgWidgetDisplayAreaSubject* CreateWidgetDisplayAreaSubject(iggWidget *owner, const iString &text); - static ibgWidgetDrawAreaSubject* CreateWidgetDrawAreaSubject(iggWidgetDrawArea *owner, bool interactive); - static ibgWidgetEntrySubject* CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb); - static ibgWidgetHelpBrowserSubject* CreateWidgetHelpBrowserSubject(iggWidgetHelpBrowser *owner); - static ibgWidgetMultiImageDisplayAreaSubject* CreateWidgetMultiImageDisplayAreaSubject(iggWidget *owner); - static ibgWidgetProgressBarSubject* CreateWidgetProgressBarSubject(iggWidget *owner); - static ibgWidgetRadioBoxSubject* CreateWidgetRadioBoxSubject(iggWidget *owner, int cols, const iString &title); - static ibgWidgetSpinBoxSubject* CreateWidgetSpinBoxSubject(iggWidget *owner, int min, int max, const iString &title, int step); - static ibgWidgetTextEditorSubject* CreateWidgetTextEditorSubject(iggWidgetTextEditor *owner, unsigned int mode); - static ibgWidgetTrackBallSubject* CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb); - -private: - - static const iString qt, fx; -}; - -#endif // IGGSUBJECTFACTORY_H diff -Nru ifrit-3.3.4/shells/configure/iggextensionfactory.cpp ifrit-3.4.2/shells/configure/iggextensionfactory.cpp --- ifrit-3.3.4/shells/configure/iggextensionfactory.cpp 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/configure/iggextensionfactory.cpp 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/configure/iggextensionfactory.h ifrit-3.4.2/shells/configure/iggextensionfactory.h --- ifrit-3.3.4/shells/configure/iggextensionfactory.h 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/configure/iggextensionfactory.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -37,9 +37,7 @@ class iggExtensionFactory { - friend class iggPageView; - -protected: +public: static iggFrame* CreateMultiViewFrame(iggFrameBase *parent); diff -Nru ifrit-3.3.4/shells/configure/iggsubjectfactory.cpp ifrit-3.4.2/shells/configure/iggsubjectfactory.cpp --- ifrit-3.3.4/shells/configure/iggsubjectfactory.cpp 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/configure/iggsubjectfactory.cpp 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -404,14 +404,14 @@ } -ibgWidgetColorSelectionSubject* iggSubjectFactory::CreateWidgetColorSelectionSubject(iggWidget *owner, bool horizontal) +ibgWidgetColorSelectionSubject* iggSubjectFactory::CreateWidgetColorSelectionSubject(iggWidget *owner) { if(owner->GetShell() == 0) return 0; if(owner->GetShell()->Type() == qt) { #if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT1(qt,WidgetColorSelection,horizontal); + RETURN_SUBJECT0(qt,WidgetColorSelection); #else return 0; #endif @@ -420,7 +420,7 @@ if(owner->GetShell()->Type() == fx) { #if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT1(fx,WidgetColorSelection,horizontal); + RETURN_SUBJECT0(fx,WidgetColorSelection); #else return 0; #endif @@ -507,14 +507,14 @@ } -ibgWidgetEntrySubject* iggSubjectFactory::CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb) +ibgWidgetEntrySubject* iggSubjectFactory::CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label) { if(owner->GetShell() == 0) return 0; if(owner->GetShell()->Type() == qt) { #if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT4(qt,WidgetEntry,slider,numdig,label,rmb); + RETURN_SUBJECT3(qt,WidgetEntry,slider,numdig,label); #else return 0; #endif @@ -523,7 +523,7 @@ if(owner->GetShell()->Type() == fx) { #if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT4(fx,WidgetEntry,slider,numdig,label,rmb); + RETURN_SUBJECT3(fx,WidgetEntry,slider,numdig,label); #else return 0; #endif @@ -689,14 +689,14 @@ } -ibgWidgetTrackBallSubject* iggSubjectFactory::CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb) +ibgWidgetTrackBallSubject* iggSubjectFactory::CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera) { if(owner->GetShell() == 0) return 0; if(owner->GetShell()->Type() == qt) { #if ISHELL_INCLUDED(ISHELL_QT) - RETURN_SUBJECT2(qt,WidgetTrackBall,followCamera,rmb); + RETURN_SUBJECT1(qt,WidgetTrackBall,followCamera); #else return 0; #endif @@ -705,7 +705,7 @@ if(owner->GetShell()->Type() == fx) { #if ISHELL_INCLUDED(ISHELL_FX) - RETURN_SUBJECT2(fx,WidgetTrackBall,followCamera,rmb); + RETURN_SUBJECT1(fx,WidgetTrackBall,followCamera); #else return 0; #endif diff -Nru ifrit-3.3.4/shells/configure/iggsubjectfactory.h ifrit-3.4.2/shells/configure/iggsubjectfactory.h --- ifrit-3.3.4/shells/configure/iggsubjectfactory.h 2011-01-27 17:52:10.000000000 +0000 +++ ifrit-3.4.2/shells/configure/iggsubjectfactory.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -50,7 +50,6 @@ class iggWidget; class iggWidgetDrawArea; class iggWidgetHelpBrowser; -class iggWidgetRenderModeButton; class iggWidgetTextEditor; class ibgDialogSubject; @@ -101,18 +100,18 @@ static ibgShellSubject* CreateShellSubject(iggShell *owner, int argc, char **argv); static ibgWidgetButtonSubject* CreateWidgetButtonSubject(iggWidget *owner, int type, const iString &text, int slot); - static ibgWidgetColorSelectionSubject* CreateWidgetColorSelectionSubject(iggWidget *owner, bool horizontal); + static ibgWidgetColorSelectionSubject* CreateWidgetColorSelectionSubject(iggWidget *owner); static ibgWidgetComboBoxSubject* CreateWidgetComboBoxSubject(iggWidget *owner, const iString &title, bool bold = false); static ibgWidgetDisplayAreaSubject* CreateWidgetDisplayAreaSubject(iggWidget *owner, const iString &text); static ibgWidgetDrawAreaSubject* CreateWidgetDrawAreaSubject(iggWidgetDrawArea *owner, bool interactive); - static ibgWidgetEntrySubject* CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb); + static ibgWidgetEntrySubject* CreateWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label); static ibgWidgetHelpBrowserSubject* CreateWidgetHelpBrowserSubject(iggWidgetHelpBrowser *owner); static ibgWidgetMultiImageDisplayAreaSubject* CreateWidgetMultiImageDisplayAreaSubject(iggWidget *owner); static ibgWidgetProgressBarSubject* CreateWidgetProgressBarSubject(iggWidget *owner); static ibgWidgetRadioBoxSubject* CreateWidgetRadioBoxSubject(iggWidget *owner, int cols, const iString &title); static ibgWidgetSpinBoxSubject* CreateWidgetSpinBoxSubject(iggWidget *owner, int min, int max, const iString &title, int step); static ibgWidgetTextEditorSubject* CreateWidgetTextEditorSubject(iggWidgetTextEditor *owner, unsigned int mode); - static ibgWidgetTrackBallSubject* CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb); + static ibgWidgetTrackBallSubject* CreateWidgetTrackBallSubject(iggWidget *owner, bool followCamera); private: diff -Nru ifrit-3.3.4/shells/generic/.#iggframe.cpp.1.2 ifrit-3.4.2/shells/generic/.#iggframe.cpp.1.2 --- ifrit-3.3.4/shells/generic/.#iggframe.cpp.1.2 2011-01-27 17:50:45.000000000 +0000 +++ ifrit-3.4.2/shells/generic/.#iggframe.cpp.1.2 1970-01-01 00:00:00.000000000 +0000 @@ -1,589 +0,0 @@ -//LICENSE A - - -#include "iconfigure.h" -#if ISHELL_INCLUDED(ISHELL_GG) - - -#include "iggframe.h" - - -#include "iimage.h" -#include "isystem.h" - -#include "iggmainwindow.h" -#include "iggrenderwindowobserver.h" -#include "iggwidget.h" - -#include "ibgframesubject.h" - -#include "iggsubjectfactory.h" -#include "iggparameter.h" -using namespace iggParameter; - -// -// Templates -// -#include "iarraytemplate.h" - - -// -// Base Frame class -// -iggFrameBase::iggFrameBase(iggFrameBase *parent) : iggWidget(parent) -{ - this->Define(); -} - - -iggFrameBase::iggFrameBase(iShell *shell) : iggWidget(shell) -{ - mWasLaidOut = true; - this->Define(); -} - - -void iggFrameBase::Define() -{ - mNeedsBaloonHelp = false; - mNeedsUpdate = true; -} - - -iggFrameBase::~iggFrameBase() -{ - // - // Make sure our help status is up-to-date - // - this->CheckBaloonHelpStatus(); - // - // Delete all children (they unregisted themselves) - // - while(mChildren.Size() > 0) - { - delete mChildren.Last(); - } -} - - -bool iggFrameBase::CheckBaloonHelpStatus() -{ - if(mNeedsBaloonHelp) - { - int i; - bool ok = true; - for(i=0; ok && iCheckBaloonHelpStatus()) - { - ok = false; -#ifdef I_CHECK1 - mChildren[i]->CheckBaloonHelpStatus(); -#endif - } - } - if(ok) mNeedsBaloonHelp = false; // all children have their own help - } - return this->iggWidget::CheckBaloonHelpStatus(); -} - - -void iggFrameBase::RegisterChild(iggWidget *child) -{ - int i; - - if(child != 0) - { - mChildren.AddUnique(child); - // - // Add already set dependencies to this child - // - for(i=0; iAddDependent(mDependents[i]); - } - } -} - - -void iggFrameBase::UnRegisterChild(iggWidget *child) -{ - if(child != 0) mChildren.Remove(child); -} - - -void iggFrameBase::RegisterRenderWindowObserver(iggRenderWindowObserver *rwo) -{ - if(rwo != 0) mRenderWindowObservers.AddUnique(rwo); -} - - -void iggFrameBase::UnRegisterRenderWindowObserver(iggRenderWindowObserver *rwo) -{ - if(rwo != 0) mRenderWindowObservers.Remove(rwo); -} - - -// -// Frames do not have buddies - their widgets do -// -void iggFrameBase::AddDependent(iggWidget *w) -{ - int i; - for(i=0; iAddDependent(w); // when buddy changes, we update through the parent frame - } - iggWidget::AddDependent(w); -} - - -void iggFrameBase::RemoveDependent(iggWidget *w) -{ - int i; - for(i=0; iRemoveDependent(w); - } - iggWidget::RemoveDependent(w); -} - - -void iggFrameBase::UpdateWidgetBody() -{ - mNeedsUpdate = true; - if(this->IsVisible()) this->UpdateChildren(); -} - - -// -// Update all children -// -void iggFrameBase::UpdateChildren() -{ - if(mNeedsUpdate) - { - int i; - mNeedsUpdate = false; - for(i=0; iUpdateWidget(); - } - for(i=0; iUpdateConnection(); - } - } -} - - -// -// Pass slot calls to parent -// -void iggFrameBase::OnInt1Body(int v) -{ - if(mParent != 0) mParent->OnInt1Body(v); -} - - -void iggFrameBase::OnInt2Body(int v) -{ - if(mParent != 0) mParent->OnInt2Body(v); -} - - -void iggFrameBase::OnVoid1Body() -{ - if(mParent != 0) mParent->OnVoid1Body(); -} - - -void iggFrameBase::OnVoid2Body() -{ - if(mParent != 0) mParent->OnVoid2Body(); -} - - -void iggFrameBase::OnVoid3Body() -{ - if(mParent != 0) mParent->OnVoid3Body(); -} - - -void iggFrameBase::OnBool1Body(bool v) -{ - if(mParent != 0) mParent->OnBool1Body(v); -} - - -void iggFrameBase::OnString1Body(const iString &v) -{ - if(mParent != 0) mParent->OnString1Body(v); -} - - -void iggFrameBase::OnChildFlipped() -{ - iSystem::Sleep(30); - this->GetMainWindow()->ProcessEvents(); -} - - -// -// Plain Frame class with optional border and title -// -iggFrame::iggFrame(const iString& title, iggFrameBase *parent, int cols) : iggFrameBase(parent) -{ - this->Define(cols,true); - this->ShowFrame(true); - this->SetPadding(true); - this->SetTitle(title); -} - - -iggFrame::iggFrame(iggFrameBase *parent, int cols) : iggFrameBase(parent) -{ - this->Define(cols,true); -} - - -iggFrame::iggFrame(iShell *shell, int cols, bool withsubject) : iggFrameBase(shell) -{ - mWasLaidOut = true; - this->Define(cols,withsubject); -} - - -void iggFrame::Define(int cols, bool withsubject) -{ - if(withsubject) - { - mSubject = iggSubjectFactory::CreateFrameSubject(this,cols); - } - else - { - mSubject = 0; - } - - mCurCol = mCurRow = 0; -} - - -void iggFrame::GetFrameGeometry(int wg[4]) const -{ - mSubject->GetFrameGeometry(wg); -} - - -void iggFrame::SetTitle(const iString &title) -{ - mSubject->SetTitle(title); -} - - -void iggFrame::ShowFrame(bool s) -{ - mSubject->ShowFrame(s); -} - - -// -// Layout helpers -// -void iggFrame::SetPadding(bool s) -{ - mSubject->SetPadding(s); -} - - -void iggFrame::SetColStretch(int col, int s) -{ - mSubject->SetColStretch(col,s); -} - - -void iggFrame::SetRowStretch(int row, int s) -{ - mSubject->SetRowStretch(row,s); -} - - -void iggFrame::AddLine(iggWidget *child1, iggWidget *child2, iggWidget *child3, iggWidget *child4, iggWidget *child5, iggWidget *child6, iggWidget *child7) -{ - this->AddLine(child1,1,child2,1,child3,1,child4,1,child5,1,child6,1,child7,1); -} - - -void iggFrame::AddLine(iggWidget *child1, int nc1, iggWidget *child2, int nc2, iggWidget *child3, int nc3, iggWidget *child4, int nc4, iggWidget *child5, int nc5, iggWidget *child6, int nc6, iggWidget *child7, int nc7) -{ - if((child1!=0 && child1->GetParent()!=this) || (child2!=0 && child2->GetParent()!=this) || (child3!=0 && child3->GetParent()!=this) || (child4!=0 && child4->GetParent()!=this) || (child5!=0 && child5->GetParent()!=this) || (child6!=0 && child6->GetParent()!=this) || (child7!=0 && child7->GetParent()!=this)) - { - IERROR_LOW("Incorrect parenting in iggFrame class,"); - return; - } - - int c = 0; - this->InsertWidget(c,child1,nc1); - this->InsertWidget(c,child2,nc2); - this->InsertWidget(c,child3,nc3); - this->InsertWidget(c,child4,nc4); - this->InsertWidget(c,child5,nc5); - this->InsertWidget(c,child6,nc6); - this->InsertWidget(c,child7,nc7); - - mCurRow++; - mCurCol = 0; -} - - -void iggFrame::InsertWidget(int &c, iggWidget *child, int nc) -{ - if(nc > 0) - { - if(child != 0) - { - mSubject->PlaceWidget(c,mCurRow,child->mWidgetSubject,nc,true); - child->mWasLaidOut = true; - } - c += nc; - } -} - - -void iggFrame::AddSpace(int stretch) -{ - mSubject->PlaceWidget(0,mCurRow,0,1,true); - mSubject->SetRowStretch(mCurRow++,stretch); - mCurCol = 0; -} - - -// -// Allow selected widgets to clear the laid-out flag -// -void iggFrame::ClearLaidOutFlag(const iggFrameBook *book) -{ - if(book!=0 && book->GetLastPage()==this) mWasLaidOut = true; -} - - -void iggFrame::ClearLaidOutFlag(const iggFrameFlip *flip) -{ - if(flip!=0 && flip->GetLastLayer()==this) mWasLaidOut = true; -} - - -void iggFrame::ClearLaidOutFlag(const iggFrameScroll *scroll) -{ - if(scroll!=0 && scroll->GetContents()==this) mWasLaidOut = true; -} - - -void iggFrame::FlipThroughAllChildren() -{ - int i; - iggFrameBase *c; - bool v = this->IsVisible(); - - if(!v) this->Show(true); - - this->OnChildFlipped(); - for(i=0; i(mChildren[i]); - if(c != 0) c->FlipThroughAllChildren(); - } - - if(!v) this->Show(false); -} - - -// -// FrameBook class -// -iggFrameBook::iggFrameBook(iggFrameBase *parent, bool withFeedback, TabMode tabMode) : iggFrameBase(parent) -{ - mSubject = iggSubjectFactory::CreateFrameBookSubject(this,withFeedback,tabMode); - - mFlippable = (tabMode == _Flippable); - mNeedsBaloonHelp = false; -} - - -iggFrame* iggFrameBook::GetPage(int i) const -{ - if(i>=0 && i=0 && iOpenPage(i); - } - else - { - IERROR_LOW("Trying to open an non-existent page."); - } -} - - -void iggFrameBook::AddPage(const iString &title, const iImage *image, iggFrame *frame, int index) -{ - Page tmp; - - if(frame->GetParent() != this) - { - IERROR_FATAL("Icorrect parenting in iggFrameBook."); - } - - frame->SetPadding(true); - - mSubject->AddPage(title,image,frame); - - tmp.Title = title; - tmp.Image = image; - tmp.Frame = frame; - tmp.Index = index; - mPages.Add(tmp); - - frame->ClearLaidOutFlag(this); -} - - -void iggFrameBook::ChangeIcon(int page, const iImage *image) -{ - int n; - - if(page>=0 && pageChangeIcon(page,*image); - } - else - { - for(n=0; nChangeIcon(n,*image); - } - } -} - - -void iggFrameBook::SetTabMode(int m) -{ - int n; - - if(m<0 || m>2) IERROR_FATAL("Invalid Book tab mode."); - - for(n=0; nSetTabMode(n,m,mPages[n].Title,mPages[n].Image); - } -} - - -int iggFrameBook::GetTabMode() const -{ - return mSubject->GetTabMode(); -} - - -void iggFrameBook::EnablePage(int n, bool s) -{ - if(n>=0 && nEnable(s); -} - - -void iggFrameBook::FlipThroughAllChildren() -{ - int i; - - for(i=0; iOpenPage(i); - mPages[i].Frame->FlipThroughAllChildren(); - } -} - - -// -// FrameFlip class -// -iggFrameFlip::iggFrameFlip(iggFrameBase *parent, bool expanding) : iggFrameBase(parent) -{ - mSubject = iggSubjectFactory::CreateFrameFlipSubject(this,expanding); - mNeedsBaloonHelp = false; - - mCurrentLayer = -1; -} - -int iggFrameFlip::Count() const -{ - return mLayers.Size(); -} - - -void iggFrameFlip::ShowLayer(int i) -{ - if(i>=0 && iShowLayer(i); - mCurrentLayer = i; - } -} - - -void iggFrameFlip::AddLayer(iggFrame *page) -{ - if(page->GetParent() != this) - { - IERROR_FATAL("Icorrect parenting in iggFrameFlip."); - } - - mLayers.Add(page); - mSubject->AddLayer(page); - page->ClearLaidOutFlag(this); -} - - -void iggFrameFlip::FlipThroughAllChildren() -{ - int i; - - for(i=0; iShowLayer(i); - mLayers[i]->FlipThroughAllChildren(); - } -} - - -// -// FrameScroll class -// -iggFrameScroll::iggFrameScroll(iggFrameBase *parent, bool withHor, int numcol, bool withVer) : iggFrameBase(parent) -{ - mSubject = iggSubjectFactory::CreateFrameScrollSubject(this,withHor,withVer); - mContents = new iggFrame(this,numcol); - mSubject->AttachContents(mContents); - mContents->ClearLaidOutFlag(this); - - mNeedsBaloonHelp = false; -} - - -void iggFrameScroll::FlipThroughAllChildren() -{ - mContents->FlipThroughAllChildren(); -} - -#endif diff -Nru ifrit-3.3.4/shells/generic/.#iggframe.h.1.1.1.1 ifrit-3.4.2/shells/generic/.#iggframe.h.1.1.1.1 --- ifrit-3.3.4/shells/generic/.#iggframe.h.1.1.1.1 2011-01-27 17:50:45.000000000 +0000 +++ ifrit-3.4.2/shells/generic/.#iggframe.h.1.1.1.1 1970-01-01 00:00:00.000000000 +0000 @@ -1,236 +0,0 @@ -//LICENSE A - -// -// A generic (toolkit-independent) containers. -// - -#ifndef IGGFRAME_H -#define IGGFRAME_H - - -#include "iggwidget.h" - - -#include "iarray.h" -#include "istring.h" - -class iImage; - -class iggFrameBook; -class iggFrameFlip; -class iggFrameScroll; -class iggRenderWindowObserver; - -class ibgFrameSubject; -class ibgFrameBookSubject; -class ibgFrameFlipSubject; -class ibgFrameScrollSubject; -class ibgFrameHelper; - - -// -// Base Frame class -// -class iggFrameBase : public iggWidget -{ - -public: - - virtual ~iggFrameBase(); - - virtual bool CheckBaloonHelpStatus(); - - void RegisterChild(iggWidget *child); - void UnRegisterChild(iggWidget *child); - - void RegisterRenderWindowObserver(iggRenderWindowObserver *rwo); - void UnRegisterRenderWindowObserver(iggRenderWindowObserver *rwo); - - virtual void AddDependent(iggWidget *w); - virtual void RemoveDependent(iggWidget *w); - - virtual void FlipThroughAllChildren() = 0; - -protected: - - iggFrameBase(iggFrameBase *parent); - iggFrameBase(iShell *shell); - - virtual void UpdateWidgetBody(); - // - // Children are updated when this frame is updated - // - virtual void UpdateChildren(); - - virtual void OnInt1Body(int); - virtual void OnInt2Body(int); - virtual void OnVoid1Body(); - virtual void OnVoid2Body(); - virtual void OnVoid3Body(); - virtual void OnBool1Body(bool); - virtual void OnString1Body(const iString &); - - void OnChildFlipped(); - - bool mNeedsUpdate; - iPointerArray mChildren; - iPointerArray mRenderWindowObservers; - -private: - - void Define(); -}; - - -// -// Plain frame with an optional border and title -// -class iggFrame : public iggFrameBase -{ - - friend class ibgFrameSubject; - -public: - - iggFrame(const iString& title, iggFrameBase *parent, int cols = 1); - iggFrame(iggFrameBase *parent, int cols = 1); - iggFrame(iShell *shell, int cols = 1, bool withsubject = true); - - inline ibgFrameSubject* GetSubject() const { return mSubject; } - - void SetPadding(bool s); - void SetColStretch(int col, int s); - void SetRowStretch(int row, int s); - - void AddLine(iggWidget *child1, iggWidget *child2 = 0, iggWidget *child3 = 0, iggWidget *child4 = 0, iggWidget *child5 = 0, iggWidget *child6 = 0, iggWidget *child7 = 0); - void AddLine(iggWidget *child1, int nc1, iggWidget *child2 = 0, int nc2 = 1, iggWidget *child3 = 0, int nc3 = 1, iggWidget *child4 = 0, int nc4 = 1, iggWidget *child5 = 0, int nc5 = 1, iggWidget *child6 = 0, int nc6 = 1, iggWidget *child7 = 0, int nc7 = 1); - void AddSpace(int stretch); - - virtual void GetFrameGeometry(int wg[4]) const; - - void SetTitle(const iString &title); - void ShowFrame(bool s); - - virtual void FlipThroughAllChildren(); - - // - // Allow selected widgets to clear the laid-out flag - // - void ClearLaidOutFlag(const iggFrameBook *book); - void ClearLaidOutFlag(const iggFrameFlip *flip); - void ClearLaidOutFlag(const iggFrameScroll *scroll); - -protected: - - int mCurCol, mCurRow; - ibgFrameSubject *mSubject; - -private: - - void Define(int cols, bool withsubject); - void InsertWidget(int &c, iggWidget *child, int nc); -}; - - -// -// A generic Book frame (TabBook, TabWidget). -// -class iggFrameBook : public iggFrameBase -{ - -public: - - enum TabMode - { - _Top = 0, - _Bottom = 1, - _Left = 2, - _Right = 3, - _Flippable = 4, - _WithFeedback = 8 - }; - - iggFrameBook(iggFrameBase *parent, int flags = 0); - - void OpenPage(int i); - void AddPage(const iString &title, const iImage *image, iggFrame *frame, int index = -1); - void SetTabMode(int m); - int GetTabMode() const; - void Flip(); - - void ChangeIcon(int page, const iImage *image); - - void EnablePage(int n, bool s); - iggFrame* GetPage(int i) const; - const iggFrame* GetLastPage() const; - - virtual void FlipThroughAllChildren(); - -protected: - - struct Page - { - iString Title; - const iImage *Image; - iggFrame *Frame; - int Index; - Page() { Title = ""; Image = 0; Frame = 0; Index = -1; } - }; - - bool mFlippable; - iArray mPages; - - ibgFrameBookSubject *mSubject; -}; - - -// -// A frame that has several layers and shows a specific one on demand. -// -class iggFrameFlip : public iggFrameBase -{ - -public: - - iggFrameFlip(iggFrameBase *parent, bool expanding = true); - - int Count() const; - - inline int GetCurrentLayer() const { return mCurrentLayer; } - void ShowLayer(int i); - void AddLayer(iggFrame *layer); - - const iggFrame* GetLastLayer() const { return mLayers.Last(); } - - virtual void FlipThroughAllChildren(); - -protected: - - int mCurrentLayer; - iArray mLayers; - ibgFrameFlipSubject *mSubject; -}; - - -// -// A frame that allows its contents to scroll up/down and left/right -// -class iggFrameScroll : public iggFrameBase -{ - -public: - - iggFrameScroll(iggFrameBase *parent, bool withHor = true, int numcol = 1, bool withVer = true); - - inline iggFrame* GetContents() const { return mContents; } - - virtual void FlipThroughAllChildren(); - -protected: - - iggFrame *mContents; - ibgFrameScrollSubject *mSubject; -}; - -#endif // IGGFRAME_H - diff -Nru ifrit-3.3.4/shells/generic/iggabstractextension.cpp ifrit-3.4.2/shells/generic/iggabstractextension.cpp --- ifrit-3.3.4/shells/generic/iggabstractextension.cpp 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggabstractextension.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggabstractextension.h ifrit-3.4.2/shells/generic/iggabstractextension.h --- ifrit-3.3.4/shells/generic/iggabstractextension.h 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggabstractextension.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggcommoneventobservers.cpp ifrit-3.4.2/shells/generic/iggcommoneventobservers.cpp --- ifrit-3.3.4/shells/generic/iggcommoneventobservers.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggcommoneventobservers.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggcommoneventobservers.h ifrit-3.4.2/shells/generic/iggcommoneventobservers.h --- ifrit-3.3.4/shells/generic/iggcommoneventobservers.h 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggcommoneventobservers.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggcontrolscript.cpp ifrit-3.4.2/shells/generic/iggcontrolscript.cpp --- ifrit-3.3.4/shells/generic/iggcontrolscript.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggcontrolscript.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggcontrolscript.h ifrit-3.4.2/shells/generic/iggcontrolscript.h --- ifrit-3.3.4/shells/generic/iggcontrolscript.h 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggcontrolscript.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggdatatypeprovider.cpp ifrit-3.4.2/shells/generic/iggdatatypeprovider.cpp --- ifrit-3.3.4/shells/generic/iggdatatypeprovider.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdatatypeprovider.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggdatatypeprovider.h ifrit-3.4.2/shells/generic/iggdatatypeprovider.h --- ifrit-3.3.4/shells/generic/iggdatatypeprovider.h 2011-01-27 17:52:11.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdatatypeprovider.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggdialog.cpp ifrit-3.4.2/shells/generic/iggdialog.cpp --- ifrit-3.3.4/shells/generic/iggdialog.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialog.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -34,6 +34,7 @@ #include "ierror.h" +#include "isystem.h" #include "ihelpfactory.h" @@ -48,6 +49,11 @@ #include "iggsubjectfactory.h" +// +// Templates +// +#include "iarraytemplate.h" + // // Main class @@ -120,12 +126,17 @@ mHelp = iHelpFactory::FindData(helpkey,iHelpFactory::_ShellReference); } mFrame->SetBaloonHelp(this->GetToolTip(),this->GetBaloonHelp()); + + mCompleteConstructionCalled = false; + List().Add(this); } iggDialog::~iggDialog() { - this->Show(false); + mSubject->Show(false); + + List().Remove(this); delete mFrame; if(mHelp != 0) delete mHelp; @@ -133,6 +144,13 @@ } +iPointerArray& iggDialog::List() +{ + static iPointerArray list(100); + return list; +} + + void iggDialog::AttachSubject(ibgDialogSubject* /*subject*/) { // @@ -167,6 +185,14 @@ return; } + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + + this->ShowBody(s); +} + + +void iggDialog::ShowBody(bool s) +{ if(s) { if(mSubject->IsVisible()) return; @@ -177,7 +203,7 @@ else mSubject->Show(false); } - + bool iggDialog::IsVisible() const { return mSubject->IsVisible(); @@ -216,4 +242,37 @@ if(this->CanBeClosed()) this->Show(false); } + +bool iggDialog::ImmediateConstruction() const +{ + return iRequiredCast(INFO,this->GetShell())->CheckCondition(iParameter::Condition::DisableDelayedInitialization); +} + + +void iggDialog::CompleteConstruction() +{ + if(mCompleteConstructionCalled) return; + + this->CompleteConstructionBody(); + mCompleteConstructionCalled = true; +#ifdef I_DEBUG + iConsole::PrintDebugMessage(iString("Completing delayed construction for element #")+iString::FromNumber(this->GetId())); +#endif +} + + +#ifdef I_DEBUG +void iggDialog::FlashAllDialogs() +{ + int i; + iPointerArray& list = List(); + for(i=0; iShow(true); + iSystem::Sleep(300); + list[i]->Show(false); + } +} +#endif + #endif diff -Nru ifrit-3.3.4/shells/generic/iggdialog.h ifrit-3.4.2/shells/generic/iggdialog.h --- ifrit-3.3.4/shells/generic/iggdialog.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialog.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -36,6 +36,9 @@ #include "iggelement.h" +#include "iarray.h" + + class iImage; class iString; @@ -78,7 +81,7 @@ inline ibgDialogSubject* GetSubject() const { return mSubject; } inline iggFrame* GetFrame() const { return mFrame; } - virtual void Show(bool s); + void Show(bool s); bool IsVisible() const; void ResizeContents(int w, int h); @@ -93,15 +96,25 @@ virtual const iString& GetToolTip() const; iString GetBaloonHelp() const; +#ifdef I_DEBUG + static void FlashAllDialogs(); +#endif + protected: iggDialog(iShell *shell, unsigned int mode, const iImage *icon, const iString &title, const char *helpkey, int cols, const char *closetext = ""); iggDialog(const iggMenuWindow *mw, unsigned int mode, const iImage *icon, const iString &title, const char *helpkey, int cols, const char *closetext = ""); iggDialog(const iggDialog *pd, unsigned int mode, const iImage *icon, const iString &title, const char *helpkey, int cols, const char *closetext = ""); + virtual void ShowBody(bool s); virtual bool CanBeClosed(); void AttachSubject(ibgDialogSubject *subject); // this is a dummy for factory use + bool ImmediateConstruction() const; + void CompleteConstruction(); + virtual void CompleteConstructionBody() = 0; + + bool mCompleteConstructionCalled; ibgDialogSubject *mSubject; iggMainWindow *mMainWindow; iggFrame *mFrame; @@ -112,6 +125,11 @@ void Define(const ibgWindowSubject *base, unsigned int mode, const iImage *icon, const iString &title, const char *helpkey, int cols, const char *closetext); + // + // Registry + // + static iPointerArray& List(); + iggDialog(const iggDialog&); // Not implemented. void operator=(const iggDialog&); // Not implemented. }; diff -Nru ifrit-3.3.4/shells/generic/iggdialoganimatingprogress.cpp ifrit-3.4.2/shells/generic/iggdialoganimatingprogress.cpp --- ifrit-3.3.4/shells/generic/iggdialoganimatingprogress.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialoganimatingprogress.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -117,6 +117,12 @@ iggDialogAnimatingProgress::iggDialogAnimatingProgress(iggMainWindow *parent) : iggDialog(parent,DialogFlag::Blocking|DialogFlag::NoTitleBar,0,"Animating...",0,4,0), iScriptObserver(0) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogAnimatingProgress::CompleteConstructionBody() +{ mFrame->AddLine(new iggWidgetTextArea("%bAnimating the scene...",mFrame),4); mFrame->AddSpace(10); @@ -124,9 +130,6 @@ mFrame->AddSpace(10); mInfoFrame = new iggFrame(mFrame,2); - mCurrentImageNumber = new iggWidgetTextArea(" 1",mInfoFrame); - mCurrentImageNumber->AlignLeft(true); - mInfoFrame->AddLine(new iggWidgetTextArea("Current image #: ",mInfoFrame),mCurrentImageNumber); mCurrentRecord = new iggWidgetTextArea(" 0",mInfoFrame); mCurrentRecord->AlignLeft(true); mInfoFrame->AddLine(new iggWidgetTextArea("Current record: ",mInfoFrame),mCurrentRecord); @@ -164,7 +167,9 @@ mCancelled = false; this->Pause(false); - mLastImageIndex = mLastRecord = mLastFrame = -1; + mLastRecord = mLastFrame = -1; + + mCurrentViewModule = this->GetShell()->GetControlModule()->GetViewModule(); this->DisplayInfo(); @@ -194,15 +199,13 @@ void iggDialogAnimatingProgress::DisplayInfo() { bool nr; - int cr, cf, cii = mCurrentViewModule->GetWriter()->GetCurrentAnimationImageIndex(); + int cr, cf; + iString s; + + this->CompleteConstruction(); mCurrentViewModule->GetAnimator()->GetInfo(nr,cr,cf); - if(cii != mLastImageIndex) - { - mLastImageIndex = cii; - mCurrentImageNumber->SetText(iString::FromNumber(cii,"%5d")); - } if(cr != mLastRecord) { mLastRecord = cr; @@ -241,6 +244,8 @@ { mPaused = s; + this->CompleteConstruction(); + mInfoFrame->Show(!s); mWarningFrame->Show(s); diff -Nru ifrit-3.3.4/shells/generic/iggdialoganimatingprogress.h ifrit-3.4.2/shells/generic/iggdialoganimatingprogress.h --- ifrit-3.3.4/shells/generic/iggdialoganimatingprogress.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialoganimatingprogress.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -60,6 +60,8 @@ protected: + virtual void CompleteConstructionBody(); + virtual void OnScriptStartBody(); virtual void OnScriptStopBody(const iString &error); virtual void OnScriptBeginLineBody(int line, const iString &text); @@ -71,9 +73,9 @@ iViewModule *mCurrentViewModule; bool mCancelled, mPaused; - iggWidgetTextArea *mCurrentImageNumber, *mCurrentFrame, *mCurrentRecord, *mWarning; + iggWidgetTextArea *mCurrentFrame, *mCurrentRecord, *mWarning; iggFrame *mInfoFrame, *mWarningFrame; - int mLastImageIndex, mLastRecord, mLastFrame; + int mLastRecord, mLastFrame; }; #endif // IGGDIALOGANIMATINGPROGRESS_H diff -Nru ifrit-3.3.4/shells/generic/iggdialogauto.cpp ifrit-3.4.2/shells/generic/iggdialogauto.cpp --- ifrit-3.3.4/shells/generic/iggdialogauto.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogauto.cpp 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -54,7 +54,7 @@ } -void iggDialogAuto::Show(bool s) +void iggDialogAuto::ShowBody(bool s) { if(!s || !mBlockShowing) { @@ -65,7 +65,8 @@ void iggDialogAuto::ForceShow(bool s) { - this->iggDialog::Show(s); + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + this->iggDialog::ShowBody(s); if((mMode & iParameter::DialogFlag::Modal) == 0) this->GetMainWindow()->PlaceAutoDialogs(); } diff -Nru ifrit-3.3.4/shells/generic/iggdialogauto.h ifrit-3.4.2/shells/generic/iggdialogauto.h --- ifrit-3.3.4/shells/generic/iggdialogauto.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogauto.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -49,13 +49,14 @@ virtual ~iggDialogAuto(); const iString& GetTitle() const { return mTitle; } - virtual void Show(bool s); void ForceShow(bool s); protected: iggDialogAuto(iggMainWindow *mw, const iString &title, int cols); + virtual void ShowBody(bool s); + private: const iString mTitle; diff -Nru ifrit-3.3.4/shells/generic/iggdialogcommandline.cpp ifrit-3.4.2/shells/generic/iggdialogcommandline.cpp --- ifrit-3.3.4/shells/generic/iggdialogcommandline.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogcommandline.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -292,7 +292,7 @@ mDialog = dialog; mCurHistoryLine = -1; - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,""); this->SetBaloonHelp("Type a script command","Type a Control Script command to be executed. Add a semicolon (;) at the end of the command to execute this and all previous unexecuted commands.

"+Help1); } @@ -487,8 +487,12 @@ mFrame->SetColStretch(1,10); this->ResizeContents(300,400); + + this->CompleteConstruction(); } + void CompleteConstructionBody(){} + virtual const iString& GetToolTip() const { static const iString tmp = "Shows the script text typed in so far"; @@ -497,7 +501,7 @@ protected: - virtual void Show(bool s) + virtual void ShowBody(bool s) { if(s) { @@ -505,7 +509,7 @@ text.Replace("\n","
"); mBrowser->SetText(text); } - iggDialog::Show(s); + iggDialog::ShowBody(s); } CommandInterpreter *mInterpreter; @@ -520,6 +524,15 @@ iggDialogCommandLine::iggDialogCommandLine(iggMainWindow *parent) : iggDialog(parent,0U,iImageFactory::FindIcon("comline.png"),"Command Line","sr.gg.dc",1,0) { + mViewScriptDialog = 0; + mInterpreter = 0; + + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogCommandLine::CompleteConstructionBody() +{ iggWidgetTextBrowser *b = new iggWidgetTextBrowser(true,false,mFrame); CommandInterpreter *ci = new CommandInterpreter(b); ci->Start(); @@ -577,8 +590,8 @@ iggDialogCommandLine::~iggDialogCommandLine() { - delete mViewScriptDialog; - mInterpreter->Delete(); + if(mViewScriptDialog != 0) delete mViewScriptDialog; + if(mInterpreter != 0) mInterpreter->Delete(); } diff -Nru ifrit-3.3.4/shells/generic/iggdialogcommandline.h ifrit-3.4.2/shells/generic/iggdialogcommandline.h --- ifrit-3.3.4/shells/generic/iggdialogcommandline.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogcommandline.h 2013-07-11 01:23:50.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -52,6 +52,8 @@ protected: + virtual void CompleteConstructionBody(); + iggDialog *mViewScriptDialog; iggFrame *mSingleLineFrame, *mMultiLineFrame; iCommandInterpreter *mInterpreter; diff -Nru ifrit-3.3.4/shells/generic/iggdialogdataexplorer.cpp ifrit-3.4.2/shells/generic/iggdialogdataexplorer.cpp --- ifrit-3.3.4/shells/generic/iggdialogdataexplorer.cpp 2011-01-27 17:52:22.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogdataexplorer.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -104,7 +104,7 @@ VariablePropertyDialogOpacitySlider(VariablePropertyDialog *dialog, iggFrame *parent) : iggWidget(parent) { mDialog = dialog; - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,"Opacity",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,"Opacity"); mNeedsBaloonHelp = false; } @@ -125,7 +125,7 @@ VariablePropertyDialogColorSelection(VariablePropertyDialog *dialog, iggFrame *parent) : iggWidget(parent) { mDialog = dialog; - mSubject = iggSubjectFactory::CreateWidgetColorSelectionSubject(this,true); + mSubject = iggSubjectFactory::CreateWidgetColorSelectionSubject(this); mNeedsBaloonHelp = false; } @@ -148,7 +148,10 @@ mList = list; mArea = area; mVariable = 0; + } + void CompleteConstructionBody() + { mFrame->AddLine(new VariablePropertyDialogOpacitySlider(this,mFrame)); mFrame->AddLine(new VariablePropertyDialogColorSelection(this,mFrame)); } @@ -1228,6 +1231,14 @@ iggDialogDataExplorer::iggDialogDataExplorer(iggMainWindow *parent) : iggDialog(parent,0U,iImageFactory::FindIcon("dataexp.png"),"Data Explorer","sr.gg.dd",2) { + mProvider = 0; + + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogDataExplorer::CompleteConstructionBody() +{ iggFrame *box1, *box2, *tmp1, *tmp2; this->SetStretch(iDataStretch::Log); @@ -1329,7 +1340,7 @@ iggDialogDataExplorer::~iggDialogDataExplorer() { - delete mProvider; + if(mProvider != 0) delete mProvider; } diff -Nru ifrit-3.3.4/shells/generic/iggdialogdataexplorer.h ifrit-3.4.2/shells/generic/iggdialogdataexplorer.h --- ifrit-3.3.4/shells/generic/iggdialogdataexplorer.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogdataexplorer.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -52,6 +52,8 @@ protected: + virtual void CompleteConstructionBody(); + iggKeywordDataTypeProvider *mProvider; iggFrameFlip *mFlashFrame; }; diff -Nru ifrit-3.3.4/shells/generic/iggdialogfilesetexplorer.cpp ifrit-3.4.2/shells/generic/iggdialogfilesetexplorer.cpp --- ifrit-3.3.4/shells/generic/iggdialogfilesetexplorer.cpp 2011-01-27 17:52:23.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogfilesetexplorer.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -234,6 +234,12 @@ mMustBeClosed = false; mLoadAll = true; + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogFileSetExplorer::CompleteConstructionBody() +{ mView = new View(this,mFrame); mFrame->AddLine(mView,3); mFrame->AddLine(new LoadAllCheckBox(this,mFrame),(iggWidget *)0,new RefreshButton(this,mFrame)); @@ -255,11 +261,11 @@ } -void iggDialogFileSetExplorer::Show(bool s) +void iggDialogFileSetExplorer::ShowBody(bool s) { mMustBeClosed = false; - iggDialog::Show(s); - if(mMustBeClosed) iggDialog::Show(false); + iggDialog::ShowBody(s); + if(mMustBeClosed) iggDialog::ShowBody(false); } diff -Nru ifrit-3.3.4/shells/generic/iggdialogfilesetexplorer.h ifrit-3.4.2/shells/generic/iggdialogfilesetexplorer.h --- ifrit-3.3.4/shells/generic/iggdialogfilesetexplorer.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogfilesetexplorer.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -43,7 +43,6 @@ iggDialogFileSetExplorer(iggMainWindow *parent); - virtual void Show(bool s); virtual void UpdateDialog(); void SetLoadAll(bool s){ mLoadAll = s; } @@ -55,6 +54,9 @@ protected: + virtual void CompleteConstructionBody(); + virtual void ShowBody(bool s); + bool mMustBeClosed, mLoadAll; iggWidgetListView *mView; }; diff -Nru ifrit-3.3.4/shells/generic/iggdialoghelp.cpp ifrit-3.4.2/shells/generic/iggdialoghelp.cpp --- ifrit-3.3.4/shells/generic/iggdialoghelp.cpp 2011-01-27 17:52:23.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialoghelp.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -198,6 +198,12 @@ // iggDialogHelp::iggDialogHelp(iggMainWindow *parent) : iggDialog(parent,0U,0,"Help","sr.gg.dh",2) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogHelp::CompleteConstructionBody() +{ HelpBrowser *hb = new HelpBrowser(this,mFrame); TopicList *tc = new TopicList(hb,mFrame); mBrowser = hb; diff -Nru ifrit-3.3.4/shells/generic/iggdialoghelp.h ifrit-3.4.2/shells/generic/iggdialoghelp.h --- ifrit-3.3.4/shells/generic/iggdialoghelp.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialoghelp.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -47,6 +47,8 @@ protected: + virtual void CompleteConstructionBody(); + iggWidgetHelpBrowser *mBrowser; }; diff -Nru ifrit-3.3.4/shells/generic/iggdialogimagecomposer.cpp ifrit-3.4.2/shells/generic/iggdialogimagecomposer.cpp --- ifrit-3.3.4/shells/generic/iggdialogimagecomposer.cpp 2011-01-27 17:52:23.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogimagecomposer.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -882,7 +882,14 @@ { mCurrentBackgroundWindow = -1; mCurrentForegroundWindow = -1; + mArea = 0; + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogImageComposer::CompleteConstructionBody() +{ iggFrame *tmp, *tmp2; tmp = new iggFrame(mFrame); @@ -937,12 +944,12 @@ tmp->AddLine(b,2); tmp->AddSpace(10); - tmp2 = new iggFrame(tmp,2); + tmp2 = new iggFrame(tmp,3); wid = new iggWidgetKeySpinBox(0,100,"",0,iImageComposer::KeyBorderWidth(),tmp2); wid->AddDependent(mArea); wid->AddDependent(mLabel); tmp2->AddLine(new iggWidgetTextArea("Border width ",tmp2),wid); - iggWidgetKeyColorSelection *bc = new iggWidgetKeyColorSelection(iImageComposer::KeyBorderColor(),tmp2,true); + iggWidgetKeyColorSelection *bc = new iggWidgetKeyColorSelection(iImageComposer::KeyBorderColor(),tmp2); bc->SetText("Set"); bc->AddDependent(mArea); tmp2->AddLine(new iggWidgetTextArea("Border color ",tmp2),bc); @@ -954,10 +961,12 @@ wid->AddDependent(mArea); wid->AddDependent(mLabel); tmp2->AddLine(wid,2); - tmp2->SetColStretch(1,10); + tmp2->SetColStretch(1,3); + tmp2->SetColStretch(2,10); tmp->AddLine(tmp2); tmp->AddSpace(10); + tmp->SetColStretch(1,10); // // Foreground page @@ -982,7 +991,9 @@ mIndexHolders[1] = new iggWidgetKeySpinBox(0,100,"",0,iImageComposer::KeyForegroundWindowBorderWidth(),b,0); mIndexHolders[1]->AddDependent(mArea); b->AddLine(new iggWidgetTextArea("Border width",b),mIndexHolders[1]); - mIndexHolders[2] = new iggWidgetKeyColorSelection(iImageComposer::KeyForegroundWindowBorderColor(),b,true,0); + iggWidgetKeyColorSelection *cs = new iggWidgetKeyColorSelection(iImageComposer::KeyForegroundWindowBorderColor(),b,0); + cs->SetText("Set"); + mIndexHolders[2] = cs; mIndexHolders[2]->AddDependent(mArea); b->AddLine(new iggWidgetTextArea("Border color",b),mIndexHolders[2]); psb = new PseudoColorBox(false,this,b); @@ -1080,6 +1091,14 @@ } +iggWidget* iggDialogImageComposer::GetArea() +{ + this->CompleteConstruction(); + + return mArea; +} + + iImageComposer* iggDialogImageComposer::GetImageComposer() const { return this->GetShell()->GetControlModule()->GetImageComposer(); diff -Nru ifrit-3.3.4/shells/generic/iggdialogimagecomposer.h ifrit-3.4.2/shells/generic/iggdialogimagecomposer.h --- ifrit-3.3.4/shells/generic/iggdialogimagecomposer.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogimagecomposer.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -57,10 +57,12 @@ void UpdateView(); void UpdateZooms(); - iggWidget* GetArea() const { return mArea; } + iggWidget* GetArea(); protected: + virtual void CompleteConstructionBody(); + int mCurrentBackgroundWindow, mCurrentForegroundWindow; iggWidget *mArea, *mLabel, *mBackgroundWindowsList; diff -Nru ifrit-3.3.4/shells/generic/iggdialogloadfile.cpp ifrit-3.4.2/shells/generic/iggdialogloadfile.cpp --- ifrit-3.3.4/shells/generic/iggdialogloadfile.cpp 2011-01-27 17:52:23.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogloadfile.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -82,6 +82,12 @@ // iggDialogLoadFile::iggDialogLoadFile(iggMainWindow *parent) : iggDialog(parent,mIsMultiThread?0U:DialogFlag::Blocking,0,"Loading file...",0,2,"Abort") { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogLoadFile::CompleteConstructionBody() +{ mProgressBar = new ProgressBar(mFrame); mLabel = new iggWidgetTextArea("",mFrame); @@ -114,6 +120,8 @@ if(this->GetShell()->GetControlModule()->GetViewModule(mod)->IsClone()) return; + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + mLabel->SetText(filename); iggDialog::Show(true); @@ -155,12 +163,4 @@ return true; } - -void iggDialogLoadFile::Show(bool) -{ - // - // This dialog is showed/hidden automatically - // -} - #endif diff -Nru ifrit-3.3.4/shells/generic/iggdialogloadfile.h ifrit-3.4.2/shells/generic/iggdialogloadfile.h --- ifrit-3.3.4/shells/generic/iggdialogloadfile.h 2011-01-27 17:52:12.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogloadfile.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -53,10 +53,9 @@ void LoadData(const iDataInfo &info, const iString &filename, int mod); void ReloadData(const iDataInfo &info); - virtual void Show(bool s); - protected: + virtual void CompleteConstructionBody(); virtual bool CanBeClosed(); iggWidgetTextArea *mLabel; diff -Nru ifrit-3.3.4/shells/generic/iggdialogpaletteeditor.cpp ifrit-3.4.2/shells/generic/iggdialogpaletteeditor.cpp --- ifrit-3.3.4/shells/generic/iggdialogpaletteeditor.cpp 2011-01-27 17:52:23.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogpaletteeditor.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -267,7 +267,7 @@ NameLineEdit(iggDialogPaletteEditor *dialog, iggFrame *parent) : iggWidget(parent) { mDialog = dialog; - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"Name",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"Name"); this->SetBaloonHelp("Set the name","Change the name of the current palette. The new name may contain white spaces but should not contain symbols '*'."); } @@ -333,10 +333,16 @@ iggDialogPaletteEditor::iggDialogPaletteEditor(iggMainWindow *parent) : iggDialog(parent,0U,iImageFactory::FindIcon("paled.png"),"Palette Editor","sr.gg.de",2) { - mCurrentPalette = new iPalette; + mCurrentPalette = new iPalette; IERROR_ASSERT(mCurrentPalette); mCurrentPalette->Copy(iPaletteSet::Default()->GetPalette(0)); mCurrentPaletteIndex = 0; + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogPaletteEditor::CompleteConstructionBody() +{ iggFrame *cpb = new iggFrame(mFrame,2); PaletteSelection *ps = new PaletteSelection(this,cpb); cpb->AddLine(ps); @@ -388,7 +394,7 @@ iggDialogPaletteEditor::~iggDialogPaletteEditor() { - delete mCurrentPalette; + if(mCurrentPalette != 0) delete mCurrentPalette; } @@ -401,6 +407,7 @@ void iggDialogPaletteEditor::SetChanged(bool s) { + this->CompleteConstruction(); mApplyButton->Enable(s); } @@ -409,6 +416,7 @@ { if(n>=0 && nGetNumberOfPalettes()) { + this->CompleteConstruction(); if(mApplyButton->IsEnabled()) this->Apply(true); mCurrentPalette->Copy(iPaletteSet::Default()->GetPalette(n)); mCurrentPaletteIndex = n; @@ -419,6 +427,7 @@ void iggDialogPaletteEditor::Apply(bool ask) { + this->CompleteConstruction(); if(mApplyButton->IsEnabled() && (!ask || this->GetMainWindow()->AskForConfirmation("Do you want to apply changes?","Apply"))) { iPaletteSet::Default()->GetPalette(mCurrentPaletteIndex)->Copy(mCurrentPalette); diff -Nru ifrit-3.3.4/shells/generic/iggdialogpaletteeditor.h ifrit-3.4.2/shells/generic/iggdialogpaletteeditor.h --- ifrit-3.3.4/shells/generic/iggdialogpaletteeditor.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogpaletteeditor.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -57,6 +57,7 @@ protected: + virtual void CompleteConstructionBody(); virtual bool CanBeClosed(); int mCurrentPaletteIndex; diff -Nru ifrit-3.3.4/shells/generic/iggdialogparallelcontroller.cpp ifrit-3.4.2/shells/generic/iggdialogparallelcontroller.cpp --- ifrit-3.3.4/shells/generic/iggdialogparallelcontroller.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogparallelcontroller.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -190,6 +190,12 @@ iggDialogParallelController::iggDialogParallelController(iggMainWindow *mw) : iggDialog(mw,0U,iImageFactory::FindIcon("parallel.png"),"Parallel Controller","sr.gg.dp",3) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogParallelController::CompleteConstructionBody() +{ iggFrame *q = new iggFrame(mFrame,2); q->AddLine(new NumProcs(q)); q->SetColStretch(0,0); diff -Nru ifrit-3.3.4/shells/generic/iggdialogparallelcontroller.h ifrit-3.4.2/shells/generic/iggdialogparallelcontroller.h --- ifrit-3.3.4/shells/generic/iggdialogparallelcontroller.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogparallelcontroller.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -47,6 +47,7 @@ protected: + virtual void CompleteConstructionBody(); iggWidget *mDisplay; }; diff -Nru ifrit-3.3.4/shells/generic/iggdialogperformancemeter.cpp ifrit-3.4.2/shells/generic/iggdialogperformancemeter.cpp --- ifrit-3.3.4/shells/generic/iggdialogperformancemeter.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogperformancemeter.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -147,6 +147,12 @@ iggDialogPerformanceMeter::iggDialogPerformanceMeter(iggMainWindow *parent) : iggDialog(parent,0U,iImageFactory::FindIcon("perf.png"),"Performance Meter",0,7) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogPerformanceMeter::CompleteConstructionBody() +{ iggWidgetNumberDisplay *tm = new iggWidgetNumberDisplay("",mFrame); tm->Display(iSystem::GetMemoryLimit(),1); diff -Nru ifrit-3.3.4/shells/generic/iggdialogperformancemeter.h ifrit-3.4.2/shells/generic/iggdialogperformancemeter.h --- ifrit-3.3.4/shells/generic/iggdialogperformancemeter.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogperformancemeter.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -41,6 +41,10 @@ iggDialogPerformanceMeter(iggMainWindow *parent); virtual const iString& GetToolTip() const; + +protected: + + virtual void CompleteConstructionBody(); }; #endif // IGGDIALOGPERFORMANCEMETER_H diff -Nru ifrit-3.3.4/shells/generic/iggdialogpickerwindow.cpp ifrit-3.4.2/shells/generic/iggdialogpickerwindow.cpp --- ifrit-3.3.4/shells/generic/iggdialogpickerwindow.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogpickerwindow.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -117,6 +117,12 @@ iggDialogPickerWindow::iggDialogPickerWindow(iggMainWindow *parent) : iggDialog(parent,0U,iImageFactory::FindIcon("picks.png"),"Picker Window","sr.gg.dk",1) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogPickerWindow::CompleteConstructionBody() +{ mWaitFrame = new iggFrame(mFrame); mWaitFrame->AddLine(new iggWidgetTextArea("Please wait, the data are being gathered...",mWaitFrame)); mWaitFrame->Show(false); @@ -146,19 +152,21 @@ } -void iggDialogPickerWindow::Show(bool s) +void iggDialogPickerWindow::ShowBody(bool s) { int i; for(i=0; iGetShell()->GetControlModule()->GetNumberOfViewModules(); i++) { this->GetShell()->GetControlModule()->GetViewModule(i)->GetPicker()->ShowPickedPoint(s); } - iggDialog::Show(s); + iggDialog::ShowBody(s); } void iggDialogPickerWindow::CollectData(bool s) { + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + mWaitFrame->Show(s); mInfoFrame->Show(!s); } @@ -166,6 +174,8 @@ void iggDialogPickerWindow::DisplayData(const iPicker *picker) { + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + mInfo->Clear(); if(picker!=0 && !picker->GetObjectName().IsEmpty()) diff -Nru ifrit-3.3.4/shells/generic/iggdialogpickerwindow.h ifrit-3.4.2/shells/generic/iggdialogpickerwindow.h --- ifrit-3.3.4/shells/generic/iggdialogpickerwindow.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogpickerwindow.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -46,13 +46,14 @@ iggDialogPickerWindow(iggMainWindow *parent); - virtual void Show(bool s); - void CollectData(bool s); void DisplayData(const iPicker *picker); protected: + virtual void CompleteConstructionBody(); + virtual void ShowBody(bool s); + iggFrame *mInfoFrame, *mWaitFrame; iggWidgetTextBrowser *mInfo; }; diff -Nru ifrit-3.3.4/shells/generic/iggdialogrenderingprogress.cpp ifrit-3.4.2/shells/generic/iggdialogrenderingprogress.cpp --- ifrit-3.3.4/shells/generic/iggdialogrenderingprogress.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogrenderingprogress.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -86,6 +86,16 @@ mBlockParent = true; // no explicit blocking required, since it is a semi-modal dialog mIsParentBlocked = false; + mCancelled = true; + mPreviousTime = 0.0; + mTimer = vtkTimerLog::New(); IERROR_ASSERT(mTimer); + + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogRenderingProgress::CompleteConstructionBody() +{ iggFrame*tmp; mFrame->AddLine(new iggWidgetTextArea("%bRendering the scene...",mFrame)); @@ -107,10 +117,6 @@ mRemarkFrame = new iggFrame(mFrame); mRemarkFrame->AddLine(new iggWidgetTextArea("Interrupting all processes...",mRemarkFrame)); mFrame->AddLine(mRemarkFrame); - - mCancelled = true; - mPreviousTime = 0.0; - mTimer = vtkTimerLog::New(); IERROR_ASSERT(mTimer); } @@ -122,6 +128,8 @@ void iggDialogRenderingProgress::Start(bool interactive) { + if(!mCompleteConstructionCalled) this->CompleteConstruction(); + mTimer->StartTimer(); mCancelled = false; mPreviousTime = 0.0; diff -Nru ifrit-3.3.4/shells/generic/iggdialogrenderingprogress.h ifrit-3.4.2/shells/generic/iggdialogrenderingprogress.h --- ifrit-3.3.4/shells/generic/iggdialogrenderingprogress.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogrenderingprogress.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -57,6 +57,7 @@ protected: + virtual void CompleteConstructionBody(); virtual bool CanBeClosed(); bool mBlockParent, mIsParentBlocked, mCancelled, mInteractive; diff -Nru ifrit-3.3.4/shells/generic/iggdialogscriptdebugger.cpp ifrit-3.4.2/shells/generic/iggdialogscriptdebugger.cpp --- ifrit-3.3.4/shells/generic/iggdialogscriptdebugger.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogscriptdebugger.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -49,6 +49,7 @@ #include "iggdialoghelp.h" #include "iggframetopparent.h" #include "iggmainwindow.h" +#include "iggshell.h" #include "iggwidgetmisc.h" #include "iggwidgetotherbutton.h" #include "iggwidgettext.h" @@ -277,7 +278,7 @@ FindText(iggFrame *parent) : iggWidget(parent) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"Find:",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"Find:"); this->SetBaloonHelp("Type a string to find"); } @@ -357,6 +358,14 @@ mFrame->AddLine(cs); mFrame->AddLine(wo); mFrame->AddLine(bs); + + this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { } }; @@ -428,7 +437,7 @@ { mDebugger = d; - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,"Delay",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,"Delay"); mSubject->SetRange(0,10); mSubject->SetValue(3); @@ -538,8 +547,6 @@ // iggDialogScriptDebugger::iggDialogScriptDebugger(iggMainWindow *parent) : iggMenuWindow(parent), iScriptObserver(0) { - int i; - // // Create MenuSubject // @@ -551,8 +558,21 @@ mCurIter = -1; mNumIter = 0; mDebugFlag = 1; + + mTimer = 0; + mFindDialog = 0; + mEditor = 0; mFirstShow = true; + mCompleteConstructionCalled = false; + + if(this->ImmediateConstruction()) this->CompleteConstruction(); +} + + +void iggDialogScriptDebugger::CompleteConstructionBody() +{ + int i; // // Top frame @@ -628,9 +648,9 @@ iggDialogScriptDebugger::~iggDialogScriptDebugger() { - mTimer->Delete(); + if(mTimer != 0) mTimer->Delete(); this->CheckModified(); - delete mFindDialog; + if(mFindDialog != 0) delete mFindDialog; } @@ -639,6 +659,12 @@ if(s && mFirstShow) { mFirstShow = false; + + if(!mCompleteConstructionCalled) + { + this->CompleteConstruction(); + } + int wg1[4], wg2[4]; this->GetMainWindow()->GetSubject()->GetWindowGeometry(wg1); this->GetSubject()->GetWindowGeometry(wg2); @@ -687,7 +713,6 @@ this->GetAnimator()->SetDebugFlag(mDebugFlag); // make sure we are current this->SetScript(this->GetAnimator()->GetScript()); mRunState = _RunStatePaused; - this->GetAnimator()->SetUseScript(true); this->GetAnimator()->Start(); this->UpdateVariables(); mEditor->MarkLine(this->GetAnimator()->GetScript()); @@ -815,7 +840,7 @@ iAnimatorScript *s = this->GetAnimator()->GetScript(); if(!s->Compile()) { - this->GetMainWindow()->PopupWindow(mGlobalFrame,iString("Syntax error: line ")+iString::FromNumber(s->GetThisLine()+1)+"\n"+s->GetErrorStatus()->Message(),PopupWindow::Error); + this->GetMainWindow()->PopupWindow(mGlobalFrame,iString("Syntax error: line ")+iString::FromNumber(s->GetErrorLine()+1)+"\n"+s->GetErrorStatus()->Message(),PopupWindow::Error); mEditor->ShowError(s); return false; } @@ -884,6 +909,8 @@ void iggDialogScriptDebugger::UpdateContents() { + if(!mCompleteConstructionCalled) return; + mGlobalFrame->UpdateWidget(); this->UpdateButtons(); } @@ -891,7 +918,7 @@ void iggDialogScriptDebugger::CheckModified() { - if(mEditor->TextModified()) + if(mEditor!=0 && mEditor->TextModified()) { switch(mMainWindow->PopupWindow(mGlobalFrame,"The current script is not saved.",PopupWindow::Warning,"Save","Ignore")) { @@ -960,7 +987,7 @@ this->SetContents(text); mCurrentFileName = fn; - this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->SetScriptFileName(fn); + this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->SetScriptFile(fn); } @@ -1222,4 +1249,22 @@ IERROR_LOW("Invalid menu item id."); } + +bool iggDialogScriptDebugger::ImmediateConstruction() const +{ + return iRequiredCast(INFO,this->GetShell())->CheckCondition(iParameter::Condition::DisableDelayedInitialization); +} + + +void iggDialogScriptDebugger::CompleteConstruction() +{ + if(mCompleteConstructionCalled) return; + + this->CompleteConstructionBody(); + mCompleteConstructionCalled = true; +#ifdef I_DEBUG + iConsole::PrintDebugMessage(iString("Completing delayed construction for element #")+iString::FromNumber(this->GetId())); +#endif +} + #endif diff -Nru ifrit-3.3.4/shells/generic/iggdialogscriptdebugger.h ifrit-3.4.2/shells/generic/iggdialogscriptdebugger.h --- ifrit-3.3.4/shells/generic/iggdialogscriptdebugger.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggdialogscriptdebugger.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -71,6 +71,10 @@ protected: + bool ImmediateConstruction() const; + void CompleteConstruction(); + virtual void CompleteConstructionBody(); + virtual void UpdateContents(); virtual void OnScriptStartBody(); @@ -93,6 +97,7 @@ iggWidgetListView *mVarView; iggDialog *mFindDialog; + bool mCompleteConstructionCalled; int mRunState, mCurIter, mNumIter, mDebugFlag; float mDelayTime; bool mDebugging, mAllowFrameStep, mInsideALine, mFirstShow; diff -Nru ifrit-3.3.4/shells/generic/iggelement.cpp ifrit-3.4.2/shells/generic/iggelement.cpp --- ifrit-3.3.4/shells/generic/iggelement.cpp 2011-01-27 17:52:24.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggelement.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggelement.h ifrit-3.4.2/shells/generic/iggelement.h --- ifrit-3.3.4/shells/generic/iggelement.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggelement.h 2013-07-11 01:23:51.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -60,9 +60,10 @@ // // Running conditions // - const int OldWindowManager = 1; - const int SmallDesktopSize = 2; - const int SlowRemoteConnection = 4; + const int OldWindowManager = 1; + const int SmallDesktopSize = 2; + const int SlowRemoteConnection = 4; + const int DisableDelayedInitialization = 8; }; }; @@ -77,6 +78,7 @@ virtual ~iggElement(); + int GetId() const { return mId; } protected: diff -Nru ifrit-3.3.4/shells/generic/iggextensionwindow.cpp ifrit-3.4.2/shells/generic/iggextensionwindow.cpp --- ifrit-3.3.4/shells/generic/iggextensionwindow.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggextensionwindow.cpp 2013-07-11 01:23:57.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggextensionwindow.h ifrit-3.4.2/shells/generic/iggextensionwindow.h --- ifrit-3.3.4/shells/generic/iggextensionwindow.h 2011-01-27 17:52:13.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggextensionwindow.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframe.cpp ifrit-3.4.2/shells/generic/iggframe.cpp --- ifrit-3.3.4/shells/generic/iggframe.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframe.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -38,6 +38,7 @@ #include "iggmainwindow.h" #include "iggrenderwindowobserver.h" +#include "iggshell.h" #include "iggwidget.h" #include "ibgframesubject.h" @@ -295,6 +296,12 @@ } +bool iggFrame::NeedsRedoLayout() +{ + return false; +} + + void iggFrame::GetFrameGeometry(int wg[4]) const { mSubject->GetFrameGeometry(wg); @@ -425,6 +432,47 @@ // +// A frame with delayed construction. +// +iggFrameDC::iggFrameDC(iggFrameBase *parent, int cols) : iggFrame(parent,cols) +{ + mCompleteConstructionCalled = false; +} + + +bool iggFrameDC::ImmediateConstruction() const +{ + return iRequiredCast(INFO,this->GetShell())->CheckCondition(iParameter::Condition::DisableDelayedInitialization); +} + + +bool iggFrameDC::NeedsRedoLayout() +{ + if(mCompleteConstructionCalled) + { + return false; + } + else + { + this->CompleteConstruction(); + return true; + } +} + + +void iggFrameDC::CompleteConstruction() +{ + if(mCompleteConstructionCalled) return; + + this->CompleteConstructionBody(); + mCompleteConstructionCalled = true; +#ifdef I_DEBUG + iConsole::PrintDebugMessage(iString("Completing delayed construction for element #")+iString::FromNumber(this->GetId())); +#endif +} + + +// // FrameBook class // iggFrameBook::iggFrameBook(iggFrameBase *parent, bool withFeedback, int orientation) : iggFrameBase(parent) diff -Nru ifrit-3.3.4/shells/generic/iggframe.h ifrit-3.4.2/shells/generic/iggframe.h --- ifrit-3.3.4/shells/generic/iggframe.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframe.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -162,6 +162,8 @@ protected: + virtual bool NeedsRedoLayout(); + int mCurCol, mCurRow; ibgFrameSubject *mSubject; @@ -173,6 +175,28 @@ // +// A frame with delayed construction. +// +class iggFrameDC : public iggFrame +{ + +public: + + iggFrameDC(iggFrameBase *parent, int cols = 1); + +protected: + + virtual bool NeedsRedoLayout(); + + bool ImmediateConstruction() const; + void CompleteConstruction(); + virtual void CompleteConstructionBody() = 0; + + bool mCompleteConstructionCalled; +}; + + +// // A generic Book frame (TabBook, TabWidget). // class iggFrameBook : public iggFrameBase diff -Nru ifrit-3.3.4/shells/generic/iggframeattachposition.cpp ifrit-3.4.2/shells/generic/iggframeattachposition.cpp --- ifrit-3.3.4/shells/generic/iggframeattachposition.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeattachposition.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeattachposition.h ifrit-3.4.2/shells/generic/iggframeattachposition.h --- ifrit-3.3.4/shells/generic/iggframeattachposition.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeattachposition.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeboxsize.cpp ifrit-3.4.2/shells/generic/iggframeboxsize.cpp --- ifrit-3.3.4/shells/generic/iggframeboxsize.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeboxsize.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeboxsize.h ifrit-3.4.2/shells/generic/iggframeboxsize.h --- ifrit-3.3.4/shells/generic/iggframeboxsize.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeboxsize.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframecurrentinstance.cpp ifrit-3.4.2/shells/generic/iggframecurrentinstance.cpp --- ifrit-3.3.4/shells/generic/iggframecurrentinstance.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframecurrentinstance.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframecurrentinstance.h ifrit-3.4.2/shells/generic/iggframecurrentinstance.h --- ifrit-3.3.4/shells/generic/iggframecurrentinstance.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframecurrentinstance.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatatypeselector.cpp ifrit-3.4.2/shells/generic/iggframedatatypeselector.cpp --- ifrit-3.3.4/shells/generic/iggframedatatypeselector.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatatypeselector.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatatypeselector.h ifrit-3.4.2/shells/generic/iggframedatatypeselector.h --- ifrit-3.3.4/shells/generic/iggframedatatypeselector.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatatypeselector.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatatypewidgetlist.cpp ifrit-3.4.2/shells/generic/iggframedatatypewidgetlist.cpp --- ifrit-3.3.4/shells/generic/iggframedatatypewidgetlist.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatatypewidgetlist.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatatypewidgetlist.h ifrit-3.4.2/shells/generic/iggframedatatypewidgetlist.h --- ifrit-3.3.4/shells/generic/iggframedatatypewidgetlist.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatatypewidgetlist.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatavariablelist.cpp ifrit-3.4.2/shells/generic/iggframedatavariablelist.cpp --- ifrit-3.3.4/shells/generic/iggframedatavariablelist.cpp 2011-01-27 17:52:25.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatavariablelist.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedatavariablelist.h ifrit-3.4.2/shells/generic/iggframedatavariablelist.h --- ifrit-3.3.4/shells/generic/iggframedatavariablelist.h 2011-01-27 17:52:14.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedatavariablelist.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedoublebutton.cpp ifrit-3.4.2/shells/generic/iggframedoublebutton.cpp --- ifrit-3.3.4/shells/generic/iggframedoublebutton.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedoublebutton.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframedoublebutton.h ifrit-3.4.2/shells/generic/iggframedoublebutton.h --- ifrit-3.3.4/shells/generic/iggframedoublebutton.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframedoublebutton.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframefunctionmapping.cpp ifrit-3.4.2/shells/generic/iggframefunctionmapping.cpp --- ifrit-3.3.4/shells/generic/iggframefunctionmapping.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframefunctionmapping.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframefunctionmapping.h ifrit-3.4.2/shells/generic/iggframefunctionmapping.h --- ifrit-3.3.4/shells/generic/iggframefunctionmapping.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframefunctionmapping.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframehistogramareaextra.cpp ifrit-3.4.2/shells/generic/iggframehistogramareaextra.cpp --- ifrit-3.3.4/shells/generic/iggframehistogramareaextra.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframehistogramareaextra.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframehistogramareaextra.h ifrit-3.4.2/shells/generic/iggframehistogramareaextra.h --- ifrit-3.3.4/shells/generic/iggframehistogramareaextra.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframehistogramareaextra.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframematerialproperties.cpp ifrit-3.4.2/shells/generic/iggframematerialproperties.cpp --- ifrit-3.3.4/shells/generic/iggframematerialproperties.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframematerialproperties.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframematerialproperties.h ifrit-3.4.2/shells/generic/iggframematerialproperties.h --- ifrit-3.3.4/shells/generic/iggframematerialproperties.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframematerialproperties.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeobjectcontrols.cpp ifrit-3.4.2/shells/generic/iggframeobjectcontrols.cpp --- ifrit-3.3.4/shells/generic/iggframeobjectcontrols.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeobjectcontrols.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeobjectcontrols.h ifrit-3.4.2/shells/generic/iggframeobjectcontrols.h --- ifrit-3.3.4/shells/generic/iggframeobjectcontrols.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeobjectcontrols.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepaletteselection.cpp ifrit-3.4.2/shells/generic/iggframepaletteselection.cpp --- ifrit-3.3.4/shells/generic/iggframepaletteselection.cpp 2011-01-27 17:52:26.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepaletteselection.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepaletteselection.h ifrit-3.4.2/shells/generic/iggframepaletteselection.h --- ifrit-3.3.4/shells/generic/iggframepaletteselection.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepaletteselection.h 2013-07-11 01:23:52.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepaletteselectionbase.cpp ifrit-3.4.2/shells/generic/iggframepaletteselectionbase.cpp --- ifrit-3.3.4/shells/generic/iggframepaletteselectionbase.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepaletteselectionbase.cpp 2013-07-11 01:23:58.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepaletteselectionbase.h ifrit-3.4.2/shells/generic/iggframepaletteselectionbase.h --- ifrit-3.3.4/shells/generic/iggframepaletteselectionbase.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepaletteselectionbase.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepiecewisefunctioncontrols.cpp ifrit-3.4.2/shells/generic/iggframepiecewisefunctioncontrols.cpp --- ifrit-3.3.4/shells/generic/iggframepiecewisefunctioncontrols.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepiecewisefunctioncontrols.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepiecewisefunctioncontrols.h ifrit-3.4.2/shells/generic/iggframepiecewisefunctioncontrols.h --- ifrit-3.3.4/shells/generic/iggframepiecewisefunctioncontrols.h 2011-01-27 17:52:15.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepiecewisefunctioncontrols.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeposition.cpp ifrit-3.4.2/shells/generic/iggframeposition.cpp --- ifrit-3.3.4/shells/generic/iggframeposition.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeposition.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframeposition.h ifrit-3.4.2/shells/generic/iggframeposition.h --- ifrit-3.3.4/shells/generic/iggframeposition.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframeposition.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepushcontrols.cpp ifrit-3.4.2/shells/generic/iggframepushcontrols.cpp --- ifrit-3.3.4/shells/generic/iggframepushcontrols.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepushcontrols.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframepushcontrols.h ifrit-3.4.2/shells/generic/iggframepushcontrols.h --- ifrit-3.3.4/shells/generic/iggframepushcontrols.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframepushcontrols.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframerangemapping.cpp ifrit-3.4.2/shells/generic/iggframerangemapping.cpp --- ifrit-3.3.4/shells/generic/iggframerangemapping.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframerangemapping.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -211,7 +211,7 @@ HistogramSlider(iggFrame *parent) : iggWidget(parent) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,"",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,0,""); mSubject->SetRange(-10,10); mSubject->SetValue(0); diff -Nru ifrit-3.3.4/shells/generic/iggframerangemapping.h ifrit-3.4.2/shells/generic/iggframerangemapping.h --- ifrit-3.3.4/shells/generic/iggframerangemapping.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframerangemapping.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframereplicate.cpp ifrit-3.4.2/shells/generic/iggframereplicate.cpp --- ifrit-3.3.4/shells/generic/iggframereplicate.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframereplicate.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframereplicate.h ifrit-3.4.2/shells/generic/iggframereplicate.h --- ifrit-3.3.4/shells/generic/iggframereplicate.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframereplicate.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframetopparent.cpp ifrit-3.4.2/shells/generic/iggframetopparent.cpp --- ifrit-3.3.4/shells/generic/iggframetopparent.cpp 2011-01-27 17:52:27.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframetopparent.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggframetopparent.h ifrit-3.4.2/shells/generic/iggframetopparent.h --- ifrit-3.3.4/shells/generic/iggframetopparent.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggframetopparent.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggmainwindow.cpp ifrit-3.4.2/shells/generic/iggmainwindow.cpp --- ifrit-3.3.4/shells/generic/iggmainwindow.cpp 2011-01-27 17:52:28.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggmainwindow.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -276,8 +276,9 @@ namespace ToolBar { const int OpenWindowsPage = 801; - const int MinimizeWindowsPage = 802; - const int MaximizeWindowsPage = 803; + const int MinimizeWindows = 802; + const int MaximizeWindows = 803; + const int MoveAllTogether = 804; const int ShowSurface = 901; const int ShowCrossSection = 902; @@ -610,6 +611,11 @@ DialogAbout(iggMainWindow *parent) : iggDialog(parent,DialogFlag::Modal,0,"About",0,3,"Ok") { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { int i, n; iString s; @@ -646,13 +652,12 @@ n = s.Contains(';'); for(i=0; iAddLine(new iggWidgetTextArea(s.Section(";",i,i),mFrame),3); mFrame->AddLine(new iggWidgetTextArea("",mFrame),3); - mFrame->AddLine(new iggWidgetTextArea("IFrIT is created and maintained by Nick Gnedin",mFrame),3); } - virtual void Show(bool s) + virtual void ShowBody(bool s) { if(s) mFlipper->Start(); else mFlipper->Abort(); - iggDialog::Show(s); + iggDialog::ShowBody(s); } protected: @@ -668,15 +673,20 @@ DialogDocking(iggMainWindow *parent) : iggDialog(parent,DialogFlag::Blocking|DialogFlag::NoTitleBar,0,"Docking...",0,3,0) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mFlipper = new iggWidgetLogoFlipper(mFrame); mFrame->AddLine(0,mFlipper); mFrame->AddLine(new iggWidgetTextArea("%b%+Rearranging windows...",mFrame),3); } - virtual void Show(bool s) + virtual void ShowBody(bool s) { if(s) mFlipper->Start(); else mFlipper->Abort(); - iggDialog::Show(s); + iggDialog::ShowBody(s); } protected: @@ -695,6 +705,11 @@ AxesLabelsDialog(iggMainWindow *parent) : iggDialogAuto(parent,"Axes Labels",3) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mFrame->AddLine(new iggWidgetKeyTextLineEdit(false,"X: Label",iViewModule::KeyAxesBoxLabels(),RenderMode::UseGlobal,mFrame,0),new iggWidgetKeyFloatLineEdit("Min",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,0),new iggWidgetKeyFloatLineEdit("Max",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,1)); mFrame->AddLine(new iggWidgetKeyTextLineEdit(false,"Y: Label",iViewModule::KeyAxesBoxLabels(),RenderMode::UseGlobal,mFrame,1),new iggWidgetKeyFloatLineEdit("Min",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,2),new iggWidgetKeyFloatLineEdit("Max",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,3)); mFrame->AddLine(new iggWidgetKeyTextLineEdit(false,"Z: Label",iViewModule::KeyAxesBoxLabels(),RenderMode::UseGlobal,mFrame,2),new iggWidgetKeyFloatLineEdit("Min",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,4),new iggWidgetKeyFloatLineEdit("Max",iViewModule::KeyAxesBoxRanges(),RenderMode::UseGlobal,mFrame,5)); @@ -777,6 +792,26 @@ iggFrame *mStartFrame; }; + class DebugHelperFlashAllDialogsButton : public iggWidgetSimpleButton + { + + public: + + DebugHelperFlashAllDialogsButton(iggFrame *parent) : iggWidgetSimpleButton("Flash all dialogs",parent) + { + mNeedsBaloonHelp = false; + } + + protected: + + virtual void Execute() + { + this->GetMainWindow()->Block(true); + iggDialog::FlashAllDialogs(); + this->GetMainWindow()->Block(false); + } + }; + class DebugHelperCreateUGButton : public iggWidgetSimpleButton { @@ -792,7 +827,7 @@ virtual void Execute() { this->GetMainWindow()->Block(true); - iHelpFactory::CreateUserGuide(iHelpFactory::_Publish); + iHelpFactory::CreateUserGuide(); this->GetMainWindow()->Block(false); } }; @@ -839,12 +874,24 @@ DebugHelperDialog(iggFrame *sf, iggMainWindow *parent) : iggDialog(parent,0U,0,"Debug Helper",0,1) { + mStartFrame = sf; + + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + void CompleteConstructionBody() + { mFrame->AddLine(new DebugHelperParallelRadioBox(mFrame)); mFrame->AddLine(new DebugHelperEmphasizeAllWidgetsCheckBox(mFrame)); mFrame->AddLine(new DebugHelperEmphasizeUnderCursorCheckBox(mFrame)); - mFrame->AddLine(new DebugHelperFlipAllPagesButton(sf,mFrame)); + mFrame->AddLine(new DebugHelperFlipAllPagesButton(mStartFrame,mFrame)); + mFrame->AddLine(new DebugHelperFlashAllDialogsButton(mFrame)); mFrame->AddLine(new DebugHelperCreateUGButton(mFrame)); } + + iggFrame *mStartFrame; }; #endif }; @@ -862,7 +909,7 @@ // iggMainWindow::iggMainWindow(iShell *shell) : iObject("MainWindow"), iggMenuWindow(shell), mReloadDataInfo(new iDataInfo), mEraseDataInfo(new iDataInfo) { - mInitialized = mDocked = mDoNotOfferToReload = mDetailLoadedDataInfo = mAllowPrePopulateToolBar = false; + mInitialized = mDocked = mDoNotOfferToReload = mDetailLoadedDataInfo = mAllowPrePopulateToolBar = mMoveTogether = false; mInteractorHelp = mToolTips = mOptionsAreGlobal = mWindowUnderFocusCurrent = mAutoRender = true; mIdiosyncratic = true; @@ -958,7 +1005,6 @@ // iggShell *s = iRequiredCast(INFO,this->GetShell()); - if(s->IsDesktopSmall(true)) mLog->Show(false); if(s->CheckCondition(iParameter::Condition::SlowRemoteConnection)) { ibgRenderWindowSubject::RenderOnFocus = true; @@ -991,7 +1037,6 @@ Book *book = new Book(tmpf); mBook = book; -// iggPage::SetDelayedConstruction(false); mViewPage = new iggPageView(mBook); mDataPage = new iggPageData(mBook); @@ -1001,7 +1046,6 @@ mPages[3] = mParticlesPage = new iggPageParticles(mBook); mPages[4] = new iggPageVectorField(mBook); mPages[5] = new iggPageTensorField(mBook); -// iggPage::SetDelayedConstruction(true); iParticlesViewSubject::UseFullState(false); // optimization, since we use iParticleGroup keys @@ -1033,23 +1077,33 @@ mBaseFrame->ShowLayer(0); mGlobalFrame->AddLine(mBaseFrame,3); - iggFrame *tmp1 = new iggFrame(mGlobalFrame,2); - iggFrame *tmp2 = new iggFrame(mGlobalFrame); - tmp1->AddSpace(10); + + iggFrameFlip *flip1 = new iggFrameFlip(mGlobalFrame,false); + iggFrame *tmp1 = new iggFrame(flip1,3); mRenderButton = new RenderButton(tmp1); mRenderButton->Show(!mAutoRender); tmp1->SetPadding(true); tmp1->AddLine(new ImageButton(tmp1),mRenderButton); - tmp1->AddSpace(10); - mDataTypeFrame = new iggFrameFlip(tmp2,false); - tmp2->AddSpace(10); - tmp2->AddLine(mDataTypeFrame); - tmp2->AddSpace(10); - mGlobalFrame->AddLine(tmp1,new iggWidgetTextArea("",mGlobalFrame),tmp2); + tmp1->SetColStretch(2,10); + flip1->AddLayer(tmp1); + flip1->ShowLayer(0); + + mDataTypeFrame = new iggFrameFlip(mGlobalFrame,false); + + //mGlobalFrame->AddLine(tmp1,new iggWidgetTextArea("",mGlobalFrame),tmp2); + mGlobalFrame->AddLine(flip1,(iggWidget *)0,mDataTypeFrame); mGlobalFrame->AddLine(mLog,3); - mGlobalFrame->SetRowStretch(0,0); + mGlobalFrame->SetRowStretch(0,1); mGlobalFrame->SetRowStretch(1,0); - mGlobalFrame->SetRowStretch(2,1); + if(s->IsDesktopSmall(true)) + { + mLog->Show(false); + mGlobalFrame->SetRowStretch(2,0); + } + else + { + mGlobalFrame->SetRowStretch(2,10); + } book->PolishPages(); @@ -1523,7 +1577,8 @@ mLog->AppendTextLine(prefix,message,color); if(mLog->GetNumberOfLines() > 1000) { - while(mLog->GetNumberOfLines() > 700) mLog->RemoveLine(0); + iString text = mLog->GetText(); + mLog->SetText(text.Part(text.Length()/5)); } } } @@ -1531,11 +1586,14 @@ void iggMainWindow::WriteToLog(const iString &message) { - mLog->AppendTextLine("\t",message); - - if(mLog->GetNumberOfLines() > 1000) + if(mLog != 0) { - while(mLog->GetNumberOfLines() > 700) mLog->RemoveLine(0); + mLog->AppendTextLine("\t",message); + if(mLog->GetNumberOfLines() > 1000) + { + iString text = mLog->GetText(); + mLog->SetText(text.Part(text.Length()/5)); + } } } @@ -1549,8 +1607,14 @@ void iggMainWindow::ShowLog(bool s) { mLog->Show(s); - if(!s) + if(s) + { + mGlobalFrame->SetRowStretch(2,10); + this->ProcessEvents(); + } + else { + mGlobalFrame->SetRowStretch(2,0); this->ProcessEvents(); int wg[4]; @@ -2008,7 +2072,7 @@ } -void iggMainWindow::MoveWindows(int pos[2], bool all) +void iggMainWindow::MoveWindows(int pos[2]) { // // We must make this function safe against multiple concurrent calls. @@ -2020,9 +2084,9 @@ if(mInMove) return; // ignore rapidly arriving events mInMove = true; - int wg[4]; - if(all && mInitialized && !mDocked) // do not move the first render window + if(mMoveTogether && mInitialized && !mDocked) // do not move the first render window { + int wg[4]; int i, dp[2]; dp[0] = pos[0] - mPrevPos[0]; dp[1] = pos[1] - mPrevPos[1]; @@ -2051,7 +2115,7 @@ // if(mNextPos[0]!=pos[0] || mNextPos[1]!=pos[1]) { - this->MoveWindows(mNextPos,all); + this->MoveWindows(mNextPos); } } @@ -2115,7 +2179,7 @@ this->GetSubject()->BeginMenu("Automatic Dialogs",false); { - this->GetSubject()->AddMenuItem(Menu::Dialog::AutoBlock,"Do ¬ launch automatically",0,"",true,iggDialogAuto::mBlockShowing); + this->GetSubject()->AddMenuItem(Menu::Dialog::AutoBlock,"Do not launch automatically",0,"",true,iggDialogAuto::mBlockShowing); int i; iString ws; for(i=0; iGetSubject()->GetShell()->GetControlModule()->GetParallelManager()->GetMaxNumberOfProcessors()>1) this->GetSubject()->AddMenuItem(Menu::Dialog::ParallelController,"Parallel &Controller",iImageFactory::FindIcon("parallel.png"),"Ctrl+C",false,false); if(mDialogDataExplorer != 0) this->GetSubject()->AddMenuItem(Menu::Dialog::DataExplorer,"&Data Explorer",iImageFactory::FindIcon("dataexp.png"),"Ctrl+D",false,false); if(mDialogImageComposer != 0) this->GetSubject()->AddMenuItem(Menu::Dialog::ImageComposer,"&Image Composer",iImageFactory::FindIcon("imcomp.png"),"Ctrl+I",false,false); - if(mDialogCommandLine != 0) this->GetSubject()->AddMenuItem(Menu::Dialog::CommandLine,"&Command Interpreter",iImageFactory::FindIcon("comline.png"),"Ctrl+N",false,false); + if(mDialogCommandLine != 0) this->GetSubject()->AddMenuItem(Menu::Dialog::CommandLine,"Command I&nterpreter",iImageFactory::FindIcon("comline.png"),"Ctrl+N",false,false); mExtensionWindow->PopulateGlobalDialogMenu(); } this->GetSubject()->EndMenu(); @@ -2330,14 +2394,9 @@ mExtensionWindow->PopulateShowToolBar(); this->GetSubject()->AddToolBarSeparator(); this->GetSubject()->AddToolBarButton(ToolBar::OpenWindowsPage,"Switch to page with multiple windows controls",iImageFactory::FindIcon("wins.png"),false); - this->GetSubject()->AddToolBarButton(ToolBar::MinimizeWindowsPage,"Minimize all windows",iImageFactory::FindIcon("minimize.png"),false); - this->GetSubject()->AddToolBarButton(ToolBar::MaximizeWindowsPage,"Restore all windows to normal size",iImageFactory::FindIcon("maximize.png"),false); - - this->GetSubject()->AddToolBarSeparator(); - if(mDialogPickerWindow != 0) this->GetSubject()->AddToolBarButton(Menu::Dialog::PickerWindow,"Open picker window"); - if(mDialogFileSetExplorer != 0) this->GetSubject()->AddToolBarButton(Menu::Dialog::FileSetExplorer,"Open file set explorer window"); - if(mDialogDataExplorer != 0) this->GetSubject()->AddToolBarButton(Menu::Dialog::DataExplorer,"Open data explorer window"); - if(mDialogImageComposer != 0) this->GetSubject()->AddToolBarButton(Menu::Dialog::ImageComposer,"Open image composer window"); + this->GetSubject()->AddToolBarButton(ToolBar::MinimizeWindows,"Minimize all windows",iImageFactory::FindIcon("minimize.png"),false); + this->GetSubject()->AddToolBarButton(ToolBar::MaximizeWindows,"Restore all windows to normal size",iImageFactory::FindIcon("maximize.png"),false); + this->GetSubject()->AddToolBarButton(ToolBar::MoveAllTogether,"Move all windows together",iImageFactory::FindIcon("together.png"),true); } @@ -2501,7 +2560,7 @@ { if(id>=Menu::Dialog::AutoBegin && idForceShow(true); + mAutoDialogList[id-Menu::Dialog::AutoBegin]->ForceShow(on); } else IERROR_LOW("Invalid menu item id."); } @@ -2979,17 +3038,22 @@ mViewPage->GetWindowListDialog()->Show(true); break; } - case ToolBar::MinimizeWindowsPage: + case ToolBar::MinimizeWindows: { this->DisplayWindowsAsIcons(); this->GetSubject()->GetHelper()->ShowAsIcon(); break; } - case ToolBar::MaximizeWindowsPage: + case ToolBar::MaximizeWindows: { this->DisplayWindowsAsWindows(); break; } + case ToolBar::MoveAllTogether: + { + mMoveTogether = on; + break; + } case ToolBar::ShowSurface: { this->GetShell()->GetControlModule()->Show(iSurfaceViewSubject::Type(),on,true); diff -Nru ifrit-3.3.4/shells/generic/iggmainwindow.h ifrit-3.4.2/shells/generic/iggmainwindow.h --- ifrit-3.3.4/shells/generic/iggmainwindow.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggmainwindow.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -215,7 +215,7 @@ // void DisplayWindowsAsIcons(); void DisplayWindowsAsWindows(); - void MoveWindows(int pos[2], bool all); + void MoveWindows(int pos[2]); inline bool IsDocked() const { return mDocked; } inline bool IsAutoRender() const { return mAutoRender; } @@ -309,7 +309,7 @@ int mCurrentTheme, mBlockLevel; iPointerArray mWindowList; iggWidgetProgressBar *mProgressBar; - bool mDocked, mInteractorHelp, mToolTips, mOptionsAreGlobal, mWindowUnderFocusCurrent, mDetailLoadedDataInfo, mAutoRender; + bool mDocked, mInteractorHelp, mToolTips, mOptionsAreGlobal, mWindowUnderFocusCurrent, mDetailLoadedDataInfo, mAutoRender, mMoveTogether; bool mIdiosyncratic, mDoNotOfferToReload, mInitialized, mInMove, mTwoSubjectsAreTheSame, mAllowPrePopulateToolBar; iDataInfo *mReloadDataInfo, *mEraseDataInfo; iString mStateFileName; diff -Nru ifrit-3.3.4/shells/generic/iggmenuwindow.cpp ifrit-3.4.2/shells/generic/iggmenuwindow.cpp --- ifrit-3.3.4/shells/generic/iggmenuwindow.cpp 2011-01-27 17:52:28.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggmenuwindow.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggmenuwindow.h ifrit-3.4.2/shells/generic/iggmenuwindow.h --- ifrit-3.3.4/shells/generic/iggmenuwindow.h 2011-01-27 17:52:16.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggmenuwindow.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpage.cpp ifrit-3.4.2/shells/generic/iggpage.cpp --- ifrit-3.3.4/shells/generic/iggpage.cpp 2011-01-27 17:52:28.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpage.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpage.h ifrit-3.4.2/shells/generic/iggpage.h --- ifrit-3.3.4/shells/generic/iggpage.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpage.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagecrosssection.cpp ifrit-3.4.2/shells/generic/iggpagecrosssection.cpp --- ifrit-3.3.4/shells/generic/iggpagecrosssection.cpp 2011-01-27 17:52:28.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagecrosssection.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -253,7 +253,7 @@ { mButton = button; - mSubject = iggSubjectFactory::CreateWidgetSpinBoxSubject(this,2,1000,"the box in",1); + mSubject = iggSubjectFactory::CreateWidgetSpinBoxSubject(this,2,1000," the box in ",1); mSubject->SetValue(10); this->SetBaloonHelp("Number of steps to scan the box in","Set the number of steps to scan the box with a cross section in."); @@ -294,154 +294,249 @@ this->GetShell()->GetControlModule()->GetViewModule()->Render(); } }; -}; - - -using namespace iggPageCrossSection_Private; -iggPageCrossSection::iggPageCrossSection(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::CrossSection) -{ - const iImage *icon = iImageFactory::FindIcon("xsec.png"); - // // Main page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,3); - mBook->AddPage("Main",icon,page0); - // - // Show - // - iggWidget *show = new iggWidgetShowButton(iCrossSectionViewSubject::Type(),page0); - iggFrameCurrentInstance *ci1 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeyCrossSectionCurrent(),iViewModule::KeyCrossSectionMax(),page0); - ci1->AddDependent(this); - page0->AddLine(show,static_cast(0),ci1); - page0->AddSpace(2); - // - // Paint with and Direction - // - iggFrame *pf = new iggFrame(page0,2); - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iCrossSectionViewSubject::KeyVar(),0,pf,0); - pl->Complete(); - pl->AddDependent(show); - iggWidgetKeyRadioBox *cd = new iggWidgetKeyRadioBox(1,"Direction",0,iCrossSectionViewSubject::KeyDir(),pf); - cd->InsertItem("X"); - cd->InsertItem("Y"); - cd->InsertItem("Z"); - pf->AddLine(pl,cd); - page0->AddLine(pf); - page0->AddSpace(2); - // - // Method - // - iggFrame *mf = new iggFrame(page0,2); - iggWidgetKeyRadioBox *cm = new iggWidgetKeyRadioBox(1,"Method",0,iCrossSectionViewSubject::KeyMethod(),mf); - cm->InsertItem("Polygons"); - cm->InsertItem("Textures"); - mf->AddLine(cm,new iggWidgetKeyCheckBox("Interpolate data",iCrossSectionViewSubject::KeyInterpolateData(),mf)); - page0->AddLine(mf); - page0->AddSpace(10); - // - // Position - // - PositionSlider *cp = new PositionSlider(page0); - DownsampleCheckBox *dc = new DownsampleCheckBox(page0); - cp->SetDownsampleBuddy(dc); - page0->AddLine(cp,2); - page0->AddLine(dc); - - page0->AddSpace(2); - page0->AddLine(new iggFrameAttachPosition(cp,iCrossSectionViewSubject::KeyAttachToMarker(),"",page0,true),1); - page0->AddLine(new OrthogonalizeViewButton(page0)); + class MainPage : public iggFrameDC + { + + public: + + MainPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,3), mProvider(provider), mSlider(0) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + PositionSlider* Slider() const { return mSlider; } + + protected: + + iggDataTypeProvider *mProvider; + PositionSlider *mSlider; - page0->AddSpace(10); + virtual void CompleteConstructionBody() + { + // + // Show + // + iggWidget *show = new iggWidgetShowButton(iCrossSectionViewSubject::Type(),this); + iggFrameCurrentInstance *ci1 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeyCrossSectionCurrent(),iViewModule::KeyCrossSectionMax(),this); + ci1->AddDependent(this); + this->AddLine(show,static_cast(0),ci1); + this->AddSpace(2); + // + // Paint with and Direction + // + iggFrame *pf = new iggFrame(this,2); + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iCrossSectionViewSubject::KeyVar(),0,pf,0); + pl->Complete(); + pl->AddDependent(show); + iggWidgetKeyRadioBox *cd = new iggWidgetKeyRadioBox(1,"Direction",0,iCrossSectionViewSubject::KeyDir(),pf); + cd->InsertItem("X"); + cd->InsertItem("Y"); + cd->InsertItem("Z"); + pf->AddLine(pl,cd); + this->AddLine(pf); + this->AddSpace(2); + // + // Method + // + iggFrame *mf = new iggFrame(this,2); + iggWidgetKeyRadioBox *cm = new iggWidgetKeyRadioBox(1,"Method",0,iCrossSectionViewSubject::KeyMethod(),mf); + cm->InsertItem("Polygons"); + cm->InsertItem("Textures"); + mf->AddLine(cm,new iggWidgetKeyCheckBox("Interpolate data",iCrossSectionViewSubject::KeyInterpolateData(),mf)); + this->AddLine(mf); + this->AddSpace(10); + // + // Position + // + mSlider = new PositionSlider(this); + DownsampleCheckBox *dc = new DownsampleCheckBox(this); + mSlider->SetDownsampleBuddy(dc); + this->AddLine(mSlider,3); + this->AddLine(dc); + + this->AddSpace(2); + this->AddLine(new iggFrameAttachPosition(mSlider,iCrossSectionViewSubject::KeyAttachToMarker(),"",this,true),1); + this->AddLine(new OrthogonalizeViewButton(this)); + + this->AddSpace(10); + + this->SetColStretch(1,10); + this->SetColStretch(2,5); + } + }; - page0->SetColStretch(1,10); - page0->SetColStretch(2,5); // // Paint page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Paint",icon,page1); - // - // Book - // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); + class PaintPage : public iggFrameDC + { + + public: + + PaintPage(iggFrameBase *parent) : iggFrameDC(parent,1) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("xsec.png"); + + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,2); + pb->AddPage("Palette",icon,pbpage0); + { + iggFramePaletteSelection *ps = new iggFramePaletteSelection(false,iCrossSectionViewSubject::KeyPalette(),pbpage0,0); + pbpage0->AddLine(ps); + pbpage0->AddSpace(20); + + pbpage0->SetColStretch(0,10); + pbpage0->SetColStretch(1,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(true,true,iCrossSectionViewSubject::Type(),pbpage1); + pbpage1->AddLine(mp); + + pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; + // - // Palette page + // Instances page + // ************************************************ // - iggFrame *pbpage0 = new iggFrame(pb,2); - pb->AddPage("Palette",icon,pbpage0); + class InstancesPage : public iggFrameDC + { - iggFramePaletteSelection *ps = new iggFramePaletteSelection(false,iCrossSectionViewSubject::KeyPalette(),pbpage0,0); - pbpage0->AddLine(ps); - pbpage0->AddSpace(20); + public: + + InstancesPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Instance # + // + iggFrameCurrentInstance *ci2 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeyCrossSectionCurrent(),iViewModule::KeyCrossSectionMax(),this); + ci2->AddDependent(this); + this->AddLine(ci2); + this->AddSpace(2); + // + // Color + // + this->AddLine(new iggFrameCreateDeleteButton(this,iCrossSectionViewSubject::Type(),true,"instance",this)); + this->AddSpace(10); - pbpage0->SetColStretch(0,10); - pbpage0->SetColStretch(1,3); + this->SetColStretch(2,10); + } + }; // - // Material page + // Special page + // ************************************************ // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); + class SpecialPage : public iggFrameDC + { - iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(true,true,iCrossSectionViewSubject::Type(),pbpage1); - pbpage1->AddLine(mp); + public: + + SpecialPage(iggFrameBase *parent, MainPage *p) : iggFrameDC(parent,2), mMainPage(p) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: - pbpage1->AddSpace(10); - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); + MainPage *mMainPage; + + virtual void CompleteConstructionBody() + { + iggFrame *pf = new iggFrame(this,3); + ScanBoxButton *sb = new ScanBoxButton(pf); + sb->SetBuddy(mMainPage->Slider()); + pf->AddLine(sb,new ScanDurationSpinBox(sb,pf),new iggWidgetTextArea("steps",pf)); + this->AddLine(pf); + this->AddSpace(2); + + pf = new iggFrame("Place cross-section at...",this,2); + pf->AddLine(new iggWidgetTextArea("Minimum of the data",pf),new iggWidgetKeyExecIntButton(0,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); + pf->AddLine(new iggWidgetTextArea("Maximum of the data",pf),new iggWidgetKeyExecIntButton(1,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); + pf->AddLine(new iggWidgetTextArea("Center of the box",pf),new iggWidgetKeyExecIntButton(3,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); + pf->AddLine(new iggWidgetTextArea("Lower 1/4 of the box",pf),new iggWidgetKeyExecIntButton(2,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); + pf->AddLine(new iggWidgetTextArea("Upper 1/4 of the box",pf),new iggWidgetKeyExecIntButton(4,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); + this->AddLine(pf); + + this->AddSpace(10); + this->SetColStretch(1,10); + } + }; +}; + + +using namespace iggPageCrossSection_Private; + + +iggPageCrossSection::iggPageCrossSection(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::CrossSection) +{ + const iImage *icon = iImageFactory::FindIcon("xsec.png"); // - // Instances page + // Main page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,3); - mBook->AddPage("Instances",icon,page2); + MainPage *page0 = new MainPage(mBook,mProvider); + mBook->AddPage("Main",icon,page0); + // - // Instance # + // Paint page + // ************************************************ // - iggFrameCurrentInstance *ci2 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeyCrossSectionCurrent(),iViewModule::KeyCrossSectionMax(),page2); - ci2->AddDependent(this); - page2->AddLine(ci2); - page2->AddSpace(2); + PaintPage *page1 = new PaintPage(mBook); + mBook->AddPage("Paint",icon,page1); + // - // Color + // Instances page + // ************************************************ // - page2->AddLine(new iggFrameCreateDeleteButton(this,iCrossSectionViewSubject::Type(),true,"instance",page2)); - page2->AddSpace(10); - - page2->SetColStretch(2,10); + InstancesPage *page2 = new InstancesPage(mBook); + mBook->AddPage("Instances",icon,page2); // // Special page // ************************************************ // - iggFrame *page3 = new iggFrame(mBook,2); + SpecialPage *page3 = new SpecialPage(mBook,page0); mBook->AddPage("Special",icon,page3); - - pf = new iggFrame(page3,3); - ScanBoxButton *sb = new ScanBoxButton(pf); - sb->SetBuddy(cp); - pf->AddLine(sb,new ScanDurationSpinBox(sb,pf),new iggWidgetTextArea("steps",pf)); - page3->AddLine(pf); - page3->AddSpace(2); - - pf = new iggFrame("Place cross-section at...",page3,2); - pf->AddLine(new iggWidgetTextArea("Minimum of the data",pf),new iggWidgetKeyExecIntButton(0,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); - pf->AddLine(new iggWidgetTextArea("Maximum of the data",pf),new iggWidgetKeyExecIntButton(1,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); - pf->AddLine(new iggWidgetTextArea("Center of the box",pf),new iggWidgetKeyExecIntButton(3,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); - pf->AddLine(new iggWidgetTextArea("Lower 1/4 of the box",pf),new iggWidgetKeyExecIntButton(2,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); - pf->AddLine(new iggWidgetTextArea("Upper 1/4 of the box",pf),new iggWidgetKeyExecIntButton(4,"Go",iCrossSectionViewSubject::KeySpecialLocation(),pf)); - page3->AddLine(pf); - - page3->AddSpace(10); - page3->SetColStretch(1,10); } #endif diff -Nru ifrit-3.3.4/shells/generic/iggpagecrosssection.h ifrit-3.4.2/shells/generic/iggpagecrosssection.h --- ifrit-3.3.4/shells/generic/iggpagecrosssection.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagecrosssection.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagedata.cpp ifrit-3.4.2/shells/generic/iggpagedata.cpp --- ifrit-3.3.4/shells/generic/iggpagedata.cpp 2011-01-27 17:52:28.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagedata.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -291,7 +291,7 @@ mMin = lim->GetMin(mIndex); mMax = lim->GetMax(mIndex); mStretch = lim->GetStretch(mIndex); - if(lim->GetClass(mIndex) > 999) this->SetStep(1.0f); + if(lim->GetRank(mIndex) == -1) this->SetStep(1.0f); mResolution = this->ComputeResolution(); this->SetRange(0,mResolution); this->iggWidgetKeyFloatSlider::UpdateWidgetBody(); @@ -317,9 +317,13 @@ vls1->AddBuddy(vls2); this->AddLine(vls1,2,new LimitsExpandButton(true,true,mPage,this,index),1,new LimitsExpandButton(true,false,mPage,this,index),1); this->AddLine(vls2,2,new LimitsExpandButton(false,false,mPage,this,index),1,new LimitsExpandButton(false,true,mPage,this,index),1); - mStretchBox = new LimitsStretchComboBox(mPage,this,index); - this->AddLine(mStretchBox,1,new LimitsNameEdit(mPage,this,index),3); - this->SetColStretch(1,10); + iggFrame *f = new iggFrame(this,3); + mStretchBox = new LimitsStretchComboBox(mPage,f,index); + f->AddLine(new LimitsNameEdit(mPage,f,index),(iggWidget *)0,mStretchBox); + f->SetColStretch(0,5); + f->SetColStretch(1,1); + this->AddLine(f,4); + this->SetColStretch(0,5); } protected: @@ -369,7 +373,7 @@ public: - LimitsFrameSet(const iggPageData *page, iggFrame *parent) : iggFrameScroll(parent,false), mPage(page) + LimitsFrameSet(const iggPageData *page, iggFrame *parent) : iggFrameScroll(parent,true), mPage(page) { mNeedsBaloonHelp = false; } @@ -558,7 +562,7 @@ CalculatorLineEdit(iggFrame *parent) : iggWidget(parent) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"%bFunction:",0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,"%bFunction:"); mSubject->SetEditable(false); mNeedsBaloonHelp = false; @@ -663,6 +667,11 @@ { mLineEdit = le; + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mCalculatorLineEdit = new CalculatorLineEdit(mFrame); mFrame->AddLine(mCalculatorLineEdit,2); @@ -734,7 +743,7 @@ mFrame->AddLine(f3,f4); } - virtual void Show(bool s) + virtual void ShowBody(bool s) { if(s) { @@ -743,7 +752,7 @@ mCalculatorLineEdit->SetText(line); } - iggDialog::Show(s); + iggDialog::ShowBody(s); } virtual const iString& GetToolTip() const @@ -851,40 +860,117 @@ iggDataTypeProvider *mProvider; }; -}; -using namespace iggPageData_Private; + // + // Shift page + // + class CommonShiftPage : public iggFrameDC + { + public: + + CommonShiftPage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } -iggPageData::iggPageData(iggFrameBase *parent) : iggPageMain(parent,true,true) -{ - const iImage *icon = iImageFactory::FindIcon("data.png"); + protected: - mInfoBuffer = new iDataInfo[DataWith::COUNT]; IERROR_ASSERT(mInfoBuffer); - mProvider = new iggCompositeDataTypeProvider(this); IERROR_ASSERT(mProvider); - mProvider->AddProvider(new iggKeywordDataTypeProvider("scalars",this)); - mProvider->AddProvider(new iggKeywordDataTypeProvider("particles",this)); + virtual void CompleteConstructionBody() + { + iggFrame *sh = new iggFrame(this); + sh->AddLine(new ShiftingSlider("%bX",iDataReader::KeyShiftData(),sh,0)); + sh->AddLine(new ShiftingSlider("%bY",iDataReader::KeyShiftData(),sh,1)); + sh->AddLine(new ShiftingSlider("%bZ",iDataReader::KeyShiftData(),sh,2)); + this->AddLine(sh); + this->AddSpace(10); + this->SetColStretch(0,10); + this->SetColStretch(1,3); + } + }; - iDataType::FindTypesByKeywords(mInfoBuffer[DataWith::ParticleDownsampling],"particles"); - mInfoBuffer[DataWith::BoundaryCondition] = mInfoBuffer[DataWith::ParticleDownsampling] + iUniformScalarsDataSubject::DataType() + iUniformVectorsDataSubject::DataType() + iUniformTensorsDataSubject::DataType(); - mInfoBuffer[DataWith::VariableCalculation] = iUniformScalarsDataSubject::DataType(); - this->GetMainWindow()->GetExtensionWindow()->AddReloadingDataTypes(this); + // + // Erase page + // + class CommonErasePage : public iggFrameDC + { + + public: + + CommonErasePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + ErasePushButton *eb = new ErasePushButton("Erase selected data",this); + this->AddLine(new EraseFrame(eb,this)); + this->AddLine(eb); + this->AddSpace(2); + this->SetRowStretch(0,10); + this->SetColStretch(0,10); + this->SetColStretch(1,0); + } + }; + + + // + // Fixed/adjustable page + // + class CommonRangePage : public iggFrameDC + { + + public: + + CommonRangePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + this->AddLine(new FixedLimitsFrame(this)); + this->AddSpace(10); + this->SetRowStretch(0,8); + this->SetColStretch(1,10); + } + }; + // // Common page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,1); - mBook->AddPage("Common",icon,page0); + class CommonPage : public iggFrameDC { - // - // Book - // - iggFrameBook *sb = new iggFrameBook(page0); - page0->AddLine(sb); + + public: + + CommonPage(iggFrameBase *parent, iDataInfo *info) : iggFrameDC(parent,1), mInfoBuffer(info) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iDataInfo *mInfoBuffer; + + virtual void CompleteConstructionBody() { + const iImage *icon = iImageFactory::FindIcon("data.png"); + + // + // Book + // + iggFrameBook *sb = new iggFrameBook(this); + this->AddLine(sb); // // Global page // @@ -917,59 +1003,53 @@ // // Shift page // - iggFrame *sbpage1 = new iggFrame(sb,2); + CommonShiftPage *sbpage1 = new CommonShiftPage(sb); sb->AddPage("Shift data",icon,sbpage1); - { - iggFrame *sh = new iggFrame(sbpage1); - sh->AddLine(new ShiftingSlider("%bX",iDataReader::KeyShiftData(),sh,0)); - sh->AddLine(new ShiftingSlider("%bY",iDataReader::KeyShiftData(),sh,1)); - sh->AddLine(new ShiftingSlider("%bZ",iDataReader::KeyShiftData(),sh,2)); - sbpage1->AddLine(sh); - sbpage1->AddSpace(10); - sbpage1->SetColStretch(0,10); - sbpage1->SetColStretch(1,3); - } + // // Erase page // - iggFrame *sbpage2 = new iggFrame(sb,2); + CommonErasePage *sbpage2 = new CommonErasePage(sb); sb->AddPage("Erase",icon,sbpage2); - { - ErasePushButton *eb = new ErasePushButton("Erase selected data",sbpage2); - sbpage2->AddLine(new EraseFrame(eb,sbpage2)); - sbpage2->AddLine(eb); - sbpage2->AddSpace(2); - sbpage2->SetRowStretch(0,10); - sbpage2->SetColStretch(0,10); - sbpage2->SetColStretch(1,10); - } + // // Fixed/adjustable page // - iggFrame *sbpage3 = new iggFrame(sb,2); + CommonRangePage *sbpage3 = new CommonRangePage(sb); sb->AddPage("Ranges",icon,sbpage3); - { - sbpage3->AddLine(new FixedLimitsFrame(sbpage3)); - sbpage3->AddSpace(10); - sbpage3->SetRowStretch(0,8); - sbpage3->SetColStretch(1,10); - } } - } + }; + // // Field data page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Field data",icon,page1); + class FieldDataPage : public iggFrameDC { - // - // Book - // - iggFrameBook *fb = new iggFrameBook(page1); - page1->AddLine(fb); + + public: + + FieldDataPage(iggFrameBase *parent, iggPageData *owner, iDataInfo *info, iggCompositeDataTypeProvider *provider) : iggFrameDC(parent,1), mOwner(owner), mInfoBuffer(info), mProvider(provider) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggPageData *mOwner; + iDataInfo *mInfoBuffer; + iggCompositeDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("data.png"); + + // + // Book + // + iggFrameBook *fb = new iggFrameBook(this); + this->AddLine(fb); // // Placement page // @@ -984,24 +1064,24 @@ iggWidgetTextArea *tmp = new iggWidgetTextArea(" Dimension to fit",fbpage2); tmp->AlignLeft(true); fbpage2->AddLine(tmp); - iggWidgetKeyRadioBox *fb = new iggWidgetKeyRadioBox(1,"into bounding box",2,iDataReader::KeyScaledDimension(),fbpage2); - fb->InsertItem("Longest"); - fb->InsertItem("Shortest"); - fb->InsertItem("X"); - fb->InsertItem("Y"); - fb->InsertItem("Z"); - fbpage2->AddLine(fb); + iggWidgetKeyRadioBox *bb = new iggWidgetKeyRadioBox(1,"into bounding box",2,iDataReader::KeyScaledDimension(),fbpage2); + bb->InsertItem("Longest"); + bb->InsertItem("Shortest"); + bb->InsertItem("X"); + bb->InsertItem("Y"); + bb->InsertItem("Z"); + fbpage2->AddLine(bb); fbpage2->AddSpace(10); fbpage2->SetColStretch(1,10); - } + } // // Limits page // iggFrame *fbpage1 = new iggFrame(fb,1); fb->AddPage("Limits",icon,fbpage1); { - fbpage1->AddLine(new LimitsFrameSet(this,fbpage1)); + fbpage1->AddLine(new LimitsFrameSet(mOwner,fbpage1)); } // // Operate page @@ -1029,21 +1109,37 @@ fbpage3->SetColStretch(2,3); } } - } + }; + // // Particle data page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,1); - mBook->AddPage("Particle data",icon,page2); + class ParticleDataPage : public iggFrameDC { - // - // Book - // - iggFrameBook *pb = new iggFrameBook(page2); - page2->AddLine(pb); + + public: + + ParticleDataPage(iggFrameBase *parent, iDataInfo *info, iggCompositeDataTypeProvider *provider) : iggFrameDC(parent,1), mInfoBuffer(info), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iDataInfo *mInfoBuffer; + iggCompositeDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() { + const iImage *icon = iImageFactory::FindIcon("data.png"); + + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); // // Downsample page // @@ -1096,7 +1192,48 @@ pbpage1->SetColStretch(1,10); } } - } + }; +}; + + +using namespace iggPageData_Private; + + +iggPageData::iggPageData(iggFrameBase *parent) : iggPageMain(parent,true,true) +{ + const iImage *icon = iImageFactory::FindIcon("data.png"); + + mInfoBuffer = new iDataInfo[DataWith::COUNT]; IERROR_ASSERT(mInfoBuffer); + mProvider = new iggCompositeDataTypeProvider(this); IERROR_ASSERT(mProvider); + mProvider->AddProvider(new iggKeywordDataTypeProvider("scalars",this)); + mProvider->AddProvider(new iggKeywordDataTypeProvider("particles",this)); + + iDataType::FindTypesByKeywords(mInfoBuffer[DataWith::ParticleDownsampling],"particles"); + mInfoBuffer[DataWith::BoundaryCondition] = mInfoBuffer[DataWith::ParticleDownsampling] + iUniformScalarsDataSubject::DataType() + iUniformVectorsDataSubject::DataType() + iUniformTensorsDataSubject::DataType(); + mInfoBuffer[DataWith::VariableCalculation] = iUniformScalarsDataSubject::DataType(); + + this->GetMainWindow()->GetExtensionWindow()->AddReloadingDataTypes(this); + + // + // Common page + // ************************************************ + // + CommonPage *page0 = new CommonPage(mBook,mInfoBuffer); + mBook->AddPage("Common",icon,page0); + + // + // Field data page + // ************************************************ + // + FieldDataPage *page1 = new FieldDataPage(mBook,this,mInfoBuffer,mProvider); + mBook->AddPage("Field data",icon,page1); + + // + // Particle data page + // ************************************************ + // + ParticleDataPage *page2 = new ParticleDataPage(mBook,mInfoBuffer,mProvider); + mBook->AddPage("Particle data",icon,page2); } diff -Nru ifrit-3.3.4/shells/generic/iggpagedata.h ifrit-3.4.2/shells/generic/iggpagedata.h --- ifrit-3.3.4/shells/generic/iggpagedata.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagedata.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagemain.cpp ifrit-3.4.2/shells/generic/iggpagemain.cpp --- ifrit-3.3.4/shells/generic/iggpagemain.cpp 2011-01-27 17:52:29.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagemain.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagemain.h ifrit-3.4.2/shells/generic/iggpagemain.h --- ifrit-3.3.4/shells/generic/iggpagemain.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagemain.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageobject.cpp ifrit-3.4.2/shells/generic/iggpageobject.cpp --- ifrit-3.3.4/shells/generic/iggpageobject.cpp 2011-01-27 17:52:29.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageobject.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageobject.h ifrit-3.4.2/shells/generic/iggpageobject.h --- ifrit-3.3.4/shells/generic/iggpageobject.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageobject.h 2013-07-11 01:23:53.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageobjectextension.cpp ifrit-3.4.2/shells/generic/iggpageobjectextension.cpp --- ifrit-3.3.4/shells/generic/iggpageobjectextension.cpp 2011-01-27 17:52:29.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageobjectextension.cpp 2013-07-11 01:23:59.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageobjectextension.h ifrit-3.4.2/shells/generic/iggpageobjectextension.h --- ifrit-3.3.4/shells/generic/iggpageobjectextension.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageobjectextension.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageparticles.cpp ifrit-3.4.2/shells/generic/iggpageparticles.cpp --- ifrit-3.3.4/shells/generic/iggpageparticles.cpp 2011-01-27 17:52:29.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageparticles.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -232,286 +232,416 @@ iggPageParticles *mPage; }; -}; -using namespace iggPageParticles_Private; + // + // Main page + // ************************************************ + // + class MainPage : public iggFrameDC + { + public: -iggPageParticles::iggPageParticles(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Particles) -{ - int i; + MainPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } - const iImage *icon = iImageFactory::FindIcon("part.png"); + protected: - mCurrentParticles = this->GetParticlesObject()->GetActiveDataTypeIndex(); + virtual void CompleteConstructionBody() + { + // + // Show + // + iggFrameCurrentInstance *ci = new iggFrameCurrentInstance(false,"Group","Group",iParticlesViewSubject::KeyCurrentGroup(),iParticlesViewSubject::KeyMaxGroup(),this); + ci->AddDependent(this); + this->AddLine(new iggWidgetShowButton(iParticlesViewSubject::Type(),this),static_cast(0),ci); + this->AddSpace(2); + // + // Method & color normals + // + iggFrame *tf = new iggFrame(this,2); + iggWidgetKeyComboBox *tb = new iggWidgetKeyComboBox("Type",0,iParticleGroup::KeyType(),tf); + int i; + for(i=0; iInsertItem(iPointGlyph::GetName(i)); + } + tf->AddLine(tb,new iggWidgetKeyColorSelection(iParticleGroup::KeyColor(),tf)); - // - // Replace provider - // - delete mProvider; - mProvider = new ParticleTypeProvider(this); IERROR_ASSERT(mProvider); + this->AddLine(tf); + this->AddSpace(10); + // + // Opacity + // + iggWidgetKeyFloatSlider *os = new iggWidgetKeyFloatSlider(1.0e-4,1.0,40,1,5,"Opacity",iParticleGroup::KeyOpacity(),RenderMode::UseGlobal,this); + os->SetStretch(2,10); + this->AddLine(os,2); + iggWidgetKeyFloatSlider *ss = new iggWidgetKeyFloatSlider(1.0e-2,1.0e2,40,1,5,"Size",iParticleGroup::KeyFixedSize(),RenderMode::UseGlobal,this); + ss->SetStretch(2,10); + this->AddLine(ss,2); + iggFrame *tmp = new iggFrame(this,4); + tmp->AddLine(new AdjustSizeSliderButton(ss,false,tmp),new AdjustSizeSliderButton(ss,true,tmp),new iggWidgetTextArea("Expand/shrink the lower limit",tmp)); + tmp->SetColStretch(3,10); + this->AddLine(tmp); + this->AddLine(new iggWidgetKeyCheckBox("Scale particles automatically",iParticleGroup::KeyAutoScaled(),this)); + this->AddSpace(10); + + this->SetColStretch(1,10); + } + }; - mIcons.Add(iImageFactory::FindIcon("part.png")); - const iDataInfo &di(mProvider->GetDataInfo()); - const iImage *image; - for(i=1; iGetMainWindow()->GetExtensionWindow()->GetSpecialParticleIcon(di.Type(i)); - if(image == 0) mIcons.Add(icon); else mIcons.Add(image); - } // - // Main page + // Paint page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,3); - mBook->AddPage("Main",icon,page0); - // - // Show - // - iggFrameCurrentInstance *ci = new iggFrameCurrentInstance(false,"Group","Group",iParticlesViewSubject::KeyCurrentGroup(),iParticlesViewSubject::KeyMaxGroup(),page0); - ci->AddDependent(this); - page0->AddLine(new iggWidgetShowButton(iParticlesViewSubject::Type(),page0),static_cast(0),ci); - page0->AddSpace(2); - // - // Method & color normals - // - iggFrame *tf = new iggFrame(page0,2); - iggFrame *tf1 = new iggFrame(tf,1); - iggWidgetKeyComboBox *tb = new iggWidgetKeyComboBox("Type",0,iParticleGroup::KeyType(),tf1); - tf1->AddLine(tb); - tf1->AddSpace(10); - for(i=0; iInsertItem(iPointGlyph::GetName(i)); - } - tf->AddLine(tf1,new iggWidgetKeyColorSelection(iParticleGroup::KeyColor(),tf,false)); - - page0->AddLine(tf); - page0->AddSpace(10); - // - // Opacity - // - iggWidgetKeyFloatSlider *os = new iggWidgetKeyFloatSlider(1.0e-4,1.0,40,1,5,"Opacity",iParticleGroup::KeyOpacity(),RenderMode::UseGlobal,page0); - os->SetStretch(2,10); - page0->AddLine(os,2); - iggWidgetKeyFloatSlider *ss = new iggWidgetKeyFloatSlider(1.0e-2,1.0e2,40,1,5,"Size",iParticleGroup::KeyFixedSize(),RenderMode::UseGlobal,page0); - ss->SetStretch(2,10); - page0->AddLine(ss,2); - iggFrame *tmp = new iggFrame(page0,4); - tmp->AddLine(new AdjustSizeSliderButton(ss,false,tmp),new AdjustSizeSliderButton(ss,true,tmp),new iggWidgetTextArea("Expand/shrink the lower limit",tmp)); - tmp->SetColStretch(3,10); - page0->AddLine(tmp); - page0->AddLine(new iggWidgetKeyCheckBox("Scale particles automatically",iParticleGroup::KeyAutoScaled(),page0)); - page0->AddSpace(10); - page0->SetColStretch(1,10); + public: + + PaintPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,1), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } - // - // Paint page - // ************************************************ - // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Paint",icon,page1); - // - // Book - // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); - // - // Palette page - // - iggFrame *pbpage0 = new iggFrame(pb,3); - pb->AddPage("Palette",icon,pbpage0); + iggWidgetKeyVariableLimitsSlider* AttLower() const { return mAttLower; } + iggWidgetKeyVariableLimitsSlider* AttUpper() const { return mAttUpper; } - iggFrame *pf = new iggFrame(pbpage0,2); - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iParticleGroup::KeyAttributeToColor(),0,pf); - pl->InsertItem("None"); - pl->Complete(); - tmp = new iggFrame(pf); - tmp->AddSpace(10); - iggWidgetKeyStretchComboBox *ls = new iggWidgetKeyStretchComboBox(iParticleGroup::KeyStretchToColor(),tmp); - tmp->AddLine(ls); - tmp->AddSpace(10); - pf->AddLine(pl,tmp); - pbpage0->AddLine(pf); + protected: - pbpage0->AddSpace(5); + iggDataTypeProvider *mProvider; + iggWidgetKeyVariableLimitsSlider *mAttLower, *mAttUpper; - iggWidgetKeyVariableLimitsSlider *al = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Min",iParticleGroup::KeyLowerLimitToColor(),&iParticleGroup::KeyAttributeToColor(),&iParticleGroup::KeyStretchToColor(),RenderMode::UseGlobal,pbpage0,0,&iParticleGroup::KeyAttributeToColor()); - iggWidgetKeyVariableLimitsSlider *au = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Max",iParticleGroup::KeyUpperLimitToColor(),&iParticleGroup::KeyAttributeToColor(),&iParticleGroup::KeyStretchToColor(),RenderMode::UseGlobal,pbpage0,0,&iParticleGroup::KeyAttributeToColor()); - pl->AddDependent(al); - pl->AddDependent(au); - ls->AddDependent(al); - ls->AddDependent(au); - al->AddBuddy(au); - pbpage0->AddLine(al,2); - pbpage0->AddLine(au,2); + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("part.png"); - pbpage0->AddSpace(10); + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,3); + pb->AddPage("Palette",icon,pbpage0); + { + iggFrame *pf = new iggFrame(pbpage0,2); + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iParticleGroup::KeyAttributeToColor(),0,pf); + pl->InsertItem("None"); + pl->Complete(); + iggFrame *tmp = new iggFrame(pf); + tmp->AddSpace(10); + iggWidgetKeyStretchComboBox *ls = new iggWidgetKeyStretchComboBox(iParticleGroup::KeyStretchToColor(),tmp); + tmp->AddLine(ls); + tmp->AddSpace(10); + pf->AddLine(pl,tmp); + pbpage0->AddLine(pf); + + pbpage0->AddSpace(5); + + mAttLower = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Min",iParticleGroup::KeyLowerLimitToColor(),&iParticleGroup::KeyAttributeToColor(),&iParticleGroup::KeyStretchToColor(),RenderMode::UseGlobal,pbpage0,0,&iParticleGroup::KeyAttributeToColor()); + mAttUpper = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Max",iParticleGroup::KeyUpperLimitToColor(),&iParticleGroup::KeyAttributeToColor(),&iParticleGroup::KeyStretchToColor(),RenderMode::UseGlobal,pbpage0,0,&iParticleGroup::KeyAttributeToColor()); + pl->AddDependent(mAttLower); + pl->AddDependent(mAttUpper); + ls->AddDependent(mAttLower); + ls->AddDependent(mAttUpper); + mAttLower->AddBuddy(mAttUpper); + pbpage0->AddLine(mAttLower,2); + pbpage0->AddLine(mAttUpper,2); - pbpage0->AddLine(new iggFramePaletteSelection(true,iParticleGroup::KeyPalette(),pbpage0),2); - pbpage0->AddSpace(20); + pbpage0->AddSpace(10); - pbpage0->SetColStretch(1,10); - pbpage0->SetColStretch(2,3); + pbpage0->AddLine(new iggFramePaletteSelection(true,iParticleGroup::KeyPalette(),pbpage0),2); + pbpage0->AddSpace(20); - // - // Material page - // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); + pbpage0->SetColStretch(1,10); + pbpage0->SetColStretch(2,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + pbpage1->AddLine(new iggFrameMaterialProperties(true,false,iParticleGroup::Type(),pbpage1)); + pbpage1->AddSpace(10); - pbpage1->AddLine(new iggFrameMaterialProperties(true,false,iParticleGroup::Type(),pbpage1)); - pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); // // Size page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,1); - mBook->AddPage("Size",icon,page2); - // - // Book - // - iggFrameBook *sb = new iggFrameBook(page2); - page2->AddLine(sb); - // - // Settings page - // - iggFrame *sbpage0 = new iggFrame(sb,3); - sb->AddPage("Settings",icon,sbpage0); - - iggFrame *sf = new iggFrame(sbpage0,2); - iggFrameDataVariableList *sl = new iggFrameDataVariableList(mProvider,"Size with...",iParticleGroup::KeyAttributeToSize(),0,sf); - sl->InsertItem("None"); - sl->Complete(); - tmp = new iggFrame(sf); - tmp->AddSpace(10); - iggWidgetKeyStretchComboBox *lz = new iggWidgetKeyStretchComboBox(iParticleGroup::KeyStretchToSize(),tmp); - tmp->AddLine(lz); - tmp->AddSpace(10); - sf->AddLine(sl,tmp); - sf->AddLine(new iggWidgetKeyCheckBox("Use as size; scale by",iParticleGroup::KeyAttributeSizeDirect(),sf),new iggWidgetKeyFloatLineEdit("",iParticleGroup::KeyAttributeSizeExtraFactor(),RenderMode::UseGlobal,sf)); - - sbpage0->AddLine(sf); + class SizePage : public iggFrameDC + { - sbpage0->AddSpace(5); + public: - iggWidgetKeyVariableLimitsSlider *bl = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Min",iParticleGroup::KeyLowerLimitToSize(),&iParticleGroup::KeyAttributeToSize(),&iParticleGroup::KeyStretchToSize(),RenderMode::UseGlobal,sbpage0,0,&iParticleGroup::KeyAttributeToSize()); - iggWidgetKeyVariableLimitsSlider *bu = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Max",iParticleGroup::KeyUpperLimitToSize(),&iParticleGroup::KeyAttributeToSize(),&iParticleGroup::KeyStretchToSize(),RenderMode::UseGlobal,sbpage0,0,&iParticleGroup::KeyAttributeToSize()); - sl->AddDependent(bl); - sl->AddDependent(bu); - lz->AddDependent(bl); - lz->AddDependent(bu); - bl->AddBuddy(bu); - // - // Add paint limits as well - // - bl->AddBuddy(au); - bu->AddBuddy(al); + SizePage(iggFrameBase *parent, iggDataTypeProvider *provider, PaintPage *pp) : iggFrameDC(parent,1), mProvider(provider), mPaintPage(pp) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } - sbpage0->AddLine(bl,2); - sbpage0->AddLine(bu,2); + protected: - sbpage0->AddSpace(10); + iggDataTypeProvider *mProvider; + PaintPage *mPaintPage; - sbpage0->SetColStretch(1,10); - sbpage0->SetColStretch(2,3); + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("part.png"); + + // + // Book + // + iggFrameBook *sb = new iggFrameBook(this); + this->AddLine(sb); + // + // Settings page + // + iggFrame *sbpage0 = new iggFrame(sb,3); + sb->AddPage("Settings",icon,sbpage0); + { + iggFrame *sf = new iggFrame(sbpage0,2); + iggFrameDataVariableList *sl = new iggFrameDataVariableList(mProvider,"Size with...",iParticleGroup::KeyAttributeToSize(),0,sf); + sl->InsertItem("None"); + sl->Complete(); + iggFrame *tmp = new iggFrame(sf); + tmp->AddSpace(10); + iggWidgetKeyStretchComboBox *lz = new iggWidgetKeyStretchComboBox(iParticleGroup::KeyStretchToSize(),tmp); + tmp->AddLine(lz); + tmp->AddSpace(10); + sf->AddLine(sl,tmp); + sf->AddLine(new iggWidgetKeyCheckBox("Use as size; scale by",iParticleGroup::KeyAttributeSizeDirect(),sf),new iggWidgetKeyFloatLineEdit("",iParticleGroup::KeyAttributeSizeExtraFactor(),RenderMode::UseGlobal,sf)); + + sbpage0->AddLine(sf); + + sbpage0->AddSpace(5); + + iggWidgetKeyVariableLimitsSlider *bl = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Min",iParticleGroup::KeyLowerLimitToSize(),&iParticleGroup::KeyAttributeToSize(),&iParticleGroup::KeyStretchToSize(),RenderMode::UseGlobal,sbpage0,0,&iParticleGroup::KeyAttributeToSize()); + iggWidgetKeyVariableLimitsSlider *bu = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Max",iParticleGroup::KeyUpperLimitToSize(),&iParticleGroup::KeyAttributeToSize(),&iParticleGroup::KeyStretchToSize(),RenderMode::UseGlobal,sbpage0,0,&iParticleGroup::KeyAttributeToSize()); + sl->AddDependent(bl); + sl->AddDependent(bu); + lz->AddDependent(bl); + lz->AddDependent(bu); + bl->AddBuddy(bu); + // + // Add paint limits as well + // + bu->AddBuddy(mPaintPage->AttUpper()); + bl->AddBuddy(mPaintPage->AttLower()); + + sbpage0->AddLine(bl,2); + sbpage0->AddLine(bu,2); + + sbpage0->AddSpace(10); + + sbpage0->SetColStretch(1,10); + sbpage0->SetColStretch(2,3); + } + // + // Function page + // + iggFrame *sbpage1 = new iggFrame(sb,1); + sb->AddPage("Function",icon,sbpage1); + { + // + // FunctionMapping widget + // + sbpage1->AddLine(new iggFrameFunctionMapping(iParticleGroup::KeySizeFunction(),sbpage1)); + } + } + }; - // - // Function page - // - iggFrame *sbpage1 = new iggFrame(sb,1); - sb->AddPage("Function",icon,sbpage1); - // - // FunctionMapping widget - // - sbpage1->AddLine(new iggFrameFunctionMapping(iParticleGroup::KeySizeFunction(),sbpage1)); // // Replicate page // ************************************************ // - iggFrame *page3 = new iggFrame(mBook,2); - mBook->AddPage("Replicate",icon,page3); - // - // Replicate - // - page3->AddLine(new iggFrameReplicate(iParticlesViewSubject::Type(),page3)); - page3->AddSpace(10); - page3->SetColStretch(1,3); + class ReplicatePage : public iggFrameDC + { + + public: + + ReplicatePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Replicate + // + this->AddLine(new iggFrameReplicate(iParticlesViewSubject::Type(),this)); + this->AddSpace(10); + this->SetColStretch(1,3); + } + }; // // Advanced page // ************************************************ // - iggFrame *page4 = new iggFrame(mBook,1); - mBook->AddPage("Advanced",icon,page4); + class AdvancedPage : public iggFrameDC + { + + public: + + AdvancedPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,1), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("part.png"); + + // + // Book + // + iggFrameBook *ab = new iggFrameBook(this); + this->AddLine(ab); + // + // Split page + // + iggFrame *abpage0 = new iggFrame(ab,1); + ab->AddPage("Split into groups",icon,abpage0); + { + // + // Book + // + iggFrameBook *db = new iggFrameBook(abpage0); + abpage0->AddLine(db); + iggFrameDataVariableList *av; + iggWidgetKeyStretchComboBox *as; + // + // Main page + // + iggFrame *dbpage0 = new iggFrame(db,2); + db->AddPage("Main",icon,dbpage0); + { + av = new iggFrameDataVariableList(mProvider,"Split by...",iParticlesViewSubject::KeyAttributeToSplit(),0,dbpage0); + av->InsertItem("Do not split"); + av->Complete(); // splitter's attributes start with -1 + dbpage0->AddLine(av); + + as = new iggWidgetKeyStretchComboBox(iParticlesViewSubject::KeySplitRangesStretch(),dbpage0); + dbpage0->AddLine(as); + dbpage0->AddSpace(10); + dbpage0->SetColStretch(1,3); + } + // + // FunctionMapping widget + // + iggFrame *dbpage1 = new iggFrame(db,1); + db->AddPage("Ranges",icon,dbpage1); + { + RangeMapping *rm = new RangeMapping(this,dbpage1); + av->AddDependent(rm); + as->AddDependent(rm); + + dbpage1->AddLine(rm); + } + // + // Connect page + // + iggFrame *abpage1 = new iggFrame(ab,3); + ab->AddPage("Connect with lines",icon,abpage1); + { + iggFrameDataVariableList *cv = new iggFrameDataVariableList(mProvider,"Connect by...",iParticleGroup::KeyAttributeToConnect(),0,abpage1); + cv->InsertItem("Do not connect"); + cv->Complete(); // connector's attributes start with -1 + iggFrameDataVariableList *sv = new iggFrameDataVariableList(mProvider,"Separate by...",iParticleGroup::KeyAttributeToSeparate(),0,abpage1); + sv->InsertItem("None"); + sv->Complete(); // connector's attributes start with -1 + abpage1->AddLine(cv,sv); + + abpage1->AddSpace(10); + abpage1->SetColStretch(2,10); + } + } + } + }; +}; + + +using namespace iggPageParticles_Private; + + +iggPageParticles::iggPageParticles(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Particles) +{ + const iImage *icon = iImageFactory::FindIcon("part.png"); + + mCurrentParticles = this->GetParticlesObject()->GetActiveDataTypeIndex(); + // - // Book + // Replace provider // - iggFrameBook *ab = new iggFrameBook(page4); - page4->AddLine(ab); + delete mProvider; + mProvider = new ParticleTypeProvider(this); IERROR_ASSERT(mProvider); + + mIcons.Add(iImageFactory::FindIcon("part.png")); + const iDataInfo &di(mProvider->GetDataInfo()); + const iImage *image; + int i; + for(i=1; iGetMainWindow()->GetExtensionWindow()->GetSpecialParticleIcon(di.Type(i)); + if(image == 0) mIcons.Add(icon); else mIcons.Add(image); + } // - // Split page + // Main page + // ************************************************ // - iggFrame *abpage0 = new iggFrame(ab,1); - ab->AddPage("Split into groups",icon,abpage0); + MainPage *page0 = new MainPage(mBook); + mBook->AddPage("Main",icon,page0); // - // Book + // Paint page + // ************************************************ // - iggFrameBook *db = new iggFrameBook(abpage0); - abpage0->AddLine(db); + PaintPage *page1 = new PaintPage(mBook,mProvider); + mBook->AddPage("Paint",icon,page1); + // - // Main page + // Size page + // ************************************************ // - iggFrame *dbpage0 = new iggFrame(db,2); - db->AddPage("Main",icon,dbpage0); - - iggFrameDataVariableList *av = new iggFrameDataVariableList(mProvider,"Split by...",iParticlesViewSubject::KeyAttributeToSplit(),0,dbpage0); - av->InsertItem("Do not split"); - av->Complete(); // splitter's attributes start with -1 - dbpage0->AddLine(av); - - iggWidgetKeyStretchComboBox *as = new iggWidgetKeyStretchComboBox(iParticlesViewSubject::KeySplitRangesStretch(),dbpage0); - dbpage0->AddLine(as); - dbpage0->AddSpace(10); - dbpage0->SetColStretch(1,3); - // - // FunctionMapping widget - // - iggFrame *dbpage1 = new iggFrame(db,1); - db->AddPage("Ranges",icon,dbpage1); - - RangeMapping *rm = new RangeMapping(this,dbpage1); - av->AddDependent(rm); - as->AddDependent(rm); - - dbpage1->AddLine(rm); + SizePage *page2 = new SizePage(mBook,mProvider,page1); + mBook->AddPage("Size",icon,page2); // - // Connect page + // Replicate page + // ************************************************ // - iggFrame *abpage1 = new iggFrame(ab,3); - ab->AddPage("Connect with lines",icon,abpage1); - - iggFrameDataVariableList *cv = new iggFrameDataVariableList(mProvider,"Connect by...",iParticleGroup::KeyAttributeToConnect(),0,abpage1); - cv->InsertItem("Do not connect"); - cv->Complete(); // connector's attributes start with -1 - iggFrameDataVariableList *sv = new iggFrameDataVariableList(mProvider,"Separate by...",iParticleGroup::KeyAttributeToSeparate(),0,abpage1); - sv->InsertItem("None"); - sv->Complete(); // connector's attributes start with -1 - abpage1->AddLine(cv,sv); + ReplicatePage *page3 = new ReplicatePage(mBook); + mBook->AddPage("Replicate",icon,page3); - abpage1->AddSpace(10); - abpage1->SetColStretch(2,10); + // + // Advanced page + // ************************************************ + // + AdvancedPage *page4 = new AdvancedPage(mBook,mProvider); + mBook->AddPage("Advanced",icon,page4); } diff -Nru ifrit-3.3.4/shells/generic/iggpageparticles.h ifrit-3.4.2/shells/generic/iggpageparticles.h --- ifrit-3.3.4/shells/generic/iggpageparticles.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageparticles.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagesurface.cpp ifrit-3.4.2/shells/generic/iggpagesurface.cpp --- ifrit-3.3.4/shells/generic/iggpagesurface.cpp 2011-01-27 17:52:29.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagesurface.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -449,213 +449,305 @@ this->GetMainWindow()->Block(false); } }; -}; - -using namespace iggPageSurface_Private; - - -iggPageSurface::iggPageSurface(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Surface) -{ - const iImage *icon = iImageFactory::FindIcon("surf.png"); // // Main page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,1); - mBook->AddPage("Main",icon,page0); - // - // Top half-page sub-frame - // - iggFrame *page0top = new iggFrame(page0,4); - page0->AddLine(page0top); - // - // Show - // - iggWidget *show = new iggWidgetShowButton(iSurfaceViewSubject::Type(),page0top); - iggFrameCurrentInstance *ci1 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeySurfaceCurrent(),iViewModule::KeySurfaceMax(),page0top); - ci1->AddDependent(this); - page0top->AddLine(show,static_cast(0),static_cast(0),ci1); - page0top->AddSpace(2); - // - // Method & flip normals - // - iggFrame *mf = new iggFrame(page0top,2); - MethodRadioBox *mb = new MethodRadioBox(iSurfaceViewSubject::KeyMethod(),mf); - iggFrame *mf2 = new iggFrame(mf,1); - mf2->AddLine(new iggWidgetKeyColorSelection(iSurfaceViewSubject::KeyColor(),mf2,false,0)); - mf2->AddLine(new iggWidgetKeyCheckBox("Flip normals",iSurfaceViewSubject::KeyNormalsFlipped(),mf2)); - mf->AddLine(mb,mf2); - mf2 = new iggFrame(page0top); - mf2->AddSpace(1); - mf2->AddLine(new PrintInfoButton(mf2)); - mf2->AddSpace(1); - page0top->AddLine(mf,2,mf2,1); - page0top->AddSpace(2); - // - // Opacity - // - iggWidgetKeyFloatSlider *os = new iggWidgetKeyFloatSlider(0.0,1.0,100,0,5,"Opacity",iSurfaceViewSubject::KeyOpacity(),RenderMode::UseGlobal,page0top); - page0top->AddLine(os,3); - iggWidgetAllInstancesCheckBox *li = new iggWidgetAllInstancesCheckBox(page0top); - li->AddDependent(os); - page0top->AddLine(li,2); - page0top->AddSpace(10); + class MainPage : public iggFrameDC + { - page0top->SetColStretch(2,3); + public: - // - // Lower half-page: various method-dependent settings in a headless mBook - // - iggFrame *page0bot = new iggFrame(page0,1); - page0->AddLine(page0bot); + MainPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,1), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } - iggFrameFlip *msflip = new iggFrameFlip(page0bot); - page0bot->AddLine(msflip); - page0bot->SetColStretch(0,10); -// page0bot->SetColStretch(1,1); - mb->SetFlipBuddy(msflip); + protected: - // - // Isosurface settings - // - iggFrame *mspage0 = new iggFrame(msflip,4); - msflip->AddLayer(mspage0); + iggDataTypeProvider *mProvider; - iggFrame *iv = new iggFrame(mspage0,1); - iggFrameDataVariableList *io = new iggFrameDataVariableList(mProvider,"Isosurface of...",iSurfaceViewSubject::KeyIsoSurfaceVar(),0,iv); - io->Complete(); - io->AddDependent(show); - iv->AddLine(io); - iv->AddLine(new iggWidgetKeyCheckBox("Optimize",iSurfaceViewSubject::KeyIsoSurfaceOptimization(),iv)); - - iggWidgetKeyRadioBox *id = new iggWidgetKeyRadioBox(1,"Reduction",0,iSurfaceViewSubject::KeyIsoSurfaceReduction(),mspage0); - id->InsertItem("None"); - id->InsertItem("Light"); - id->InsertItem("Medium"); - id->InsertItem("Heavy"); - - iggWidgetKeyRadioBox *is = new iggWidgetKeyRadioBox(1,"Smoothing",0,iSurfaceViewSubject::KeyIsoSurfaceSmoothing(),mspage0); - is->InsertItem("None"); - is->InsertItem("Light"); - is->InsertItem("Medium"); - is->InsertItem("Heavy"); + virtual void CompleteConstructionBody() + { + // + // Top half-page sub-frame + // + iggFrame *page0top = new iggFrame(this,4); + this->AddLine(page0top); + // + // Show + // + iggWidget *show = new iggWidgetShowButton(iSurfaceViewSubject::Type(),page0top); + iggFrameCurrentInstance *ci1 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeySurfaceCurrent(),iViewModule::KeySurfaceMax(),page0top); + ci1->AddDependent(this); + page0top->AddLine(show,static_cast(0),static_cast(0),ci1); + page0top->AddSpace(2); + // + // Method & flip normals + // + iggFrame *mf = new iggFrame(page0top,2); + MethodRadioBox *mb = new MethodRadioBox(iSurfaceViewSubject::KeyMethod(),mf); + iggFrame *mf2 = new iggFrame(mf,1); + mf2->AddSpace(1); + mf2->AddLine(new iggWidgetKeyColorSelection(iSurfaceViewSubject::KeyColor(),mf2,0)); + mf2->AddLine(new PrintInfoButton(mf2)); + mf2->AddSpace(3); + mf2->AddLine(new iggWidgetKeyCheckBox("Flip normals",iSurfaceViewSubject::KeyNormalsFlipped(),mf2)); + mf->AddLine(mb,mf2); + page0top->AddLine(mf,2); + page0top->AddSpace(2); + // + // Opacity + // + iggWidgetKeyFloatSlider *os = new iggWidgetKeyFloatSlider(0.0,1.0,100,0,5,"Opacity",iSurfaceViewSubject::KeyOpacity(),RenderMode::UseGlobal,page0top); + page0top->AddLine(os,3); + iggWidgetAllInstancesCheckBox *li = new iggWidgetAllInstancesCheckBox(page0top); + li->AddDependent(os); + page0top->AddLine(li,2); + page0top->AddSpace(10); - mspage0->AddLine(iv,id,is); - mspage0->AddLine(new iggWidgetKeyCheckBox("Use alternative reduction method",iSurfaceViewSubject::KeyAlternativeIsoSurfaceReductionMethod(),mspage0),3); - - mspage0->AddSpace(10); + page0top->SetColStretch(2,3); - iggWidget *il = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Level",iSurfaceViewSubject::KeyIsoSurfaceLevel(),&iSurfaceViewSubject::KeyIsoSurfaceVar(),0,RenderMode::UseGlobal,mspage0); - io->AddDependent(il); - mspage0->AddLine(il,3); - - mspage0->AddSpace(10); - mspage0->SetColStretch(3,10); + // + // Lower half-page: various method-dependent settings in a headless mBook + // + iggFrame *page0bot = new iggFrame(this,1); + this->AddLine(page0bot); - // - // Sphere & plane settings - // - iggFrame *mspage1 = new iggFrame(msflip); - msflip->AddLayer(mspage1); + iggFrameFlip *msflip = new iggFrameFlip(page0bot); + page0bot->AddLine(msflip); + page0bot->SetColStretch(0,10); + // page0bot->SetColStretch(1,1); + mb->SetFlipBuddy(msflip); + + // + // Isosurface settings + // + iggFrame *mspage0 = new iggFrame(msflip,4); + msflip->AddLayer(mspage0); - iggFrameObjectControls *sc= new iggFrameObjectControls("",iSurfaceViewSubject::KeyPosition(true),iSurfaceViewSubject::KeyPlaneDirection(),iSurfaceViewSubject::KeySize(true),mspage1); - mb->SetObjectBuddy(sc); - mspage1->AddLine(sc); + iggFrame *iv = new iggFrame(mspage0,1); + iggFrameDataVariableList *io = new iggFrameDataVariableList(mProvider,"Isosurface of...",iSurfaceViewSubject::KeyIsoSurfaceVar(),0,iv); + io->Complete(); + io->AddDependent(show); + iv->AddLine(io); + iv->AddLine(new iggWidgetKeyCheckBox("Optimize",iSurfaceViewSubject::KeyIsoSurfaceOptimization(),iv)); + + iggWidgetKeyRadioBox *id = new iggWidgetKeyRadioBox(1,"Reduction",0,iSurfaceViewSubject::KeyIsoSurfaceReduction(),mspage0); + id->InsertItem("None"); + id->InsertItem("Light"); + id->InsertItem("Medium"); + id->InsertItem("Heavy"); + + iggWidgetKeyRadioBox *is = new iggWidgetKeyRadioBox(1,"Smoothing",0,iSurfaceViewSubject::KeyIsoSurfaceSmoothing(),mspage0); + is->InsertItem("None"); + is->InsertItem("Light"); + is->InsertItem("Medium"); + is->InsertItem("Heavy"); + + mspage0->AddLine(iv,id,is); + mspage0->AddLine(new iggWidgetKeyCheckBox("Use alternative reduction method",iSurfaceViewSubject::KeyAlternativeIsoSurfaceReductionMethod(),mspage0),3); + + mspage0->AddSpace(10); + + iggWidget *il = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Level",iSurfaceViewSubject::KeyIsoSurfaceLevel(),&iSurfaceViewSubject::KeyIsoSurfaceVar(),0,RenderMode::UseGlobal,mspage0); + io->AddDependent(il); + mspage0->AddLine(il,3); + + mspage0->AddSpace(10); + mspage0->SetColStretch(3,10); + + // + // Sphere & plane settings + // + iggFrame *mspage1 = new iggFrame(msflip); + msflip->AddLayer(mspage1); + + iggFrameObjectControls *sc= new iggFrameObjectControls("",iSurfaceViewSubject::KeyPosition(true),iSurfaceViewSubject::KeyPlaneDirection(),iSurfaceViewSubject::KeySize(true),mspage1); + mb->SetObjectBuddy(sc); + mspage1->AddLine(sc); + + mspage1->AddSpace(10); + mspage0->SetColStretch(0,10); + } + }; - mspage1->AddSpace(10); - mspage0->SetColStretch(0,10); // // Paint page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Paint",icon,page1); + class PaintPage : public iggFrameDC + { + + public: + + PaintPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,1), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("surf.png"); + + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,3); + pb->AddPage("Palette",icon,pbpage0); + { + iggFrame *pf = new iggFrame(pbpage0,2); + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iSurfaceViewSubject::KeyPaintVar(),0,pf,0); + pl->InsertItem("None"); + pl->Complete(); + + SideRadioBox *ss = new SideRadioBox(pf); + ss->SetVarBuddy(pl); + + pf->AddLine(pl,ss); + pbpage0->AddLine(pf); + + pbpage0->AddSpace(10); + + iggFramePaletteSelection *ps = new iggFramePaletteSelection(true,iSurfaceViewSubject::KeyPalette(),pbpage0,0); + ss->SetPalBuddy(ps); + + pbpage0->AddLine(ps,2); + + pbpage0->AddSpace(20); + + pbpage0->SetColStretch(1,10); + pbpage0->SetColStretch(2,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(false,true,iSurfaceViewSubject::Type(),pbpage1,0); + pbpage1->AddLine(mp); + + pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; + // - // Book + // Instances page + // ************************************************ // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); + class InstancesPage : public iggFrameDC + { + + public: + + InstancesPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Instance # + // + iggFrameCurrentInstance *ci2 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeySurfaceCurrent(),iViewModule::KeySurfaceMax(),this); + ci2->AddDependent(this); + this->AddLine(ci2,new iggWidgetKeyColorSelection(iSurfaceViewSubject::KeyColor(),this,0)); + this->AddSpace(2); + // + // Color + // + this->AddLine(new iggFrameCreateDeleteButton(this,iSurfaceViewSubject::Type(),true,"instance",this)); + this->AddSpace(10); + + this->AddLine(new BatchCreateFrame(this)); + this->AddSpace(10); + + this->SetColStretch(2,10); + } + }; + // - // Palette page + // Replicate page + // ************************************************ // - iggFrame *pbpage0 = new iggFrame(pb,3); - pb->AddPage("Palette",icon,pbpage0); + class ReplicatePage : public iggFrameDC + { - iggFrame *pf = new iggFrame(pbpage0,2); - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Paint with...",iSurfaceViewSubject::KeyPaintVar(),0,pf,0); - pl->InsertItem("None"); - pl->Complete(); + public: - SideRadioBox *ss = new SideRadioBox(pf); - ss->SetVarBuddy(pl); + ReplicatePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } - pf->AddLine(pl,ss); - pbpage0->AddLine(pf); + protected: - pbpage0->AddSpace(10); + virtual void CompleteConstructionBody() + { + // + // Replicate + // + this->AddLine(new iggFrameReplicate(iSurfaceViewSubject::Type(),this)); + this->AddSpace(10); + this->SetColStretch(1,3); + } + }; +}; - iggFramePaletteSelection *ps = new iggFramePaletteSelection(true,iSurfaceViewSubject::KeyPalette(),pbpage0,0); - ss->SetPalBuddy(ps); - pbpage0->AddLine(ps,2); +using namespace iggPageSurface_Private; - pbpage0->AddSpace(20); - pbpage0->SetColStretch(1,10); - pbpage0->SetColStretch(2,3); +iggPageSurface::iggPageSurface(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Surface) +{ + const iImage *icon = iImageFactory::FindIcon("surf.png"); // - // Material page + // Main page + // ************************************************ // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); + MainPage *page0 = new MainPage(mBook,mProvider); + mBook->AddPage("Main",icon,page0); - iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(false,true,iSurfaceViewSubject::Type(),pbpage1,0); - pbpage1->AddLine(mp); - - pbpage1->AddSpace(10); - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); + // + // Paint page + // ************************************************ + // + PaintPage *page1 = new PaintPage(mBook,mProvider); + mBook->AddPage("Paint",icon,page1); // // Instances page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,3); + InstancesPage *page2 = new InstancesPage(mBook); mBook->AddPage("Instances",icon,page2); - // - // Instance # - // - iggFrameCurrentInstance *ci2 = new iggFrameCurrentInstance(false,"Instance","Instance",iViewModule::KeySurfaceCurrent(),iViewModule::KeySurfaceMax(),page2); - ci2->AddDependent(this); - page2->AddLine(ci2); - page2->AddSpace(2); - // - // Color - // - page2->AddLine(new iggWidgetKeyColorSelection(iSurfaceViewSubject::KeyColor(),page2,false,0),new iggFrameCreateDeleteButton(this,iSurfaceViewSubject::Type(),true,"instance",page2)); - page2->AddSpace(10); - - page2->AddLine(new BatchCreateFrame(page2),2); - page2->AddSpace(10); - - page2->SetColStretch(2,10); // // Replicate page // ************************************************ // - iggFrame *page3 = new iggFrame(mBook,2); + ReplicatePage *page3 = new ReplicatePage(mBook); mBook->AddPage("Replicate",icon,page3); - // - // Replicate - // - page3->AddLine(new iggFrameReplicate(iSurfaceViewSubject::Type(),page3)); - page3->AddSpace(10); - page3->SetColStretch(1,3); } #endif diff -Nru ifrit-3.3.4/shells/generic/iggpagesurface.h ifrit-3.4.2/shells/generic/iggpagesurface.h --- ifrit-3.3.4/shells/generic/iggpagesurface.h 2011-01-27 17:52:17.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagesurface.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagetensorfield.cpp ifrit-3.4.2/shells/generic/iggpagetensorfield.cpp --- ifrit-3.3.4/shells/generic/iggpagetensorfield.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagetensorfield.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -59,103 +59,189 @@ using namespace iParameter; -using namespace iParameter; -iggPageTensorField::iggPageTensorField(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::TensorField) +namespace iggPageTensorField_Private { - const iImage *icon = iImageFactory::FindIcon("tens.png"); - // // Main page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,3); - mBook->AddPage("Main",icon,page0); - // - // Show - // - page0->AddLine(new iggWidgetShowButton(iTensorFieldViewSubject::Type(),page0)); - page0->AddSpace(2); + class MainPage : public iggFrameDC + { + + public: + + MainPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,3), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() + { + // + // Show + // + this->AddLine(new iggWidgetShowButton(iTensorFieldViewSubject::Type(),this)); + this->AddSpace(2); + // + // Method & color + // + iggFrame *mc = new iggFrame(this,2); + iggWidgetKeyRadioBox *mb = new iggWidgetKeyRadioBox(1,"Method",0,iTensorFieldViewSubject::KeyMethod(),mc); + mb->InsertItem("Glyph"); + iggFrame *cf = new iggFrame(mc,2); + cf->AddSpace(1); + cf->AddLine(new iggWidgetKeyColorSelection(iTensorFieldViewSubject::KeyColor(),cf)); + cf->AddSpace(2); + cf->SetColStretch(1,1); + mc->AddLine(mb,cf); + mc->SetColStretch(1,3); + + this->AddLine(mc); + this->AddSpace(10); + // + // Glyph size + // + this->AddLine(new iggWidgetKeySizeSlider(1.0e-5,0,"Glyph size",iTensorFieldViewSubject::KeyGlyphSize(true),RenderMode::UseGlobal,this),2); + this->AddSpace(2); + // + // Tensor magnitude and downsample + // + //iggWidgetKeyRelativeFloatSlider *ms = new iggWidgetKeyRelativeFloatSlider(iDataSubject::KeyMax(),0.0,1.0,100,0,5,"Tensor magnitude",iDataSubject::KeyUpperLimit(),RenderMode::UseGlobal,page0,0); + //ms->AttachDataTypeProvider(mProvider); + iggWidgetKeyVariableLimitsSlider *ms = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Tensor magnitude",iDataSubject::KeyUpperLimit(),0,0,RenderMode::UseGlobal,this,0); + ms->SetStretch(5,10,0); + this->AddLine(ms,2); + iggWidgetKeyIntSlider *rs = new iggWidgetKeyIntSlider(1,20,5,"Sample rate",iTensorFieldViewSubject::KeyGlyphSampleRate(),RenderMode::UseGlobal,this); + rs->SetStretch(5,10,0); + this->AddLine(rs,2); + this->AddSpace(10); + + this->SetColStretch(1,10); + this->SetColStretch(2,3); + } + }; + + // - // Method & color + // Paint page + // ************************************************ // - iggFrame *mc = new iggFrame(page0,2); - iggWidgetKeyRadioBox *mb = new iggWidgetKeyRadioBox(1,"Method",0,iTensorFieldViewSubject::KeyMethod(),mc); - mb->InsertItem("Glyph"); - mc->AddLine(mb,new iggWidgetKeyColorSelection(iTensorFieldViewSubject::KeyColor(),mc,false)); - page0->AddLine(mc); - page0->AddSpace(10); - // - // Glyph size - // - page0->AddLine(new iggWidgetKeySizeSlider(1.0e-5,0,"Glyph size",iTensorFieldViewSubject::KeyGlyphSize(true),RenderMode::UseGlobal,page0),2); - page0->AddSpace(2); - // - // Tensor magnitude and downsample - // - //iggWidgetKeyRelativeFloatSlider *ms = new iggWidgetKeyRelativeFloatSlider(iDataSubject::KeyMax(),0.0,1.0,100,0,5,"Tensor magnitude",iDataSubject::KeyUpperLimit(),RenderMode::UseGlobal,page0,0); - //ms->AttachDataTypeProvider(mProvider); - iggWidgetKeyVariableLimitsSlider *ms = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Tensor magnitude",iDataSubject::KeyUpperLimit(),0,0,RenderMode::UseGlobal,page0,0); - ms->SetStretch(5,10,0); - page0->AddLine(ms,2); - iggWidgetKeyIntSlider *rs = new iggWidgetKeyIntSlider(1,20,5,"Sample rate",iTensorFieldViewSubject::KeyGlyphSampleRate(),RenderMode::UseGlobal,page0); - rs->SetStretch(5,10,0); - page0->AddLine(rs,2); - page0->AddSpace(10); + class PaintPage : public iggFrameDC + { + + public: + + PaintPage(iggFrameBase *parent, iggDataTypeProvider *scalar_provider) : iggFrameDC(parent,1), mScalarProvider(scalar_provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mScalarProvider; + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("tens.png"); + + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,3); + pb->AddPage("Palette",icon,pbpage0); + { + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mScalarProvider,"Paint with...",iTensorFieldViewSubject::KeyColorBy(),&iTensorFieldViewSubject::KeyConnectedToScalars(),pbpage0); + pl->InsertItem("None"); + pl->Complete(); + pbpage0->AddLine(pl); + pbpage0->AddSpace(10); + pbpage0->AddLine(new iggFramePaletteSelection(true,iTensorFieldViewSubject::KeyPalette(),pbpage0),2); + pbpage0->AddSpace(20); + pbpage0->SetColStretch(1,10); + pbpage0->SetColStretch(2,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + pbpage1->AddLine(new iggFrameMaterialProperties(false,false,iTensorFieldViewSubject::Type(),pbpage1)); + pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; - page0->SetColStretch(1,10); - page0->SetColStretch(2,3); // - // Paint page + // Replicate page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Paint",icon,page1); + class ReplicatePage : public iggFrameDC + { + + public: + + ReplicatePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Replicate + // + this->AddLine(new iggFrameReplicate(iTensorFieldViewSubject::Type(),this)); + this->AddSpace(10); + this->SetColStretch(1,3); + } + }; +}; + + +using namespace iggPageTensorField_Private; + + +iggPageTensorField::iggPageTensorField(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::TensorField) +{ + const iImage *icon = iImageFactory::FindIcon("tens.png"); + // - // Book + // Main page + // ************************************************ // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); + MainPage *page0 = new MainPage(mBook,mProvider); + mBook->AddPage("Main",icon,page0); + // - // Palette page + // Paint page + // ************************************************ // - iggFrame *pbpage0 = new iggFrame(pb,3); - pb->AddPage("Palette",icon,pbpage0); - - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mScalarProvider,"Paint with...",iTensorFieldViewSubject::KeyColorBy(),&iTensorFieldViewSubject::KeyConnectedToScalars(),pbpage0); - pl->InsertItem("None"); - pl->Complete(); - pbpage0->AddLine(pl); - pbpage0->AddSpace(10); - pbpage0->AddLine(new iggFramePaletteSelection(true,iTensorFieldViewSubject::KeyPalette(),pbpage0),2); - pbpage0->AddSpace(20); - pbpage0->SetColStretch(1,10); - pbpage0->SetColStretch(2,3); - // - // Material page - // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); - - pbpage1->AddLine(new iggFrameMaterialProperties(false,false,iTensorFieldViewSubject::Type(),pbpage1)); - pbpage1->AddSpace(10); - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); + PaintPage *page1 = new PaintPage(mBook,mScalarProvider); + mBook->AddPage("Paint",icon,page1); // // Replicate page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,2); + ReplicatePage *page2 = new ReplicatePage(mBook); mBook->AddPage("Replicate",icon,page2); - // - // Replicate - // - page2->AddLine(new iggFrameReplicate(iTensorFieldViewSubject::Type(),page2)); - page2->AddSpace(10); - page2->SetColStretch(1,3); } #endif diff -Nru ifrit-3.3.4/shells/generic/iggpagetensorfield.h ifrit-3.4.2/shells/generic/iggpagetensorfield.h --- ifrit-3.3.4/shells/generic/iggpagetensorfield.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagetensorfield.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagevectorfield.cpp ifrit-3.4.2/shells/generic/iggpagevectorfield.cpp --- ifrit-3.3.4/shells/generic/iggpagevectorfield.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagevectorfield.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -144,6 +144,258 @@ iggFrameObjectControls *mObjectBuddy; }; + + + // + // Main page + // ************************************************ + // + class MainPage : public iggFrameDC + { + + public: + + MainPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,3), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mProvider; + + virtual void CompleteConstructionBody() + { + // + // Show + // + this->AddLine(new iggWidgetShowButton(iVectorFieldViewSubject::Type(),this)); + this->AddSpace(2); + // + // Method & color + // + iggFrame *mc = new iggFrame(this,2); + iggWidgetKeyRadioBox *mb = new iggWidgetKeyRadioBox(1,"Method",0,iVectorFieldViewSubject::KeyMethod(),mc); + mb->InsertItem("Glyph"); + mb->InsertItem("Stream lines"); + mb->InsertItem("Stream tubes"); + mb->InsertItem("Strean bands"); + iggFrame *cf = new iggFrame(mc,2); + cf->AddSpace(1); + cf->AddLine(new iggWidgetKeyColorSelection(iVectorFieldViewSubject::KeyColor(),cf,0)); + cf->AddSpace(10); + cf->SetColStretch(1,1); + mc->AddLine(mb,cf); + mc->SetColStretch(1,3); + + this->AddLine(mc); + this->AddSpace(10); + // + // Glyph size + // + this->AddLine(new iggWidgetKeySizeSlider(1.0e-8,0,"Glyph size",iVectorFieldViewSubject::KeyGlyphSize(true),RenderMode::UseGlobal,this),2); + this->AddSpace(2); + // + // Vector magnitude and downsample + // + iggWidgetKeyVariableLimitsSlider *ms = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Vector magnitude",iDataSubject::KeyUpperLimit(),0,0,RenderMode::UseGlobal,this,-1,&iVectorFieldViewSubject::KeyDataOffset()); + ms->SetStretch(5,10,0); + this->AddLine(ms,2); + iggWidgetKeyIntSlider *rs = new iggWidgetKeyIntSlider(1,20,5,"Sample rate",iVectorFieldViewSubject::KeyGlyphSampleRate(),RenderMode::UseGlobal,this); + rs->SetStretch(5,10,0); + this->AddLine(rs,2); + this->AddSpace(10); + + this->SetColStretch(1,10); + this->SetColStretch(2,3); + } + }; + + + // + // Paint page + // ************************************************ + // + class PaintPage : public iggFrameDC + { + + public: + + PaintPage(iggFrameBase *parent, iggDataTypeProvider *scalar_provider) : iggFrameDC(parent,1), mScalarProvider(scalar_provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mScalarProvider; + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("vect.png"); + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,3); + pb->AddPage("Palette",icon,pbpage0); + { + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mScalarProvider,"Paint with...",iVectorFieldViewSubject::KeyColorBy(),&iVectorFieldViewSubject::KeyConnectedToScalars(),pbpage0); + pl->InsertItem("Vector magnitude"); + pl->InsertItem("Vorticity"); + pl->InsertItem("Divergence"); + pl->InsertItem("None"); + pl->Complete(); + pbpage0->AddLine(pl); + pbpage0->AddSpace(10); + pbpage0->AddLine(new iggFramePaletteSelection(true,iVectorFieldViewSubject::KeyPalette(),pbpage0,0),2); + pbpage0->AddSpace(20); + pbpage0->SetColStretch(1,10); + pbpage0->SetColStretch(2,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + pbpage1->AddLine(new iggFrameMaterialProperties(false,false,iVectorFieldViewSubject::Type(),pbpage1)); + pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; + + + // + // Streamlines page + // ************************************************ + // + class StreamlinesPage : public iggFrameDC + { + + public: + + StreamlinesPage(iggFrameBase *parent) : iggFrameDC(parent,1) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("vect.png"); + + // + // Book + // + iggFrameBook *sb = new iggFrameBook(this); + this->AddLine(sb); + // + // Main page + // + iggFrame *sbpage0 = new iggFrame(sb,4); + sb->AddPage("Main",icon,sbpage0); + MethodRadioBox *lt; + { + sbpage0->AddLine(new iggWidgetKeySpinBox(1,10000,"Number of streamlines",0,iVectorFieldViewSubject::KeyNumberOfStreamLines(),sbpage0)); + + lt = new MethodRadioBox(iVectorFieldViewSubject::KeySourceType(),sbpage0); + + iggWidgetKeyRadioBox *ld = new iggWidgetKeyRadioBox(2,"Streamline direction",0,iVectorFieldViewSubject::KeyLineDir(),sbpage0); + ld->InsertItem("Up stream"); + ld->InsertItem("Down stream"); + ld->InsertItem("Forward"); + ld->InsertItem("Backward"); + ld->InsertItem("Both ways"); + sbpage0->AddLine(lt,ld); + sbpage0->AddSpace(5); + + iggWidgetKeyFloatSlider *ll = new iggWidgetKeyFloatSlider(1.0e-4f,1.0f,40,1,0,"Length",iVectorFieldViewSubject::KeyLineLength(),RenderMode::UseGlobal,sbpage0); + ll->SetStretch(3,10); + iggWidgetKeyIntSlider *lw = new iggWidgetKeyIntSlider(1,10,0,"Width",iVectorFieldViewSubject::KeyTubeSize(),RenderMode::UseGlobal,sbpage0); + lw->SetStretch(3,10); + sbpage0->AddLine(ll,3); + sbpage0->AddLine(lw,3); + sbpage0->AddSpace(10); + + iggFrame *ab = new iggFrame("Adjustments",sbpage0,1); + iggWidgetKeyIntSlider *lq = new iggWidgetKeyIntSlider(1,7,0,"Line quality",iVectorFieldViewSubject::KeyLineQuality(),RenderMode::UseGlobal,ab); + lq->SetStretch(5,10); + iggWidgetKeyFloatSlider *tr = new iggWidgetKeyFloatSlider(1.0,20.0,20,0,0,"Tube range",iVectorFieldViewSubject::KeyTubeRangeFactor(),RenderMode::UseGlobal,ab); + tr->SetStretch(5,10); + iggWidgetKeyFloatSlider *tv = new iggWidgetKeyFloatSlider(1.0e-4f,1.0f,40,1,0,"Tube variation",iVectorFieldViewSubject::KeyTubeVariationFactor(),RenderMode::UseGlobal,ab); + tv->SetStretch(5,10); + ab->AddLine(lq); + ab->AddLine(tr); + ab->AddLine(tv); + sbpage0->AddLine(ab,3); + + sbpage0->AddSpace(20); + sbpage0->SetColStretch(2,10); + sbpage0->SetColStretch(3,3); + } + // + // Source page + // + iggFrame *sbpage1 = new iggFrame(sb,2); + sb->AddPage("Source",icon,sbpage1); + { + iggFrameObjectControls *sc = new iggFrameObjectControls("Source",iVectorFieldViewSubject::KeyPosition(true),iVectorFieldViewSubject::KeySourceDirection(),iVectorFieldViewSubject::KeySourceSize(true),sbpage1); + lt->SetObjectBuddy(sc); + + sbpage1->AddLine(sc); + + sbpage1->AddSpace(5); + + iggFrame *of = new iggFrame("Source object",sbpage1,1); + iggWidgetKeyCheckBox *sv = new iggWidgetKeyCheckBox("Show",iVectorFieldViewSubject::KeyShowSourceObject(),of); + iggWidgetKeyFloatSlider *so = new iggWidgetKeyFloatSlider(0.0,1.0,100,0,0,"Opacity",iVectorFieldViewSubject::KeySourceOpacity(),RenderMode::UseGlobal,of); + so->SetStretch(3,10); + of->AddLine(sv); + of->AddLine(so); + sbpage1->AddLine(of); + + sbpage1->AddSpace(10); + + sbpage1->SetColStretch(0,10); + sbpage1->SetColStretch(1,3); + } + } + }; + + // + // Replicate page + // ************************************************ + // + class ReplicatePage : public iggFrameDC + { + + public: + + ReplicatePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Replicate + // + this->AddLine(new iggFrameReplicate(iVectorFieldViewSubject::Type(),this)); + this->AddSpace(10); + this->SetColStretch(1,3); + } + }; }; @@ -158,175 +410,29 @@ // Main page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,3); + MainPage *page0 = new MainPage(mBook,mProvider); mBook->AddPage("Main",icon,page0); - // - // Show - // - page0->AddLine(new iggWidgetShowButton(iVectorFieldViewSubject::Type(),page0)); - page0->AddSpace(2); - // - // Method & color - // - iggFrame *mc = new iggFrame(page0,2); - iggWidgetKeyRadioBox *mb = new iggWidgetKeyRadioBox(1,"Method",0,iVectorFieldViewSubject::KeyMethod(),mc); - mb->InsertItem("Glyph"); - mb->InsertItem("Stream lines"); - mb->InsertItem("Stream tubes"); - mb->InsertItem("Strean bands"); - mc->AddLine(mb,new iggWidgetKeyColorSelection(iVectorFieldViewSubject::KeyColor(),mc,false,0)); - page0->AddLine(mc); - page0->AddSpace(10); - // - // Glyph size - // - page0->AddLine(new iggWidgetKeySizeSlider(1.0e-8,0,"Glyph size",iVectorFieldViewSubject::KeyGlyphSize(true),RenderMode::UseGlobal,page0),2); - page0->AddSpace(2); - // - // Vector magnitude and downsample - // - iggWidgetKeyVariableLimitsSlider *ms = new iggWidgetKeyVariableLimitsSlider(mProvider,5,"Vector magnitude",iDataSubject::KeyUpperLimit(),0,0,RenderMode::UseGlobal,page0,-1,&iVectorFieldViewSubject::KeyDataOffset()); - ms->SetStretch(5,10,0); - page0->AddLine(ms,2); - iggWidgetKeyIntSlider *rs = new iggWidgetKeyIntSlider(1,20,5,"Sample rate",iVectorFieldViewSubject::KeyGlyphSampleRate(),RenderMode::UseGlobal,page0); - rs->SetStretch(5,10,0); - page0->AddLine(rs,2); - page0->AddSpace(10); - - page0->SetColStretch(1,10); - page0->SetColStretch(2,3); // // Paint page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); + PaintPage *page1 = new PaintPage(mBook,mScalarProvider); mBook->AddPage("Paint",icon,page1); - // - // Book - // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); - // - // Palette page - // - iggFrame *pbpage0 = new iggFrame(pb,3); - pb->AddPage("Palette",icon,pbpage0); - - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mScalarProvider,"Paint with...",iVectorFieldViewSubject::KeyColorBy(),&iVectorFieldViewSubject::KeyConnectedToScalars(),pbpage0); - pl->InsertItem("Vector magnitude"); - pl->InsertItem("Vorticity"); - pl->InsertItem("Divergence"); - pl->InsertItem("None"); - pl->Complete(); - pbpage0->AddLine(pl); - pbpage0->AddSpace(10); - pbpage0->AddLine(new iggFramePaletteSelection(true,iVectorFieldViewSubject::KeyPalette(),pbpage0,0),2); - pbpage0->AddSpace(20); - pbpage0->SetColStretch(1,10); - pbpage0->SetColStretch(2,3); - // - // Material page - // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); - - pbpage1->AddLine(new iggFrameMaterialProperties(false,false,iVectorFieldViewSubject::Type(),pbpage1)); - pbpage1->AddSpace(10); - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); // // Streamlines page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,1); + StreamlinesPage *page2 = new StreamlinesPage(mBook); mBook->AddPage("Streamlines",icon,page2); - // - // Book - // - iggFrameBook *sb = new iggFrameBook(page2); - page2->AddLine(sb); - // - // Main page - // - iggFrame *sbpage0 = new iggFrame(sb,4); - sb->AddPage("Main",icon,sbpage0); - - sbpage0->AddLine(new iggWidgetKeySpinBox(1,10000,"Number of streamlines",0,iVectorFieldViewSubject::KeyNumberOfStreamLines(),sbpage0)); - - MethodRadioBox *lt = new MethodRadioBox(iVectorFieldViewSubject::KeySourceType(),sbpage0); - - iggWidgetKeyRadioBox *ld = new iggWidgetKeyRadioBox(2,"Streamline direction",0,iVectorFieldViewSubject::KeyLineDir(),sbpage0); - ld->InsertItem("Up stream"); - ld->InsertItem("Down stream"); - ld->InsertItem("Forward"); - ld->InsertItem("Backward"); - ld->InsertItem("Both ways"); - sbpage0->AddLine(lt,ld); - sbpage0->AddSpace(5); - - iggWidgetKeyFloatSlider *ll = new iggWidgetKeyFloatSlider(1.0e-4f,1.0f,40,1,0,"Length",iVectorFieldViewSubject::KeyLineLength(),RenderMode::UseGlobal,sbpage0); - ll->SetStretch(3,10); - iggWidgetKeyIntSlider *lw = new iggWidgetKeyIntSlider(1,10,0,"Width",iVectorFieldViewSubject::KeyTubeSize(),RenderMode::UseGlobal,sbpage0); - lw->SetStretch(3,10); - sbpage0->AddLine(ll,3); - sbpage0->AddLine(lw,3); - sbpage0->AddSpace(10); - - iggFrame *ab = new iggFrame("Adjustments",sbpage0,1); - iggWidgetKeyIntSlider *lq = new iggWidgetKeyIntSlider(1,7,0,"Line quality",iVectorFieldViewSubject::KeyLineQuality(),RenderMode::UseGlobal,ab); - lq->SetStretch(5,10); - iggWidgetKeyFloatSlider *tr = new iggWidgetKeyFloatSlider(1.0,20.0,20,0,0,"Tube range",iVectorFieldViewSubject::KeyTubeRangeFactor(),RenderMode::UseGlobal,ab); - tr->SetStretch(5,10); - iggWidgetKeyFloatSlider *tv = new iggWidgetKeyFloatSlider(1.0e-4f,1.0f,40,1,0,"Tube variation",iVectorFieldViewSubject::KeyTubeVariationFactor(),RenderMode::UseGlobal,ab); - tv->SetStretch(5,10); - ab->AddLine(lq); - ab->AddLine(tr); - ab->AddLine(tv); - sbpage0->AddLine(ab,3); - - sbpage0->AddSpace(20); - sbpage0->SetColStretch(2,10); - sbpage0->SetColStretch(3,3); - // - // Source page - // - iggFrame *sbpage1 = new iggFrame(sb,2); - sb->AddPage("Source",icon,sbpage1); - - iggFrameObjectControls *sc = new iggFrameObjectControls("Source",iVectorFieldViewSubject::KeyPosition(true),iVectorFieldViewSubject::KeySourceDirection(),iVectorFieldViewSubject::KeySourceSize(true),sbpage1); - lt->SetObjectBuddy(sc); - - sbpage1->AddLine(sc); - - sbpage1->AddSpace(5); - - iggFrame *of = new iggFrame("Source object",sbpage1,1); - iggWidgetKeyCheckBox *sv = new iggWidgetKeyCheckBox("Show",iVectorFieldViewSubject::KeyShowSourceObject(),of); - iggWidgetKeyFloatSlider *so = new iggWidgetKeyFloatSlider(0.0,1.0,100,0,0,"Opacity",iVectorFieldViewSubject::KeySourceOpacity(),RenderMode::UseGlobal,of); - so->SetStretch(3,10); - of->AddLine(sv); - of->AddLine(so); - sbpage1->AddLine(of); - - sbpage1->AddSpace(10); - - sbpage1->SetColStretch(0,10); - sbpage1->SetColStretch(1,3); // // Replicate page // ************************************************ // - iggFrame *page3 = new iggFrame(mBook,2); + ReplicatePage *page3 = new ReplicatePage(mBook); mBook->AddPage("Replicate",icon,page3); - // - // Replicate - // - page3->AddLine(new iggFrameReplicate(iVectorFieldViewSubject::Type(),page3)); - page3->AddSpace(10); - page3->SetColStretch(1,3); } #endif diff -Nru ifrit-3.3.4/shells/generic/iggpagevectorfield.h ifrit-3.4.2/shells/generic/iggpagevectorfield.h --- ifrit-3.3.4/shells/generic/iggpagevectorfield.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagevectorfield.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpageview.cpp ifrit-3.4.2/shells/generic/iggpageview.cpp --- ifrit-3.3.4/shells/generic/iggpageview.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageview.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -101,7 +101,6 @@ using namespace iParameter; -using namespace iParameter; namespace iggPageView_Private @@ -226,190 +225,67 @@ // // Animation controls // - class AnimateButton : public iggWidgetSimpleButton + class AnimationStyleBox : public iggWidgetKeyRadioBox { public: - AnimateButton(iggFrame *parent) : iggWidgetSimpleButton("Animate",parent) - { - this->SetBaloonHelp("Start animation"); - } + AnimationStyleBox(iggFrame *parent) : iggWidgetKeyRadioBox(1,"Style",0,iAnimator::KeyStyle(),parent){} protected: virtual void UpdateWidgetBody() { - mWidgetHelper->Enable(this->GetShell()->GetControlModule()->GetViewModule()->GetReader()->IsFileAnimatable()); - } - - virtual void Execute() - { - this->GetMainWindow()->GetDialogAnimatingProgress()->Animate(); - this->GetShell()->GetControlModule()->Render(); - - if(this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetErrorStatus()->IsError()) - { - this->GetMainWindow()->PopupWindow("Animation completed with the following message:\n"+this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetErrorStatus()->Message()); - } - } - }; - - - // - // Helper classes that create a dialog with a single image if Area is clicked - // - class ViewImageDialog : public iggDialog - { - - public: - - ViewImageDialog(iggMainWindow *parent, const iImage &image) : iggDialog(parent,DialogFlag::Modal,0,"View Image",0,1) - { - mArea = new iggWidgetImageArea(image,false,mFrame); - mFrame->AddLine(mArea); - } - - void SetImage(const iImage& image) - { - mArea->SetImage(image,false); - mArea->SetFixedSize(image.Width(),image.Height()); - } - - virtual const iString& GetToolTip() const - { - static const iString tmp = "Shows a full image"; - return tmp; - } - - protected: - - iggWidgetImageArea *mArea; - }; - - - // - // View image area - // - class ViewImageArea : public iggWidgetImageArea - { - - public: - - ViewImageArea(iggFrame *parent) : iggWidgetImageArea(iImage(),false,parent) - { - mSubject->SetBackgroundColor(iColor(100,100,100)); - } - }; - - - // - // Load title/logo button - // - class LoadButton : public iggWidgetKeyFileNameButton - { - - public: - - LoadButton(iggWidgetImageArea *view, const iString &header, const iObjectKey &filekey, const iObjectKey &imagekey, iggFrame *parent) : iggWidgetKeyFileNameButton("Load",header,"Images (*.jpg *.jpeg *.pnm *.bmp *.png *.tif *.tiff)",filekey,parent), mImageKey(imagekey), mView(view) - { - } - - virtual void QueryValue(iString& val) const - { - static const iImage nullImage = iImage(); - - iggWidgetKeyFileNameButton::QueryValue(val); - if(val.IsEmpty()) return; - - iImage im; - iString ws; - this->GetShell()->GetControlModule()->PackCommand(ws,this->GetKey(),val); - this->GetShell()->GetControlModule()->Execute(ws,false); - if(this->GetShell()->GetControlModule()->QueryValue(mImageKey,im) && !im.IsEmpty()) - { - mView->SetImage(im,false); - } - else - { - mView->SetImage(nullImage,false); - this->GetMainWindow()->PopupWindow("Unable to load image from the file.\n The file may be corrupted."); - } - mView->UpdateWidget(); + this->iggWidgetKeyRadioBox::UpdateWidgetBody(); + this->Enable(!this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->UsingScript()); } - - protected: - - const iObjectKey &mImageKey; - iggWidgetImageArea *mView; }; - // - // Remove title/logo button - // - class RemoveButton : public iggWidgetKeyFileNameButton + class AnimationFramesSlider : public iggWidgetKeyLargeIntSlider { - + public: - RemoveButton(iggWidgetImageArea *view, const iObjectKey &key, iggFrame *parent) : iggWidgetKeyFileNameButton("Remove","","",key,parent), mView(view) - { - } - - virtual void QueryValue(iString&) const - { - static const iImage nullImage = iImage(); - - iString ws; - this->GetShell()->GetControlModule()->PackCommand(ws,this->GetKey(),iString()); - this->GetShell()->GetControlModule()->Execute(ws,false); - mView->SetImage(nullImage,false); - mView->UpdateWidget(); - mWidgetHelper->Enable(!mView->GetImage().IsEmpty()); - } + AnimationFramesSlider(iggFrame *parent) : iggWidgetKeyLargeIntSlider(1,150,5,"Frames per file",iAnimator::KeyNumberOfFrames(),RenderMode::NoRender,parent){} protected: virtual void UpdateWidgetBody() { - mWidgetHelper->Enable(!mView->GetImage().IsEmpty()); - this->iggWidgetKeyFileNameButton::UpdateWidgetBody(); + this->iggWidgetKeyLargeIntSlider::UpdateWidgetBody(); + this->Enable(!this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->UsingScript()); } - - iggWidgetImageArea *mView; }; - // - // View title/logo button - // - class ViewButton : public iggWidgetLaunchButton + class AnimateButton : public iggWidgetSimpleButton { public: - ViewButton(iggWidgetImageArea *view, iggFrame *parent) : iggWidgetLaunchButton(static_cast(0),"View",parent,true), mView(view) + AnimateButton(iggFrame *parent) : iggWidgetSimpleButton("Animate",parent) { - mDialog = mWindow = new ViewImageDialog(this->GetMainWindow(),mView->GetImage()); + this->SetBaloonHelp("Start animation"); } protected: virtual void UpdateWidgetBody() { - mWidgetHelper->Enable(!mView->GetImage().IsEmpty()); - this->iggWidgetLaunchButton::UpdateWidgetBody(); + mWidgetHelper->Enable(this->GetShell()->GetControlModule()->GetViewModule()->GetReader()->IsFileAnimatable()); } - virtual void OnVoid1Body() + virtual void Execute() { - mWindow->SetImage(mView->GetImage()); - this->iggWidgetLaunchButton::OnVoid1Body(); - } + this->GetMainWindow()->GetDialogAnimatingProgress()->Animate(); + this->GetShell()->GetControlModule()->Render(); - iggWidgetImageArea *mView; - ViewImageDialog *mWindow; + if(this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetErrorStatus()->IsError()) + { + this->GetMainWindow()->PopupWindow("Animation completed with the following message:\n"+this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetErrorStatus()->Message()); + } + } }; @@ -465,6 +341,11 @@ WindowListDialog(iggMainWindow *parent) : iggDialogAuto(parent,"Windows",1) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mFrame->AddLine(new WindowList(mFrame)); this->ResizeContents(100,200); } @@ -569,12 +450,18 @@ mFlipper = new iggWidgetLogoFlipper(mFrame); mFrame->AddLine(0,mFlipper); mFrame->AddLine(new iggWidgetTextArea(iString("%b%+")+(create?"Creat":"Delet")+"ing window...",mFrame),3); + + this->CompleteConstruction(); } - virtual void Show(bool s) + void CompleteConstructionBody() + { + } + + virtual void ShowBody(bool s) { if(s) mFlipper->Start(); else mFlipper->Abort(); - iggDialog::Show(s); + iggDialog::ShowBody(s); } protected: @@ -893,6 +780,11 @@ RulerScaleDialog(iggMainWindow *parent) : iggDialogAuto(parent,"Ruler Scale",2), iggRenderWindowObserver(mFrame) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mFrame->AddLine(new iggWidgetTextArea("Scale",mFrame),new iggWidgetKeyFloatLineEdit("",iViewModule::KeyRulerScale(),RenderMode::UseGlobal,mFrame)); mFrame->AddLine(new iggWidgetTextArea("Title",mFrame),new iggWidgetKeyTextLineEdit(false,"",iViewModule::KeyRulerTitle(),RenderMode::UseGlobal,mFrame)); mFrame->AddSpace(10); @@ -969,6 +861,11 @@ RecordLabelDialog(iggMainWindow *parent) : iggDialogAuto(parent,"Record Label Properties",3) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mFrame->AddLine(new iggWidgetTextArea("Name",mFrame),new iggWidgetKeyTextLineEdit(false,"",iViewModule::KeyLabelName(),RenderMode::UseGlobal,mFrame),static_cast(0)); mFrame->AddLine(new iggWidgetTextArea("Unit",mFrame),new iggWidgetKeyTextLineEdit(false,"",iViewModule::KeyLabelUnit(),RenderMode::UseGlobal,mFrame),static_cast(0)); mFrame->AddLine(new iggWidgetTextArea("Scale",mFrame),new iggWidgetKeyFloatLineEdit("",iViewModule::KeyLabelScale(),RenderMode::UseGlobal,mFrame),static_cast(0)); @@ -1120,71 +1017,6 @@ }; - class StepOnPath : public iggWidgetKeyIntSlider, public iggRenderWindowObserver - { - - public: - - StepOnPath(iggFrame *parent) : iggWidgetKeyIntSlider(0,100,5,"Step on path",iAnimator::KeyPositionOnPath(),RenderMode::UseGlobal,parent), iggRenderWindowObserver(parent) - { - } - - protected: - - virtual void OnRenderWindowModified() - { - this->iggRenderWindowObserver::mParent->UpdateWidget(); - this->GetMainWindow()->ProcessEvents(); - } - - virtual void UpdateWidgetBody() - { - iAnimator *an = this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator(); - this->Enable(an->GetStyle() == 4); - iRequiredCast(INFO,an->GetObserver())->AddDependent(this); - this->SetRange(0,this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetNumberOfCameraPathSteps()-1); - this->iggWidgetKeyIntSlider::UpdateWidgetBody(); - } - }; - - - class PlayDemo : public iggWidgetKeyToolButton - { - - public: - - PlayDemo(iggFrame *parent) : iggWidgetKeyToolButton("",iAnimator::KeyCameraPathDemo(),parent) - { - mSubject->SetIcon(*iImageFactory::FindIcon("moveright.png")); - mInDemo = false; - } - - virtual bool ExecuteControl(bool final, bool val) - { - mInDemo = !mInDemo; - if(mInDemo) - { - mSubject->SetIcon(*iImageFactory::FindIcon("er_stop.png")); - return this->iggWidgetKeyToolButton::ExecuteControl(final,val); - } - else - { - mSubject->SetIcon(*iImageFactory::FindIcon("moveright.png")); - this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->StopCameraPathDemo(); - return true; - } - } - - protected: - - virtual void UpdateWidgetBody() - { - this->Enable(this->GetShell()->GetControlModule()->GetViewModule()->GetAnimator()->GetStyle() == 4); - } - - bool mInDemo; - }; - // // Window size dialog and its widgets // @@ -1287,6 +1119,11 @@ WindowSizeDialog(iggMainWindow *parent) : iggDialog(parent,DialogFlag::Modal,0,"Visualization Window Size",0,2,"Set") { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + void CompleteConstructionBody() + { mBoxes[0] = new iggWidgetSimpleSpinBox(120,32768,1,"",mFrame); mBoxes[1] = new iggWidgetSimpleSpinBox(120,32768,1,"",mFrame); @@ -1302,7 +1139,7 @@ mBoxes[1]->SetBaloonHelp("Set window height","Set the height of the current visualization window."); } - virtual void Show(bool s) + virtual void ShowBody(bool s) { if(s) { @@ -1310,7 +1147,7 @@ mBoxes[0]->SetValue(size[0]); mBoxes[1]->SetValue(size[1]); } - iggDialog::Show(s); + iggDialog::ShowBody(s); } protected: @@ -1392,7 +1229,7 @@ { if(this->GetMainWindow()->PopupWindow("Please confirm: reseting the counter will overwrite the animation files created so far.",PopupWindow::Message,"Reset","Cancel") == 0) { - this->GetShell()->GetControlModule()->GetViewModule()->GetWriter()->ResetAnimationImageIndex(); + //this->GetShell()->GetControlModule()->GetViewModule()->GetWriter()->ResetAnimationImageIndex(); } } }; @@ -1560,144 +1397,29 @@ this->GetShell()->GetControlModule()->GetParallelManager()->SetNumberOfProcessors((i==0)?this->GetShell()->GetControlModule()->GetParallelManager()->GetMinNumberOfProcessors():this->GetShell()->GetControlModule()->GetParallelManager()->GetMaxNumberOfProcessors()); } }; -}; - -using namespace iggPageView_Private; - - -iggPageView::iggPageView(iggFrameBase *parent) : iggPageMain(parent) -{ - int i; - const iImage *icon = iImageFactory::FindIcon("view.png"); - - mWindowSizeDialog = new WindowSizeDialog(this->GetMainWindow()); - mWindowListDialog = new WindowListDialog(this->GetMainWindow()); // - // Main page - // ************************************************ + // Lights page // + class SceneLightsPage : public iggFrameDC { - iggFrame *page0 = new iggFrame(mBook,3); - mBook->AddPage("Main",icon,page0); - - page0->AddSpace(2); - - iggWidgetKeyTextComboBox *ur = new iggWidgetKeyTextComboBox(0,"Update rate",0,iViewModule::KeyUpdateRate(),page0); - ur->InsertItem("Non-interactive"); - ur->InsertItem(" 3 frames/sec"); - ur->InsertItem("10 frames/sec"); - ur->InsertItem("30 frames/sec"); - ur->SetInvalidValue(0); - page0->AddLine(ur,2); - page0->AddSpace(2); - - iggFrame *pf = new iggFrame("Projection",page0,1); - pf->AddLine(new iggWidgetKeyCheckBox("Parallel",iCamera::KeyParallelProjection(),pf)); - iggWidgetKeyCheckBox *pp = new iggWidgetKeyCheckBox("Perspective",iCamera::KeyParallelProjection(),pf); - pf->AddLine(pp); - pp->SetReverse(true); - if(this->GetShell()->GetControlModule()->GetParallelManager()->GetMaxNumberOfProcessors() > 1) - { - iggWidget *peb = new ParallelExecutionBox(page0); - page0->AddLine(pf,peb); - } - else + public: + + SceneLightsPage(iggFrameBase *parent) : iggFrameDC(parent,3) { - page0->AddLine(pf); + if(this->ImmediateConstruction()) this->CompleteConstruction(); } - page0->AddLine(new iggWidgetKeyExecButton("Reset view",iCamera::KeyReset(),page0),new iggWidgetLaunchButton(mWindowSizeDialog,"Set window size",page0)); - page0->AddSpace(2); - - iggFrame *fb = new iggFrame("Features",page0,1); - fb->AddLine(new iggWidgetKeyCheckBox("Bounding box",iViewModule::KeyBoundingBox(),fb)); - fb->AddLine(new ShowRecordLabelCheckBox(fb)); - fb->AddLine(new ShowRulerCheckBox(fb)); - fb->AddLine(new iggWidgetKeyCheckBox("Color bars",iViewModule::KeyColorBars(),fb)); - fb->AddLine(new iggWidgetKeyCheckBox("Measuring box",iViewModule::KeyMeasuringBox(),fb)); - fb->AddLine(new iggWidgetKeyCheckBox("Alignment axes",iViewModule::KeyCameraAlignmentLabel(),fb)); - - iggFrame *fb2 = new iggFrame(page0,1); - iggWidgetKeyRadioBox *isb = new iggWidgetKeyRadioBox(1,"Interactor style",0,iViewModule::KeyInteractorStyle(),fb2); - isb->InsertItem("Trackball"); - isb->InsertItem("Joystick"); - isb->InsertItem("Flight"); - isb->InsertItem("Keyboard"); - fb2->AddLine(isb); - - //isb->SetItem("Flight",2,false); - - iggFrame *fb3 = new iggFrame("Background",fb2,1); - iggWidgetKeyColorSelection *wid = new iggWidgetKeyColorSelection(iViewModule::KeyBackgroundColor(),fb3,true); - if(this->GetMainWindow()->GetDialogImageComposer() != 0) wid->AddDependent(this->GetMainWindow()->GetDialogImageComposer()->GetArea()); - fb3->AddLine(wid); - fb3->AddLine(new iggWidgetKeyFileNameButton(" Load wallpaper image ","Load image","Images (*.jpg *.jpeg *.pnm *.bmp *.png *.tif *.tiff)",iViewModule::KeyBackgroundImage(),fb3)); - fb2->AddLine(fb3); - - page0->AddLine(fb,fb2); - - page0->AddSpace(10); - page0->SetColStretch(2,10); - } - - // - // Scene page - // ************************************************ - // - { - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Scene",icon,page1); - // - // Book - // - iggFrameBook *sb = new iggFrameBook(page1); - page1->AddLine(sb); - // - // Camera page - // - { - iggFrame *sbpage0 = new iggFrame(sb,3); - sb->AddPage("Camera",icon,sbpage0); + protected: - iggFrame *vf = new iggFrame("View angle",sbpage0,1); - vf->AddSpace(1); - vf->AddLine(new iggWidgetKeyFloatSlider(10.0,120.0,110,0,3,"",iCamera::KeyViewAngle(),RenderMode::UseGlobal,vf)); - vf->AddLine(new iggWidgetKeyCheckBox("Vertical",iCamera::KeyViewAngleVertical(),vf)); - vf->AddSpace(10); - - iggFrame *cb = new iggFrame("Camera orientatioin",sbpage0,3); - cb->AddLine(static_cast(0),new MoveCameraButton(2,cb),static_cast(0)); - cb->AddLine(new MoveCameraButton(-1,cb),static_cast(0),new MoveCameraButton(1,cb)); - cb->AddLine(static_cast(0),new MoveCameraButton(-2,cb),static_cast(0)); - - sbpage0->AddLine(vf,cb); - sbpage0->AddSpace(2); - - iggFrame *crf = new iggFrame("Camera clipping range",sbpage0,5); - iggWidgetKeyCheckBox *cfa = new iggWidgetKeyCheckBox("Automatic",iCamera::KeyClippingRangeAuto(),crf); - crf->AddLine(cfa,3); - crf->AddLine(new ClippingRangeButton(0,cfa,crf),new ClippingRangeButton(1,cfa,crf),new iggWidgetTextArea("Adjust clipping range",crf),new ClippingRangeButton(2,cfa,crf),new ClippingRangeButton(3,cfa,crf)); - crf->AddLine(new ClippingRangeDisplay(0,crf),2,new iggWidgetTextArea("(in units of focal distance)",crf),1,new ClippingRangeDisplay(1,crf),2); - sbpage0->AddLine(crf,2); - sbpage0->AddSpace(2); - - sbpage0->AddSpace(4); - sbpage0->SetColStretch(2,10); - } - // - // Lights page - // + virtual void CompleteConstructionBody() { - iggFrame *sbpage1 = new iggFrame(sb,3); - sb->AddPage("Lights",icon,sbpage1); - - iggFrame *db = new iggFrame("Main light direction",sbpage1,1); + iggFrame *db = new iggFrame("Main light direction",this,1); db->AddLine(new iggWidgetKeyTrackBall(iViewModule::KeyLightAngles(),true,RenderMode::UseGlobal,db)); - sbpage1->AddLine(db); + this->AddLine(db); - iggFrame *ib = new iggFrame("Intensity",sbpage1,1); + iggFrame *ib = new iggFrame("Intensity",this,1); iggWidgetKeyFloatSlider *mli = new iggWidgetKeyFloatSlider(0.01f,10.0f,200,1,0,"Main light",iViewModule::KeyLightIntensity(),RenderMode::UseGlobal,ib,0); iggWidgetKeyFloatSlider *fli = new iggWidgetKeyFloatSlider(0.01f,10.0f,200,1,0,"Fill light",iViewModule::KeyLightIntensity(),RenderMode::UseGlobal,ib,1); iggWidgetKeyFloatSlider *hli = new iggWidgetKeyFloatSlider(0.01f,10.0f,200,1,0,"Head light",iViewModule::KeyLightIntensity(),RenderMode::UseGlobal,ib,2); @@ -1709,30 +1431,45 @@ ib->AddLine(mli); ib->AddLine(fli); ib->AddLine(hli); - sbpage1->AddLine(ib,2); + this->AddLine(ib,2); + + this->AddSpace(10); + this->SetColStretch(1,10); + this->SetColStretch(2,3); + } + }; + + + // + // Multi-view modes page + // + class SceneModesPage : public iggFrameDC + { + + public: + + SceneModesPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: - sbpage1->AddSpace(10); - sbpage1->SetColStretch(1,10); - sbpage1->SetColStretch(2,3); - } - // - // Special modes page - // + virtual void CompleteConstructionBody() { - iggFrame *sbpage2 = new iggFrame(sb,3); - sb->AddPage("Special",icon,sbpage2); + const iImage *icon = iImageFactory::FindIcon("view.png"); + // // Book // - iggFrameBook *vb = new iggFrameBook(sbpage2); - sbpage2->AddLine(vb); + iggFrameBook *vb = new iggFrameBook(this); + this->AddLine(vb); + // + // Stereo mode page + // + iggFrame *vbpage0 = new iggFrame(vb,3); + vb->AddPage("Stereo",icon,vbpage0); { - // - // Stereo mode page - // - iggFrame *vbpage0 = new iggFrame(vb,3); - vb->AddPage("Stereo",icon,vbpage0); - StereoModeSelector *sm = new StereoModeSelector(vbpage0); vbpage0->AddLine(sm,new iggWidgetTextArea("",vbpage0)); vbpage0->AddLine(new iggWidgetKeyCheckBox("Show alighnment marks in a dual window mode",iViewModule::KeyStereoAlignmentMarks(),vbpage0),2); @@ -1750,456 +1487,664 @@ // // Multi view mode page // - { - iggFrame *vbpage1 = iggExtensionFactory::CreateMultiViewFrame(vb); - if(vbpage1 != 0) vb->AddPage("Multi view",icon,vbpage1); - } + iggFrame *vbpage1 = iggExtensionFactory::CreateMultiViewFrame(vb); + if(vbpage1 != 0) vb->AddPage("Multi view",icon,vbpage1); } - // - // Color bars page - // + }; + + + // + // Color bars page + // + class SceneColorBarsPage : public iggFrameDC + { + + public: + + SceneColorBarsPage(iggFrameBase *parent) : iggFrameDC(parent,3) { - iggFrame *sbpage3 = new iggFrame(sb,3); - sb->AddPage("Color bars",icon,sbpage3); + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: - iggWidgetKeyCheckBox *acb = new iggWidgetKeyCheckBox("Automatic",iColorBars::KeyAutomatic(),sbpage3); + virtual void CompleteConstructionBody() + { + iggWidgetKeyCheckBox *acb = new iggWidgetKeyCheckBox("Automatic",iColorBars::KeyAutomatic(),this); - sbpage3->AddLine(acb,2); - sbpage3->AddLine(new ColorBarFrame(acb,"Left bar",iColorBars::KeyBarLeft(),sbpage3),new ColorBarFrame(acb,"Right bar",iColorBars::KeyBarRight(),sbpage3)); + this->AddLine(acb,2); + this->AddLine(new ColorBarFrame(acb,"Left bar",iColorBars::KeyBarLeft(),this),new ColorBarFrame(acb,"Right bar",iColorBars::KeyBarRight(),this)); - sbpage3->AddSpace(10); - iggFrame *tmp = new iggFrame(sbpage3,2); + this->AddSpace(10); + iggFrame *tmp = new iggFrame(this,2); tmp->AddLine(new iggWidgetTextArea("Side offset",tmp),new iggWidgetKeyFloatSlider(0.01,0.3,29,0,0,"",iColorBars::KeySideOffset(),RenderMode::UseGlobal,tmp)); tmp->AddLine(new iggWidgetTextArea("Bar size",tmp),new iggWidgetKeyFloatSlider(0.2,1.0,8,0,0,"",iColorBars::KeySize(),RenderMode::UseGlobal,tmp)); tmp->SetColStretch(1,10); - sbpage3->AddLine(tmp,3); + this->AddLine(tmp,3); - sbpage3->SetColStretch(2,10); + this->SetColStretch(2,10); } - // - // Clip plane page - // + }; + + + // + // Tools page + // + class SceneToolsPage : public iggFrameDC + { + + public: + + SceneToolsPage(iggFrameBase *parent) : iggFrameDC(parent,3) { - iggFrame *sbpage4 = new iggFrame(sb,3); - sb->AddPage("Clip plane",icon,sbpage4); + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: - sbpage4->AddLine(new iggWidgetKeyCheckBox("Use clip plane",iViewModule::KeyClipPlane(),sbpage4)); - sbpage4->AddSpace(2); + virtual void CompleteConstructionBody() + { + // + // Clip plane + // + iggFrame *cpf = new iggFrame("Clip plane",this,3); + cpf->AddLine(new iggWidgetKeyCheckBox("Use clip plane",iViewModule::KeyClipPlane(),cpf)); + cpf->AddSpace(2); - iggFrame *cb = new iggFrame("Clip plane direction",sbpage4,1); + iggFrame *cb = new iggFrame("Clip plane direction",cpf,1); cb->AddLine(new iggWidgetKeyTrackBall(iViewModule::KeyClipPlaneDirection(),false,RenderMode::UseGlobal,cb)); - sbpage4->AddLine(cb); - sbpage4->AddLine(new iggWidgetKeyFloatSlider(-2.0f,2.0f,400,0,0,"Clip plane distance",iViewModule::KeyClipPlaneDistance(),RenderMode::UseGlobal,sbpage4),2); - sbpage4->AddLine(new iggWidgetKeyCheckBox("Show as glass plane",iViewModule::KeyGlassClipPlane(),sbpage4)); - - sbpage4->AddSpace(10); - sbpage4->SetColStretch(1,10); - sbpage4->SetColStretch(2,3); + cpf->AddLine(cb); + cpf->AddLine(new iggWidgetKeyFloatSlider(-2.0f,2.0f,400,0,0,"Clip plane distance",iViewModule::KeyClipPlaneDistance(),RenderMode::UseGlobal,cpf),2); + cpf->AddLine(new iggWidgetKeyCheckBox("Show as glass plane",iViewModule::KeyGlassClipPlane(),cpf)); + + this->AddLine(cpf); + this->AddSpace(2); + + // + // Measuring box + // + iggFrame *mbf = new iggFrame("Measuring box",this,3); + mbf->AddLine(new iggWidgetKeyCheckBox("Measuring box",iViewModule::KeyMeasuringBox(),mbf)); + this->AddLine(mbf); + + this->AddSpace(10); + this->SetColStretch(0,10); + this->SetColStretch(1,3); } - } + }; + + // + // Scene page + // ************************************************ + // + class ScenePage : public iggFrameDC + { + + public: + + ScenePage(iggFrameBase *parent) : iggFrameDC(parent,1) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("view.png"); + + // + // Book + // + iggFrameBook *sb = new iggFrameBook(this); + this->AddLine(sb); + // + // Camera page (created immediately) + // + iggFrame *sbpage0 = new iggFrame(sb,3); + sb->AddPage("Camera",icon,sbpage0); + { + iggFrame *vf = new iggFrame("View angle",sbpage0,1); + vf->AddSpace(1); + vf->AddLine(new iggWidgetKeyFloatSlider(10.0,120.0,110,0,3,"",iCamera::KeyViewAngle(),RenderMode::UseGlobal,vf)); + vf->AddLine(new iggWidgetKeyCheckBox("Vertical",iCamera::KeyViewAngleVertical(),vf)); + vf->AddSpace(10); + + iggFrame *cb = new iggFrame("Camera orientatioin",sbpage0,3); + cb->AddLine(static_cast(0),new MoveCameraButton(2,cb),static_cast(0)); + cb->AddLine(new MoveCameraButton(-1,cb),static_cast(0),new MoveCameraButton(1,cb)); + cb->AddLine(static_cast(0),new MoveCameraButton(-2,cb),static_cast(0)); + + sbpage0->AddLine(vf,cb); + sbpage0->AddSpace(2); + + iggFrame *crf = new iggFrame("Camera clipping range",sbpage0,5); + iggWidgetKeyCheckBox *cfa = new iggWidgetKeyCheckBox("Automatic",iCamera::KeyClippingRangeAuto(),crf); + crf->AddLine(cfa,3); + crf->AddLine(new ClippingRangeButton(0,cfa,crf),new ClippingRangeButton(1,cfa,crf),new iggWidgetTextArea("Adjust clipping range",crf),new ClippingRangeButton(2,cfa,crf),new ClippingRangeButton(3,cfa,crf)); + crf->AddLine(new ClippingRangeDisplay(0,crf),2,new iggWidgetTextArea("(in units of focal distance)",crf),1,new ClippingRangeDisplay(1,crf),2); + sbpage0->AddLine(crf,2); + sbpage0->AddSpace(2); + + sbpage0->AddSpace(4); + sbpage0->SetColStretch(2,10); + } + // + // Lights page + // + SceneLightsPage *sbpage1 = new SceneLightsPage(sb); + sb->AddPage("Lights",icon,sbpage1); + + // + // Multi-view modes page + // + SceneModesPage *sbpage2 = new SceneModesPage(sb); + sb->AddPage("Modes",icon,sbpage2); + + // + // Color bars page + // + SceneColorBarsPage *sbpage3 = new SceneColorBarsPage(sb); + sb->AddPage("Color bars",icon,sbpage3); + + // + // Tools page + // + SceneToolsPage *sbpage4 = new SceneToolsPage(sb); + sb->AddPage("Tools",icon,sbpage4); + } + }; + // // Animation page // ************************************************ // + class AnimationPage : public iggFrameDC { - iggFrame *page2 = new iggFrame(mBook,1); - mBook->AddPage("Animation",icon,page2); - // - // Book - // - iggFrameBook *ab = new iggFrameBook(page2); - page2->AddLine(ab); + + public: + + AnimationPage(iggFrameBase *parent) : iggFrameDC(parent,1) { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("view.png"); + + // + // Book + // + iggFrameBook *ab = new iggFrameBook(this); + this->AddLine(ab); // // Style page // iggFrame *abpage0 = new iggFrame(ab,3); ab->AddPage("Style",icon,abpage0); - - iggWidgetKeyRadioBox *as = new iggWidgetKeyRadioBox(1,"Style",0,iAnimator::KeyStyle(),abpage0); - as->InsertItem("Static"); - as->InsertItem("Rotate/scale"); - as->InsertItem("Tumble"); - as->InsertItem("Flyby"); - as->InsertItem("Camera path"); - - iggFrame *tmp = new iggFrame(abpage0); - iggWidgetKeyRadioBox *ao = new iggWidgetKeyRadioBox(1,"Animation output",0,iViewModule::KeyAnimationOutput(),tmp); - ao->InsertItem("Series of images"); + { + AnimationStyleBox *as = new AnimationStyleBox(abpage0); + as->InsertItem("Static"); + as->InsertItem("Rotate/scale"); + as->InsertItem("Tumble"); + as->InsertItem("Flyby"); + + iggFrame *tmp = new iggFrame(abpage0); + iggWidgetKeyRadioBox *ao = new iggWidgetKeyRadioBox(1,"Animation output",0,iViewModule::KeyAnimationOutput(),tmp); + ao->InsertItem("Series of images"); + ao->InsertItem("MPEG movie"); #ifdef IVTK_SUPPORTS_MPEG - ao->InsertItem("MPEG2 movie"); #ifdef IVTK_501 - ao->SetItem("MPEG2 movie",1,false); // disable MPEG generation for VTK 5.0.1 due to a bug in vtkMPEGWriter + ao->SetItem("MPEG movie",1,false); // disable MPEG generation for VTK 5.0.1 due to a bug in vtkMPEGWriter #endif +#else + ao->SetItem("MPEG movie",1,false); // disable MPEG generation for VTK 5.0.1 due to a bug in vtkMPEGWriter #endif -#ifdef IVTK_SUPPORTS_AVI - ao->InsertItem("AVI movie"); + ao->InsertItem("AVI movie"); +#ifndef IVTK_SUPPORTS_AVI + ao->SetItem("AVI movie",2,false); #endif - tmp->AddLine(ao); - tmp->AddSpace(10); - abpage0->AddLine(as,tmp); - abpage0->AddLine(new iggWidgetKeyCheckBox("Restore camera after animation",iAnimator::KeyRestoreCamera(),abpage0),2); - - abpage0->AddSpace(10); - - iggWidgetKeyLargeIntSlider *af = new iggWidgetKeyLargeIntSlider(1,150,5,"Frames per file",iAnimator::KeyNumberOfFrames(),RenderMode::NoRender,abpage0); - af->SetRange(1,150,1); - abpage0->AddLine(af,2); - - abpage0->AddSpace(10); - - iggFrame *abut = new iggFrame(abpage0,3); - abut->AddLine(0,new AnimateButton(abut)); - abut->SetColStretch(0,10); - abut->SetColStretch(2,10); - abpage0->AddLine(abut,3); - - abpage0->SetColStretch(1,10); - abpage0->SetColStretch(2,3); - } - // - // Settings page - // - { + tmp->AddLine(ao); + tmp->AddSpace(10); + abpage0->AddLine(as,tmp); + + abpage0->AddSpace(10); + + AnimationFramesSlider *af = new AnimationFramesSlider(abpage0); + af->SetRange(1,150,1); + abpage0->AddLine(af,2); + + iggWidgetKeyFileNameLineEdit *aq = new iggWidgetKeyFileNameLineEdit(false,"IFrIT Animation Script",this->GetShell()->GetEnvironment(Environment::Script),"(*.ias)",true,"Current script",true,iAnimator::KeyScriptFile(),abpage0); + aq->AddDependent(af); + aq->AddDependent(as); + abpage0->AddLine(aq,2); + abpage0->AddLine(new iggWidgetLaunchButton(this->GetMainWindow()->GetDialogScriptDebugger(),"Launch script debugger",abpage0),2); + + abpage0->AddSpace(10); + + abpage0->AddLine(new iggWidgetKeyFileNameLineEdit(false,"IFrIT Animation Output",this->GetShell()->GetEnvironment(Environment::Image),"(*)",false,"Destination",false,iViewModule::KeyAnimationRootName(),abpage0),2); + + abpage0->AddSpace(10); + + iggFrame *abut = new iggFrame(abpage0,3); + abut->AddLine(0,new AnimateButton(abut)); + abut->SetColStretch(0,10); + abut->SetColStretch(2,10); + abpage0->AddLine(abut,3); + + abpage0->SetColStretch(1,10); + abpage0->SetColStretch(2,3); + } + // + // Settings page + // iggFrame *abpage1 = new iggFrame(ab,2); ab->AddPage("Settings",icon,abpage1); + { - iggWidgetKeyFloatSlider *tmpfs = new iggWidgetKeyFloatSlider(1.0e-4,1.0,40,1,0,"Flyby speed",iAnimator::KeyFlybySpeed(),RenderMode::NoRender,abpage1); - tmpfs->SetStretch(2,10); - abpage1->AddLine(tmpfs); - tmpfs = new iggWidgetKeyFloatSlider(0.0,0.1,30,0,0,"Cross section speed",iAnimator::KeyCrossSectionSpeed(),RenderMode::NoRender,abpage1); - tmpfs->SetStretch(2,10); - abpage1->AddLine(tmpfs); - - abpage1->AddSpace(2); - - iggFrame *ar = new iggFrame("Rotations",abpage1,1); - tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Azimuth (phi)",iAnimator::KeyPhi(),RenderMode::NoRender,ar); - tmpfs->SetStretch(3,10,0); - ar->AddLine(tmpfs); - tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Elevation (theta)",iAnimator::KeyTheta(),RenderMode::NoRender,ar); - tmpfs->SetStretch(3,10,0); - ar->AddLine(tmpfs); - tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Roll angle",iAnimator::KeyRoll(),RenderMode::NoRender,ar); - tmpfs->SetStretch(3,10,0); - ar->AddLine(tmpfs); - abpage1->AddLine(ar); - abpage1->AddLine(new iggWidgetKeyFloatSlider(0.98,1.02,400,1,5,"Zoom",iAnimator::KeyZoom(),RenderMode::NoRender,abpage1)); - - abpage1->AddSpace(10); - abpage1->SetColStretch(0,10); - abpage1->SetColStretch(1,3); - } - // - // Scripting page - // - { - iggFrame *abpage2 = new iggFrame(ab,2); - ab->AddPage("Scripting",icon,abpage2); - - abpage2->AddLine(new iggWidgetKeyCheckBox("Use script",iAnimator::KeyUseScript(),abpage2)); - abpage2->AddLine(new iggWidgetKeyCheckBox("Inherit settings from widgets",iAnimator::KeyInheritSettings(),abpage2)); - abpage2->AddLine(new iggWidgetKeyTextLineEdit(true,"Current script",iAnimator::KeyScriptFileName(),RenderMode::NoRender,abpage2)); - abpage2->AddLine(new iggWidgetLaunchButton(this->GetMainWindow()->GetDialogScriptDebugger(),"Launch script debugger",abpage2)); - - abpage2->AddSpace(10); - abpage2->SetColStretch(0,10); - abpage2->SetColStretch(1,3); - } - // - // Advanced page - // - { - iggFrame *abpage3 = new iggFrame(ab,2); - ab->AddPage("Advanced",icon,abpage3); - - iggWidgetKeySpinBox *tmpsb = new iggWidgetKeySpinBox(0,999,"Number of blended frames",0,iAnimator::KeyNumberOfBlendedFrames(),abpage3); - tmpsb->SetStretch(10,0); - abpage3->AddLine(tmpsb); - tmpsb = new iggWidgetKeySpinBox(0,999,"Number of transition frames",0,iAnimator::KeyNumberOfTransitionFrames(),abpage3); - tmpsb->SetStretch(10,0); - abpage3->AddLine(tmpsb); - - abpage3->AddSpace(5); - - iggFrame *acp = new iggFrame("Camera path",abpage3,2); - tmpsb = new iggWidgetKeySpinBox(2,9999,"Number of steps",0,iAnimator::KeyNumberOfCameraPathSteps(),acp); - tmpsb->SetStretch(10,0); - StepOnPath *sop = new StepOnPath(acp); - tmpsb->AddDependent(sop); - acp->AddLine(tmpsb); - tmpsb = new iggWidgetKeySpinBox(2,1000,"Number of handles",0,iAnimator::KeyNumberOfCameraPathHandles(),acp); - tmpsb->SetStretch(10,0); - acp->AddLine(tmpsb); - acp->AddLine(new iggWidgetKeyCheckBox("Make a loop",iAnimator::KeyCameraPathClosed(),acp)); - acp->AddLine(new iggWidgetKeyCheckBox("Use focal point path",iAnimator::KeyFocalPathEnabled(),acp)); - acp->AddLine(new iggWidgetKeyCheckBox("Collapse focal path into a point",iAnimator::KeyFocalPathToPoint(),acp)); - acp->AddLine(new iggWidgetKeyCheckBox("Stop on path",iAnimator::KeyStopOnPath(),acp)); - acp->AddLine(sop,new PlayDemo(acp)); - - abpage3 ->AddLine(acp); - - abpage3->AddSpace(5); - - abpage3->AddLine(new ResetAnimationImageIndexButton(abpage3)); - - abpage3->AddSpace(10); - abpage3->SetColStretch(0,10); - abpage3->SetColStretch(1,3); - } - // - // Title/logo page - // - { + iggWidgetKeyFloatSlider *tmpfs = new iggWidgetKeyFloatSlider(1.0e-4,1.0,40,1,0,"Flyby speed",iAnimator::KeyFlybySpeed(),RenderMode::NoRender,abpage1); + tmpfs->SetStretch(2,10); + abpage1->AddLine(tmpfs); + tmpfs = new iggWidgetKeyFloatSlider(0.0,0.1,30,0,0,"Cross section speed",iAnimator::KeyCrossSectionSpeed(),RenderMode::NoRender,abpage1); + tmpfs->SetStretch(2,10); + abpage1->AddLine(tmpfs); + + abpage1->AddSpace(2); + + iggFrame *ar = new iggFrame("Rotations",abpage1,1); + tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Azimuth (phi)",iAnimator::KeyPhi(),RenderMode::NoRender,ar); + tmpfs->SetStretch(3,10,0); + ar->AddLine(tmpfs); + tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Elevation (theta)",iAnimator::KeyTheta(),RenderMode::NoRender,ar); + tmpfs->SetStretch(3,10,0); + ar->AddLine(tmpfs); + tmpfs = new iggWidgetKeyFloatSlider(-10.0,10.0,200,0,4,"Roll angle",iAnimator::KeyRoll(),RenderMode::NoRender,ar); + tmpfs->SetStretch(3,10,0); + ar->AddLine(tmpfs); + abpage1->AddLine(ar); + abpage1->AddLine(new iggWidgetKeyFloatSlider(0.98,1.02,400,1,5,"Zoom",iAnimator::KeyZoom(),RenderMode::NoRender,abpage1)); + + abpage1->AddSpace(3); + + iggWidgetKeySpinBox *tmpsb = new iggWidgetKeySpinBox(0,999,"Number of blended frames",0,iAnimator::KeyNumberOfBlendedFrames(),abpage1); + tmpsb->SetStretch(10,0); + abpage1->AddLine(tmpsb); + tmpsb = new iggWidgetKeySpinBox(0,999,"Number of transition frames",0,iAnimator::KeyNumberOfTransitionFrames(),abpage1); + tmpsb->SetStretch(10,0); + abpage1->AddLine(tmpsb); + + abpage1->AddSpace(10); + abpage1->SetColStretch(0,10); + abpage1->SetColStretch(1,3); + } + // + // Title/logo page + // iggFrame *abpage4 = new iggFrame(ab,2); ab->AddPage("Title/logo",icon,abpage4); - - iggFrame *atbox = new iggFrame("Title",abpage4,3); - iggFrame *atf = new iggFrame(atbox,3); - iggWidgetKeyTextLineEdit *atle = new iggWidgetKeyTextLineEdit(true,"",iAnimator::KeyTitlePageFile(),RenderMode::NoRender,atf); - atf->AddLine(atle,3); - ViewImageArea *atia = new ViewImageArea(atbox); - LoadButton *alb = new LoadButton(atia,"Open title page file",iAnimator::KeyTitlePageFile(),iAnimator::KeyTitlePageImage(),atf); - RemoveButton *arb = new RemoveButton(atia,iAnimator::KeyTitlePageFile(),atf); - ViewButton *avb = new ViewButton(atia,atf); - alb->AddDependent(avb); - arb->AddDependent(avb); - atf->AddLine(alb,arb,avb); - - atbox->AddLine(atf,2,atia); - - iggWidgetKeySpinBox *tmpsb = new iggWidgetKeySpinBox(0,1000,"Frames to show title",0,iAnimator::KeyNumberOfTitlePageFrames(),atbox); - tmpsb->SetStretch(10,0); - atbox->AddLine(tmpsb,2); - tmpsb = new iggWidgetKeySpinBox(0,1000,"Frames to dissolve title",0,iAnimator::KeyNumberOfTitlePageBlendedFrames(),atbox); - tmpsb->SetStretch(10,0); - atbox->AddLine(tmpsb,2); - - atbox->SetColStretch(1,1); - atbox->SetColStretch(2,10); - abpage4->AddLine(atbox); - - iggFrame *albox = new iggFrame("Logo",abpage4,3); - iggFrame *alf = new iggFrame(albox,3); - iggWidgetKeyTextLineEdit *alle = new iggWidgetKeyTextLineEdit(true,"",iAnimator::KeyLogoFile(),RenderMode::NoRender,alf); - alf->AddLine(alle,3); - ViewImageArea *alia = new ViewImageArea(albox); - alb = new LoadButton(alia,"Open title page file",iAnimator::KeyLogoFile(),iAnimator::KeyLogoImage(),alf); - arb = new RemoveButton(alia,iAnimator::KeyLogoFile(),alf); - avb = new ViewButton(alia,alf); - alb->AddDependent(avb); - arb->AddDependent(avb); - alf->AddLine(alb,arb,avb); - - albox->AddLine(alf,2,alia); - - iggWidgetKeyComboBox *tmpcb = new iggWidgetKeyComboBox("Position",0,iAnimator::KeyLogoPosition(),albox); - tmpcb->InsertItem("Upper left"); - tmpcb->InsertItem("Upper right"); - tmpcb->InsertItem("Lower left"); - tmpcb->InsertItem("Lower rigt"); - tmpcb->SetStretch(10,0); - albox->AddLine(tmpcb,2); - iggWidgetKeyFloatSlider *tmpfs = new iggWidgetKeyFloatSlider(0,1.0,10,0,4,"Opacity",iAnimator::KeyLogoOpacity(),RenderMode::NoRender,albox); - tmpfs->SetStretch(10,0); - albox->AddLine(tmpfs,2); - - albox->SetColStretch(1,1); - albox->SetColStretch(2,10); - abpage4->AddLine(albox); - abpage4->AddSpace(10); - abpage4->SetColStretch(0,10); - abpage4->SetColStretch(1,3); + { + iggFrame *atbox = new iggFrame("Title",abpage4,3); + iggWidgetKeyFileNameLineEdit *atle = new iggWidgetKeyFileNameLineEdit(false,"IFrIT Title Page File",this->GetMainWindow()->GetShell()->GetEnvironment(Environment::Base),"Images (*.jpg *.jpeg *.pnm *.bmp *.png *.tif *.tiff)",true,"",true,iAnimator::KeyTitlePageFile(),atbox); + atbox->AddLine(atle,3); + + iggWidgetKeySpinBox *tmpsb = new iggWidgetKeySpinBox(0,1000,"Frames to show title",0,iAnimator::KeyNumberOfTitlePageFrames(),atbox); + tmpsb->SetStretch(10,0); + atbox->AddLine(tmpsb,2); + tmpsb = new iggWidgetKeySpinBox(0,1000,"Frames to dissolve title",0,iAnimator::KeyNumberOfTitlePageBlendedFrames(),atbox); + tmpsb->SetStretch(10,0); + atbox->AddLine(tmpsb,2); + + atbox->SetColStretch(1,1); + atbox->SetColStretch(2,10); + abpage4->AddLine(atbox); + + iggFrame *albox = new iggFrame("Logo",abpage4,3); + iggWidgetKeyFileNameLineEdit *alle = new iggWidgetKeyFileNameLineEdit(false,"IFrIT Logo File",this->GetMainWindow()->GetShell()->GetEnvironment(Environment::Base),"Images (*.jpg *.jpeg *.pnm *.bmp *.png *.tif *.tiff)",true,"",true,iAnimator::KeyLogoFile(),albox); + //avb = new iggWidgetLaunchButton(static_cast(0),"View",parent,trueViewButton(alia,alf); + //alf->AddLine(arb,avb); + albox->AddLine(alle,3); + + iggWidgetKeyComboBox *tmpcb = new iggWidgetKeyComboBox("Location",0,iAnimator::KeyLogoLocation(),albox); + tmpcb->InsertItem("Upper left"); + tmpcb->InsertItem("Upper right"); + tmpcb->InsertItem("Lower left"); + tmpcb->InsertItem("Lower rigt"); + tmpcb->SetStretch(10,0); + albox->AddLine(tmpcb,2); + iggWidgetKeyFloatSlider *tmpfs = new iggWidgetKeyFloatSlider(0,1.0,10,0,4,"Opacity",iAnimator::KeyLogoOpacity(),RenderMode::NoRender,albox); + tmpfs->SetStretch(10,0); + albox->AddLine(tmpfs,2); + + albox->SetColStretch(1,1); + albox->SetColStretch(2,10); + abpage4->AddLine(albox); + abpage4->AddSpace(10); + abpage4->SetColStretch(0,10); + abpage4->SetColStretch(1,3); + } } - } + }; + // // Markers page // ************************************************ // + class MarkersPage : public iggFrameDC { - iggFrame *page3 = new iggFrame(mBook,3); - mBook->AddPage("Markers",icon,page3); - // - // Book - // - iggFrameBook *mb = new iggFrameBook(page3); - page3->AddLine(mb); + + public: + + MarkersPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() { + int i; + const iImage *icon = iImageFactory::FindIcon("view.png"); + // + // Book + // + iggFrameBook *mb = new iggFrameBook(this); + this->AddLine(mb); // // Main page // iggFrame *mbpage0 = new iggFrame(mb,4); mb->AddPage("Main",icon,mbpage0); + { + iggFrame *msb = new MarkerFrameBox(mbpage0); - iggFrame *msb = new MarkerFrameBox(mbpage0); + CurrentMarkerBox *mcm = new CurrentMarkerBox(msb); + msb->AddLine(new iggWidgetTextArea("Current",msb),mcm); - iggFrame *msb1 = new iggFrame(msb); - iggFrame *msb2 = new iggFrame(msb); - msb->AddLine(msb1,msb2); - - CurrentMarkerBox *mcm = new CurrentMarkerBox(msb2); - msb1->AddLine(new iggWidgetTextArea("Current",msb1)); - msb2->AddLine(mcm); - iggWidgetKeyComboBox *mcs = new iggWidgetKeyComboBox("",0,iMarker::KeyType(),msb2); - mcs->AddDependent(mcm); - mcm->AddDependent(mbpage0); - for(i=0; iInsertItem(iPointGlyph::GetName(i)); - } - - iggWidget *mct = new iggWidgetKeyTextLineEdit(false,"",iMarker::KeyCaptionText(),RenderMode::UseGlobal,msb2); - - msb1->AddLine(new iggWidgetTextArea("Type",msb1)); - msb2->AddLine(mcs); - msb1->AddLine(new iggWidgetTextArea("Caption",msb1)); - msb2->AddLine(mct); - msb1->AddLine(new iggWidgetTextArea("Marker size",msb1)); - msb2->AddLine(new iggWidgetKeySizeSlider(1.0e-5,0,"",iMarker::KeySize(true),RenderMode::UseGlobal,msb2)); - - iggFrame *mcb = new iggFrame("Controls",mbpage0,1); - iggFrameCreateDeleteButton *mcd = new iggFrameCreateDeleteButton(page3,iMarker::Type(),false,"marker",mcb); - mcd->AddDependent(mbpage0); - mcb->AddLine(mcd); - - iggWidget *mmc = new MarkerMoveCaptionsButton("Rearrange captions",iViewModule::KeyMoveMarkerCaption(),mcb); - iggWidget *mmm = new iggWidgetKeyCheckBox("Show motion handles",iViewModule::KeyMarkerHandles(),mcb); - mcb->AddLine(mmc); - mcb->AddLine(mmm); - mct->AddDependent(mmc); - - mcb->AddSpace(10); - - mbpage0->AddLine(msb,2,mcb,1); - - iggFrame *mfc = new iggFrame(mbpage0,1); - iggWidgetKeyColorSelection *mcc = new iggWidgetKeyColorSelection(iMarker::KeyColor(),mfc,false); - mcc->SetText("Color"); - mfc->AddLine(mcc); - - iggFramePosition *mpos = new MarkerPositionFrame(mbpage0); - mbpage0->AddLine(mpos,2,mfc,1); - mmm->AddDependent(mpos); - - mbpage0->AddLine(new iggWidgetKeyCheckBox("Move objects interactively",iMarker::KeyInteractiveMove(),mbpage0),3); - mbpage0->AddLine(new iggWidgetKeyCheckBox("Scale marker to keep size fixed",iMarker::KeyScaled(),mbpage0),3); - - mbpage0->AddSpace(10); - mbpage0->SetColStretch(1,10); - mbpage0->SetColStretch(3,3); - } - // - // Material page - // - { + iggWidgetKeyComboBox *mcs = new iggWidgetKeyComboBox("",0,iMarker::KeyType(),msb); + mcs->AddDependent(mcm); + mcm->AddDependent(mbpage0); + for(i=0; iInsertItem(iPointGlyph::GetName(i)); + } + msb->AddLine(new iggWidgetTextArea("Type",msb),mcs); + + iggWidgetKeyColorSelection *mcc = new iggWidgetKeyColorSelection(iMarker::KeyColor(),msb); + mcc->SetText("Set"); + msb->AddLine(new iggWidgetTextArea("Color",msb),mcc); + + msb->AddLine(new iggWidgetTextArea("Size",msb),new iggWidgetKeySizeSlider(1.0e-5,0,"",iMarker::KeySize(true),RenderMode::UseGlobal,msb)); + + iggFrame *mcb = new iggFrame("Controls",mbpage0,1); + iggFrameCreateDeleteButton *mcd = new iggFrameCreateDeleteButton(this,iMarker::Type(),false,"marker",mcb); + mcd->AddDependent(mbpage0); + mcb->AddLine(mcd); + + iggWidget *mmm = new iggWidgetKeyCheckBox("Show motion handles",iViewModule::KeyMarkerHandles(),mcb); + mcb->AddLine(mmm); + + mcb->AddSpace(10); + + mbpage0->AddLine(msb,2,mcb,1); + + iggFrame *mfc = new iggFrame("Caption",mbpage0,1); + iggWidget *mct = new iggWidgetKeyTextLineEdit(false,"",iMarker::KeyCaptionText(),RenderMode::UseGlobal,mfc); + mfc->AddLine(mct); + iggWidget *mmc = new MarkerMoveCaptionsButton("Rearrange captions",iViewModule::KeyMoveMarkerCaption(),mfc); + mct->AddDependent(mmc); + mfc->AddLine(mmc); + mfc->AddSpace(10); + + iggFramePosition *mpos = new MarkerPositionFrame(mbpage0); + mbpage0->AddLine(mpos,2,mfc,1); + mmm->AddDependent(mpos); + + mbpage0->AddLine(new iggWidgetKeyCheckBox("Move objects interactively",iMarker::KeyInteractiveMove(),mbpage0),3); + mbpage0->AddLine(new iggWidgetKeyCheckBox("Scale marker to keep size fixed",iMarker::KeyScaled(),mbpage0),3); + + mbpage0->AddSpace(10); + mbpage0->SetColStretch(1,10); + mbpage0->SetColStretch(3,3); + } + // + // Material page + // iggFrame *mbpage1 = new iggFrame(mb,2); mb->AddPage("Material ",icon,mbpage1); + { + mbpage1->AddLine(new iggFrameMaterialProperties(false,false,iMarker::Type(),mbpage1)); + mbpage1->AddLine(new iggWidgetKeyFloatSlider(0.0f,1.0f,10,0,0,"Opacity",iMarker::KeyOpacity(),RenderMode::UseGlobal,mbpage1)); - mbpage1->AddLine(new iggFrameMaterialProperties(false,false,iMarker::Type(),mbpage1)); - mbpage1->AddLine(new iggWidgetKeyFloatSlider(0.0f,1.0f,10,0,0,"Opacity",iMarker::KeyOpacity(),RenderMode::UseGlobal,mbpage1)); - - iggWidget *mct = new iggWidgetKeyCheckBox("Captions are transparent",iViewModule::KeyMarkerCaptionsTransparent(),mbpage1); - mct->SetExecuteFlags(ObjectOption::One|ModuleOption::One|RenderOption::All); - mbpage1->AddLine(mct); - - mbpage1->AddSpace(10); - mbpage1->SetColStretch(0,10); - mbpage1->SetColStretch(1,3); - } - // - // Legend page - // - { + iggWidget *mct = new iggWidgetKeyCheckBox("Captions are transparent",iViewModule::KeyMarkerCaptionsTransparent(),mbpage1); + mct->SetExecuteFlags(ObjectOption::One|ModuleOption::One|RenderOption::All); + mbpage1->AddLine(mct); + + mbpage1->AddSpace(10); + mbpage1->SetColStretch(0,10); + mbpage1->SetColStretch(1,3); + } + // + // Legend page + // iggFrame *mbpage2 = new iggFrame(mb,2); mb->AddPage("Legend",icon,mbpage2); + { + mbpage2->AddLine(new iggWidgetKeyCheckBox("Show legend",iViewModule::KeyMarkerLegend(),mbpage2)); + iggWidgetKeyRadioBox *mlp = new iggWidgetKeyRadioBox(1,"Legend position",0,iViewModule::KeyMarkerLegendPosition(),mbpage2); + mlp->InsertItem("Lower right corner"); + mlp->InsertItem("Lower left corner"); - mbpage2->AddLine(new iggWidgetKeyCheckBox("Show legend",iViewModule::KeyMarkerLegend(),mbpage2)); - iggWidgetKeyRadioBox *mlp = new iggWidgetKeyRadioBox(1,"Legend position",0,iViewModule::KeyMarkerLegendPosition(),mbpage2); - mlp->InsertItem("Lower right corner"); - mlp->InsertItem("Lower left corner"); - - mbpage2->AddLine(mlp); - - mbpage2->AddSpace(10); - mbpage2->SetColStretch(1,10); - } - // - // Transform page - // - { + mbpage2->AddLine(mlp); + + mbpage2->AddSpace(10); + mbpage2->SetColStretch(1,10); + } + // + // Transform page + // iggFrame *mbpage3 = new iggFrame(mb,2); mb->AddPage("Transform",icon,mbpage3); - - iggFrame *mtb = new iggFrame("Scale",mbpage3,1); - mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"X",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,3)); - mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"Y",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,4)); - mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"Z",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,5)); - mbpage3->AddLine(mtb); - - mtb = new iggFrame("Rotate",mbpage3,1); - mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"X",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,0)); - mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"Y",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,1)); - mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"Z",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,2)); - mbpage3->AddLine(mtb); - - mbpage3->AddSpace(10); - mbpage3->SetColStretch(0,10); - mbpage3->SetColStretch(1,3); + { + iggFrame *mtb = new iggFrame("Scale",mbpage3,1); + mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"X",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,3)); + mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"Y",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,4)); + mtb->AddLine(new iggWidgetKeyFloatSlider(0.01f,100.0f,200,1,5,"Z",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,5)); + mbpage3->AddLine(mtb); + + mtb = new iggFrame("Rotate",mbpage3,1); + mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"X",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,0)); + mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"Y",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,1)); + mtb->AddLine(new iggWidgetKeyFloatSlider(-180.0,180.0,360,0,5,"Z",iMarker::KeyTransform(),RenderMode::UseGlobal,mtb,2)); + mbpage3->AddLine(mtb); + + mbpage3->AddSpace(10); + mbpage3->SetColStretch(0,10); + mbpage3->SetColStretch(1,3); + } } - } + }; + // // Windows page // ************************************************ // + class WindowsPage : public iggFrameDC + { + + public: + + WindowsPage(iggFrameBase *parent, iggPageView *page) : iggFrameDC(parent,3) + { + mPage = page; + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggPageView *mPage; + + virtual void CompleteConstructionBody() + { + iggFrame *wfb = new iggFrame("Windows",this,1); + WindowNumberComboBox *wnb = new WindowNumberComboBox(wfb,mPage); + wfb->AddLine(wnb); + CreateWindowButton *wcb1 = new CreateWindowButton(ModuleType::New,wfb); + wcb1->AddDependent(wnb); + wfb->AddLine(wcb1); + CreateWindowButton *wcb2 = new CreateWindowButton(ModuleType::Copy,wfb); + wcb2->AddDependent(wnb); + wfb->AddLine(wcb2); + CreateWindowButton *wcb3 = new CreateWindowButton(ModuleType::Clone,wfb); + wcb3->AddDependent(wnb); + wfb->AddLine(wcb3); + DeleteWindowButton *wdb = new DeleteWindowButton(wfb); + wdb->AddDependent(wnb); + wfb->AddLine(wdb); + wcb1->AddDependent(wdb); + wcb2->AddDependent(wdb); + wcb3->AddDependent(wdb); + + WindowStatusIcon *wsi = new WindowStatusIcon(this); + wnb->AddDependent(wsi); + wcb1->AddDependent(wsi); + wcb2->AddDependent(wsi); + wcb3->AddDependent(wsi); + wdb->AddDependent(wsi); + + this->AddLine(wfb,wsi); + + this->AddLine(new CopyFromWindowComboBox(this)); + this->AddSpace(2); + + this->AddLine(new WidgetsControlAllWindowsCheckBox(this)); + this->AddLine(new WindowUnderFocusCurrentCheckBox(this)); + this->AddLine(new iggWidgetKeyCheckBox("Synchronize window interactors",iControlModule::KeySynchronizeInteractors(),this)); + this->AddLine(new iggWidgetKeyExecButton("Synchronize cameras",iControlModule::KeySynchronizeCameras(),this)); + + this->AddSpace(10); + this->SetColStretch(2,10); + } + }; +}; + +using namespace iggPageView_Private; + + +iggPageView::iggPageView(iggFrameBase *parent) : iggPageMain(parent) +{ + const iImage *icon = iImageFactory::FindIcon("view.png"); + + mWindowSizeDialog = new WindowSizeDialog(this->GetMainWindow()); + mWindowListDialog = new WindowListDialog(this->GetMainWindow()); + + // + // Main page (always shown at start-up, hence no delayed construction) + // ************************************************ + // + iggFrame *page0 = new iggFrame(mBook,4); + mBook->AddPage("Main",icon,page0); { - iggFrame *page4 = new iggFrame(mBook,3); - mBook->AddPage("Windows",icon,page4); + page0->AddSpace(2); + + iggWidgetKeyTextComboBox *ur = new iggWidgetKeyTextComboBox(0,"Update rate",0,iViewModule::KeyUpdateRate(),page0); + ur->InsertItem("Non-interactive"); + ur->InsertItem(" 3 frames/sec"); + ur->InsertItem("10 frames/sec"); + ur->InsertItem("30 frames/sec"); + ur->SetInvalidValue(0); + page0->AddLine(ur,2); + page0->AddSpace(2); + + iggFrame *pf = new iggFrame("Projection",page0,1); + pf->AddLine(new iggWidgetKeyCheckBox("Parallel",iCamera::KeyParallelProjection(),pf)); + iggWidgetKeyCheckBox *pp = new iggWidgetKeyCheckBox("Perspective",iCamera::KeyParallelProjection(),pf); + pf->AddLine(pp); + pp->SetReverse(true); + + if(this->GetShell()->GetControlModule()->GetParallelManager()->GetMaxNumberOfProcessors() > 1) + { + iggWidget *peb = new ParallelExecutionBox(page0); + page0->AddLine(pf,peb); + } + else + { + page0->AddLine(pf); + } + + page0->AddLine(new iggWidgetKeyExecButton("Reset view",iCamera::KeyReset(),page0),new iggWidgetLaunchButton(mWindowSizeDialog,"Set window size",page0)); + page0->AddSpace(2); + + iggFrame *fb = new iggFrame("Features",page0,1); + fb->AddLine(new iggWidgetKeyCheckBox("Bounding box",iViewModule::KeyBoundingBox(),fb)); + fb->AddLine(new ShowRecordLabelCheckBox(fb)); + fb->AddLine(new ShowRulerCheckBox(fb)); + fb->AddLine(new iggWidgetKeyCheckBox("Color bars",iViewModule::KeyColorBars(),fb)); + fb->AddLine(new iggWidgetKeyCheckBox("Alignment axes",iViewModule::KeyCameraAlignmentLabel(),fb)); - iggFrame *wfb = new iggFrame("Windows",page4,1); - WindowNumberComboBox *wnb = new WindowNumberComboBox(wfb,this); - wfb->AddLine(wnb); - CreateWindowButton *wcb1 = new CreateWindowButton(ModuleType::New,wfb); - wcb1->AddDependent(wnb); - wfb->AddLine(wcb1); - CreateWindowButton *wcb2 = new CreateWindowButton(ModuleType::Copy,wfb); - wcb2->AddDependent(wnb); - wfb->AddLine(wcb2); - CreateWindowButton *wcb3 = new CreateWindowButton(ModuleType::Clone,wfb); - wcb3->AddDependent(wnb); - wfb->AddLine(wcb3); - DeleteWindowButton *wdb = new DeleteWindowButton(wfb); - wdb->AddDependent(wnb); - wfb->AddLine(wdb); - wcb1->AddDependent(wdb); - wcb2->AddDependent(wdb); - wcb3->AddDependent(wdb); - - WindowStatusIcon *wsi = new WindowStatusIcon(page4); - wnb->AddDependent(wsi); - wcb1->AddDependent(wsi); - wcb2->AddDependent(wsi); - wcb3->AddDependent(wsi); - wdb->AddDependent(wsi); - - page4->AddLine(wfb,wsi); - - page4->AddLine(new CopyFromWindowComboBox(page4)); - page4->AddSpace(2); - - page4->AddLine(new WidgetsControlAllWindowsCheckBox(page4)); - page4->AddLine(new WindowUnderFocusCurrentCheckBox(page4)); - page4->AddLine(new iggWidgetKeyCheckBox("Synchronize window interactors",iControlModule::KeySynchronizeInteractors(),page4)); - page4->AddLine(new iggWidgetKeyExecButton("Synchronize cameras",iControlModule::KeySynchronizeCameras(),page4)); + iggFrame *fb2 = new iggFrame(page0,1); + iggWidgetKeyRadioBox *isb = new iggWidgetKeyRadioBox(1,"Interactor style",0,iViewModule::KeyInteractorStyle(),fb2); + isb->InsertItem("Trackball"); + isb->InsertItem("Joystick"); + isb->InsertItem("Flight"); + isb->InsertItem("Keyboard"); + fb2->AddLine(isb); - page4->AddSpace(10); - page4->SetColStretch(2,10); + page0->AddLine(fb,fb2); + + fb = new iggFrame(page0,2); + fb->AddLine(new iggWidgetTextArea("Wall paper",fb),new iggWidgetKeyFileNameLineEdit(true,"Load wallpaper image",this->GetShell()->GetEnvironment(Environment::Script),"Images (*.jpg *.jpeg *.pnm *.bmp *.png *.tif *.tiff)",true," ",true,iViewModule::KeyBackgroundImage(),fb)); + fb->AddLine(new iggWidgetTextArea("Image root",fb),new iggWidgetKeyFileNameLineEdit(false,"IFrIT Image Output",this->GetShell()->GetEnvironment(Environment::Image),"(*)",false," ",false,iViewModule::KeySnapshotRootName(),fb)); + fb->SetColStretch(0,0); + fb->SetColStretch(1,3); + fb2 = new iggFrame(page0,1); + iggWidgetKeyColorSelection *bgc = new iggWidgetKeyColorSelection(iViewModule::KeyBackgroundColor(),fb2); + if(this->GetMainWindow()->GetDialogImageComposer() != 0) bgc->AddDependent(this->GetMainWindow()->GetDialogImageComposer()->GetArea()); + fb2->AddLine(bgc); + fb2->AddSpace(10); + + page0->AddLine(fb,2,fb2,1); + + page0->AddSpace(10); + page0->SetColStretch(3,10); } + + // + // Scene page + // ************************************************ + // + iggFrame *page1 = new ScenePage(mBook); + mBook->AddPage("Scene",icon,page1); + + // + // Animation page + // ************************************************ + // + iggFrame *page2 = new AnimationPage(mBook); + mBook->AddPage("Animation",icon,page2); + + // + // Markers page + // ************************************************ + // + iggFrame *page3 = new MarkersPage(mBook); + mBook->AddPage("Markers",icon,page3); + + // + // Windows page + // ************************************************ + // + iggFrame *page4 = new WindowsPage(mBook,this); + mBook->AddPage("Windows",icon,page4); } diff -Nru ifrit-3.3.4/shells/generic/iggpageview.h ifrit-3.4.2/shells/generic/iggpageview.h --- ifrit-3.3.4/shells/generic/iggpageview.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpageview.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggpagevolume.cpp ifrit-3.4.2/shells/generic/iggpagevolume.cpp --- ifrit-3.3.4/shells/generic/iggpagevolume.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagevolume.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -46,9 +46,11 @@ #include "iggframepaletteselection.h" #include "iggframereplicate.h" #include "iggmainwindow.h" +#include "iggrenderwindow.h" #include "iggwidgetkeybutton.h" #include "iggwidgetkeyselectionbox.h" #include "iggwidgetkeyslider.h" +#include "iggwidgetmisc.h" #include "iggwidgetotherbutton.h" #include "ibgframesubject.h" @@ -155,141 +157,255 @@ this->iggWidgetKeyComboBox::UpdateWidgetBody(); } }; -}; - -using namespace iggPageVolume_Private; - - -iggPageVolume::iggPageVolume(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Volume) -{ - const iImage *icon = iImageFactory::FindIcon("volv.png"); // // Main page // ************************************************ // - iggFrame *page0 = new iggFrame(mBook,3); - mBook->AddPage("Main",icon,page0); - // - // Show - // - iggWidget *show = new iggWidgetShowButton(iVolumeViewSubject::Type(),page0); - page0->AddLine(show); - page0->AddSpace(2); - // - // Field & method - // - iggFrame *tmp = new iggFrame("Method",page0); - tmp->AddLine(new MethodBox(tmp)); - page0->AddLine(tmp); + class MainPage : public iggFrameDC + { + + public: + + MainPage(iggFrameBase *parent, iggDataTypeProvider *provider) : iggFrameDC(parent,3), mProvider(provider) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + iggDataTypeProvider *mProvider; - iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Field",iVolumeViewSubject::KeyVar(),0,page0,0); - pl->Complete(); - pl->AddDependent(show); + virtual void CompleteConstructionBody() + { + // + // Show + // + iggWidget *show = new iggWidgetShowButton(iVolumeViewSubject::Type(),this); + this->AddLine(show); + this->AddSpace(2); + // + // Field & method + // + iggFrame *tmp = new iggFrame("Method",this); + tmp->AddLine(new MethodBox(tmp)); + this->AddLine(tmp); + + iggFrameDataVariableList *pl = new iggFrameDataVariableList(mProvider,"Field",iVolumeViewSubject::KeyVar(),0,this,0); + pl->Complete(); + pl->AddDependent(show); #ifdef VTK_USE_VOLUMEPRO - page0->AddLine(pl,new iggPageVolume_Private::WindowSizeFrame(page0)); + this->AddLine(pl,new iggPageVolume_Private::WindowSizeFrame(this)); #else - page0->AddLine(pl); + this->AddLine(pl); #endif - page0->AddSpace(10); + this->AddSpace(10); + + this->SetColStretch(2,10); + } + }; - page0->SetColStretch(2,10); // // Paint page // ************************************************ // - iggFrame *page1 = new iggFrame(mBook,1); - mBook->AddPage("Paint",icon,page1); + class PaintPage : public iggFrameDC + { + + public: + + PaintPage(iggFrameBase *parent) : iggFrameDC(parent,1) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + const iImage *icon = iImageFactory::FindIcon("volv.png"); + // + // Book + // + iggFrameBook *pb = new iggFrameBook(this); + this->AddLine(pb); + // + // Palette page + // + iggFrame *pbpage0 = new iggFrame(pb,2); + pb->AddPage("Palette",icon,pbpage0); + { + iggFramePaletteSelection *ps = new iggFramePaletteSelection(false,iVolumeViewSubject::KeyPalette(),pbpage0,0); + pbpage0->AddLine(ps); + pbpage0->AddSpace(20); + + pbpage0->SetColStretch(0,10); + pbpage0->SetColStretch(1,3); + } + // + // Material page + // + iggFrame *pbpage1 = new iggFrame(pb,2); + pb->AddPage("Material",icon,pbpage1); + { + iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(true,false,iVolumeViewSubject::Type(),pbpage1); + pbpage1->AddLine(mp); + + pbpage1->AddSpace(10); + pbpage1->SetColStretch(0,10); + pbpage1->SetColStretch(1,3); + } + } + }; + + // - // Book + // Opacity page + // ************************************************ // - iggFrameBook *pb = new iggFrameBook(page1); - page1->AddLine(pb); + class OpacityPage : public iggFrameDC + { + + public: + + OpacityPage(iggFrameBase *parent) : iggFrameDC(parent,1) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // FunctionMapping widget + // + this->AddLine(new iggFrameFunctionMapping(iVolumeViewSubject::KeyOpacityFunction(),this)); + } + }; + + // - // Palette page + // Replicate page + // ************************************************ // - iggFrame *pbpage0 = new iggFrame(pb,2); - pb->AddPage("Palette",icon,pbpage0); + class ReplicatePage : public iggFrameDC + { + + public: + + ReplicatePage(iggFrameBase *parent) : iggFrameDC(parent,2) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: - iggFramePaletteSelection *ps = new iggFramePaletteSelection(false,iVolumeViewSubject::KeyPalette(),pbpage0,0); - pbpage0->AddLine(ps); - pbpage0->AddSpace(20); + virtual void CompleteConstructionBody() + { + // + // Replicate + // + this->AddLine(new iggFrameReplicate(iVolumeViewSubject::Type(),this)); + this->AddSpace(10); + this->SetColStretch(1,3); + } + }; - pbpage0->SetColStretch(0,10); - pbpage0->SetColStretch(1,3); // - // Material page + // Extras page + // ************************************************ // - iggFrame *pbpage1 = new iggFrame(pb,2); - pb->AddPage("Material",icon,pbpage1); + class ExtrasPage : public iggFrameDC + { - iggFrameMaterialProperties *mp = new iggFrameMaterialProperties(true,false,iVolumeViewSubject::Type(),pbpage1); - pbpage1->AddLine(mp); + public: - pbpage1->AddSpace(10); - pbpage1->SetColStretch(0,10); - pbpage1->SetColStretch(1,3); + ExtrasPage(iggFrameBase *parent) : iggFrameDC(parent,3) + { + if(this->ImmediateConstruction()) this->CompleteConstruction(); + } + + protected: + + virtual void CompleteConstructionBody() + { + // + // Ray casting settings + // + iggFrame *rc = new iggFrame("Rendering settings",this,2); + iggWidgetKeyRadioBox *it = new iggWidgetKeyRadioBox(1,"Interpolation type",0,iVolumeViewSubject::KeyInterpolationType(),rc); + it->InsertItem("Nearest neighbor"); + it->InsertItem("Linear"); + iggWidgetKeyRadioBox *bm = new iggWidgetKeyRadioBox(1,"Blending mode",0,iVolumeViewSubject::KeyBlendMode(),rc); + bm->InsertItem("Composite"); + bm->InsertItem("Maximum intensity"); + rc->AddLine(it,bm); + this->AddLine(rc); + this->AddSpace(10); + + iggFrame *rs = new iggFrame("Downsampling settings",this,1); + iggWidgetKeyFloatSlider *fs = new iggWidgetKeyFloatSlider(0.1f,10.0f,20,1,4,"Image downsampling",iVolumeViewSubject::KeyImageDownsampleFactor(),RenderMode::UseGlobal,rs); + fs->SetStretch(3,10); + rs->AddLine(fs); + fs = new iggWidgetKeyFloatSlider(0.1f,10.0f,20,1,4,"Depth downsampling",iVolumeViewSubject::KeyDepthDownsampleFactor(),RenderMode::UseGlobal,rs); + fs->SetStretch(3,10); + rs->AddLine(fs); + + this->AddLine(rs,2); + this->AddSpace(10); + + this->SetColStretch(1,10); + this->SetColStretch(2,3); + } + }; +}; + + +using namespace iggPageVolume_Private; + + +iggPageVolume::iggPageVolume(iggFrameBase *parent) : iggPageObject(parent,ViewSubject::Id::Volume) +{ + const iImage *icon = iImageFactory::FindIcon("volv.png"); // - // Opacity page + // Main page // ************************************************ // - iggFrame *page2 = new iggFrame(mBook,1); - mBook->AddPage("Opacity",icon,page2); + MainPage *page0 = new MainPage(mBook,mProvider); + mBook->AddPage("Main",icon,page0); + // - // FunctionMapping widget + // Paint page + // ************************************************ // - page2->AddLine(new iggFrameFunctionMapping(iVolumeViewSubject::KeyOpacityFunction(),page2)); + PaintPage *page1 = new PaintPage(mBook); + mBook->AddPage("Paint",icon,page1); // - // Replicate page + // Opacity page // ************************************************ // - iggFrame *page3 = new iggFrame(mBook,2); - mBook->AddPage("Replicate",icon,page3); + OpacityPage *page2 = new OpacityPage(mBook); + mBook->AddPage("Opacity",icon,page2); + // - // Replicate + // Replicate page + // ************************************************ // - page3->AddLine(new iggFrameReplicate(iVolumeViewSubject::Type(),page3)); - page3->AddSpace(10); - page3->SetColStretch(1,3); + ReplicatePage *page3 = new ReplicatePage(mBook); + mBook->AddPage("Replicate",icon,page3); // // Extras page // ************************************************ // - iggFrame *page4 = new iggFrame(mBook,3); + ExtrasPage *page4 = new ExtrasPage(mBook); mBook->AddPage("Extras",icon,page4); - // - // Ray casting settings - // - iggFrame *rc = new iggFrame("Rendering settings",page4,2); - iggWidgetKeyRadioBox *it = new iggWidgetKeyRadioBox(1,"Interpolation type",0,iVolumeViewSubject::KeyInterpolationType(),rc); - it->InsertItem("Nearest neighbor"); - it->InsertItem("Linear"); - iggWidgetKeyRadioBox *bm = new iggWidgetKeyRadioBox(1,"Blending mode",0,iVolumeViewSubject::KeyBlendMode(),rc); - bm->InsertItem("Composite"); - bm->InsertItem("Maximum intensity"); - rc->AddLine(it,bm); - page4->AddLine(rc); - page4->AddSpace(10); - - iggFrame *rs = new iggFrame("Downsampling settings",page4,1); - iggWidgetKeyFloatSlider *fs = new iggWidgetKeyFloatSlider(0.1f,10.0f,20,1,4,"Image downsampling",iVolumeViewSubject::KeyImageDownsampleFactor(),RenderMode::UseGlobal,rs); - fs->SetStretch(3,10); - rs->AddLine(fs); - fs = new iggWidgetKeyFloatSlider(0.1f,10.0f,20,1,4,"Depth downsampling",iVolumeViewSubject::KeyDepthDownsampleFactor(),RenderMode::UseGlobal,rs); - fs->SetStretch(3,10); - rs->AddLine(fs); - - page4->AddLine(rs,2); - page4->AddSpace(10); - - page4->SetColStretch(1,10); - page4->SetColStretch(2,3); } #endif diff -Nru ifrit-3.3.4/shells/generic/iggpagevolume.h ifrit-3.4.2/shells/generic/iggpagevolume.h --- ifrit-3.3.4/shells/generic/iggpagevolume.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggpagevolume.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggparameter.h ifrit-3.4.2/shells/generic/iggparameter.h --- ifrit-3.3.4/shells/generic/iggparameter.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggparameter.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggreloading.h ifrit-3.4.2/shells/generic/iggreloading.h --- ifrit-3.3.4/shells/generic/iggreloading.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggreloading.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggreloadingtemplate.h ifrit-3.4.2/shells/generic/iggreloadingtemplate.h --- ifrit-3.3.4/shells/generic/iggreloadingtemplate.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggreloadingtemplate.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindow.cpp ifrit-3.4.2/shells/generic/iggrenderwindow.cpp --- ifrit-3.3.4/shells/generic/iggrenderwindow.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindow.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -351,7 +351,7 @@ void* iggRenderWindow::GetGenericDisplayId() { - return mSubject->GetDisplayId(); + return mSubject->GetDisplay(); } @@ -443,6 +443,12 @@ } +int iggRenderWindow::IsDirect() +{ + return mSubject->IsDirect() ? 1 : 0; +} + + void iggRenderWindow::SetStereoCapableWindow(int capable) { if(!mInitialized) diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindow.h ifrit-3.4.2/shells/generic/iggrenderwindow.h --- ifrit-3.3.4/shells/generic/iggrenderwindow.h 2011-01-27 17:52:18.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindow.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -94,6 +94,7 @@ void OnCloseAttempt(); virtual bool IsCurrent(); + virtual int IsDirect(); // // Interaction with the GUI stereo capabilities diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindowinteractor.cpp ifrit-3.4.2/shells/generic/iggrenderwindowinteractor.cpp --- ifrit-3.3.4/shells/generic/iggrenderwindowinteractor.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindowinteractor.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindowinteractor.h ifrit-3.4.2/shells/generic/iggrenderwindowinteractor.h --- ifrit-3.3.4/shells/generic/iggrenderwindowinteractor.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindowinteractor.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindowobserver.cpp ifrit-3.4.2/shells/generic/iggrenderwindowobserver.cpp --- ifrit-3.3.4/shells/generic/iggrenderwindowobserver.cpp 2011-01-27 17:52:30.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindowobserver.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggrenderwindowobserver.h ifrit-3.4.2/shells/generic/iggrenderwindowobserver.h --- ifrit-3.3.4/shells/generic/iggrenderwindowobserver.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggrenderwindowobserver.h 2013-07-11 01:23:54.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggshell.cpp ifrit-3.4.2/shells/generic/iggshell.cpp --- ifrit-3.3.4/shells/generic/iggshell.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggshell.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -77,7 +77,12 @@ public: - iggDialogFlashWindow(iShell *shell) : iggDialog(shell,DialogFlag::Unattached|DialogFlag::Blocking|DialogFlag::NoTitleBar,0,"",0,3,0) + iggDialogFlashWindow(iggShell *shell) : iggDialog(shell,DialogFlag::Unattached|DialogFlag::Blocking|DialogFlag::NoTitleBar,0,"",0,3,0) + { + this->CompleteConstruction(); + } + + void CompleteConstructionBody() { mFrame->AddLine(new iggWidgetTextArea("%b%+ IFrIT - Ionization FRont Interactive Tool ",mFrame),3); mFrame->AddLine(new iggWidgetTextArea("Version "+iVersion::GetVersion(),mFrame),3); @@ -92,10 +97,10 @@ this->ResizeContents(100,100); } - virtual void Show(bool s) + virtual void ShowBody(bool s) { mFlipper->Reset(); - iggDialog::Show(s); + iggDialog::ShowBody(s); } void OnInitAtom() @@ -160,6 +165,7 @@ } case iConsole::_LowError: { + if(m.Part(0,7) == "ERROR: ") m = m.Part(7); mMainWindow->WriteToLog("Error",m,iColor(255,0,0)); break; } @@ -206,6 +212,12 @@ } +iggShell::~iggShell() +{ + delete mSubject; +} + + void iggShell::Exit() { mSubject->Exit(); @@ -231,11 +243,7 @@ this->AddCommandLineOption("owm",false,"use old-style window manager"); this->AddCommandLineOption("sds",false,"assume the desktop size is small"); this->AddCommandLineOption("src",false,"minimize updates for running on a slow remote connection"); -} - - -iggShell::~iggShell() -{ + this->AddCommandLineOption("ddi",false,"disable delayed initialization"); } @@ -556,6 +564,12 @@ return true; } + if(o.Name == "ddi") + { + mConditionFlags |= Condition::DisableDelayedInitialization; + return true; + } + return false; } diff -Nru ifrit-3.3.4/shells/generic/iggshell.h ifrit-3.4.2/shells/generic/iggshell.h --- ifrit-3.3.4/shells/generic/iggshell.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggshell.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidget.cpp ifrit-3.4.2/shells/generic/iggwidget.cpp --- ifrit-3.3.4/shells/generic/iggwidget.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidget.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidget.h ifrit-3.4.2/shells/generic/iggwidget.h --- ifrit-3.3.4/shells/generic/iggwidget.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidget.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetarea.cpp ifrit-3.4.2/shells/generic/iggwidgetarea.cpp --- ifrit-3.3.4/shells/generic/iggwidgetarea.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetarea.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetarea.h ifrit-3.4.2/shells/generic/iggwidgetarea.h --- ifrit-3.3.4/shells/generic/iggwidgetarea.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetarea.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeybutton.cpp ifrit-3.4.2/shells/generic/iggwidgetkeybutton.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeybutton.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeybutton.cpp 2013-07-11 01:24:00.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeybutton.h ifrit-3.4.2/shells/generic/iggwidgetkeybutton.h --- ifrit-3.3.4/shells/generic/iggwidgetkeybutton.h 2011-01-27 17:52:19.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeybutton.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeycolorselection.cpp ifrit-3.4.2/shells/generic/iggwidgetkeycolorselection.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeycolorselection.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeycolorselection.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -48,9 +48,9 @@ using namespace iParameter; -iggWidgetKeyColorSelection::iggWidgetKeyColorSelection(const iObjectKey &key, iggFrame *parent, bool horizontal, int index, const iObjectKey *indkey) : iggWidgetKeyHandler(WidgetType::Other,key,RenderMode::Immediate,parent,index,indkey) +iggWidgetKeyColorSelection::iggWidgetKeyColorSelection(const iObjectKey &key, iggFrame *parent, int index, const iObjectKey *indkey) : iggWidgetKeyHandler(WidgetType::Other,key,RenderMode::Immediate,parent,index,indkey) { - mSubject = iggSubjectFactory::CreateWidgetColorSelectionSubject(this,horizontal); + mSubject = iggSubjectFactory::CreateWidgetColorSelectionSubject(this); } diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeycolorselection.h ifrit-3.4.2/shells/generic/iggwidgetkeycolorselection.h --- ifrit-3.3.4/shells/generic/iggwidgetkeycolorselection.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeycolorselection.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -46,7 +46,7 @@ public: - iggWidgetKeyColorSelection(const iObjectKey &key, iggFrame *parent, bool horizontal, int index = -1, const iObjectKey *indkey = 0); + iggWidgetKeyColorSelection(const iObjectKey &key, iggFrame *parent, int index = -1, const iObjectKey *indkey = 0); void SetText(const iString &text); diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyhandler.cpp ifrit-3.4.2/shells/generic/iggwidgetkeyhandler.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeyhandler.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyhandler.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyhandler.h ifrit-3.4.2/shells/generic/iggwidgetkeyhandler.h --- ifrit-3.3.4/shells/generic/iggwidgetkeyhandler.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyhandler.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyhandlertemplate.h ifrit-3.4.2/shells/generic/iggwidgetkeyhandlertemplate.h --- ifrit-3.3.4/shells/generic/iggwidgetkeyhandlertemplate.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyhandlertemplate.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -29,8 +29,10 @@ #include "iggwidgetkeyhandler.h" +#include "iconsole.h" #include "icontrolmodule.h" #include "ierror.h" +#include "ierrorstatus.h" #include "iobjecthelp.h" #include "ishell.h" @@ -105,6 +107,11 @@ bool ren = (this->GetRenderMode()==RenderMode::Immediate || (final && this->GetRenderMode()!=RenderMode::NoRender)); bool ret = this->GetShell()->GetControlModule()->Execute(ws,ren && this->GetMainWindow()->IsAutoRender(),this->GetExecuteFlags()); + if(!ret && this->GetShell()->GetControlModule()->GetErrorStatus()->IsError()) + { + iConsole::Display(iConsole::_HighError,this->GetShell()->GetControlModule()->GetErrorStatus()->Message()); + } + if(this->mSelfChecking && (final || this->GetRenderMode()==RenderMode::Immediate)) { this->UpdateWidget(); diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeylineedit.cpp ifrit-3.4.2/shells/generic/iggwidgetkeylineedit.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeylineedit.cpp 2011-01-27 17:52:31.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeylineedit.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -33,7 +33,15 @@ #include "iggwidgetkeylineedit.h" +#include "iimage.h" +#include "iimagefactory.h" + #include "iggframe.h" +#include "iggmainwindow.h" + +#include "ibgwidgetbuttonsubject.h" + +#include "iggsubjectfactory.h" // // templates @@ -163,4 +171,132 @@ { } + +// +//****************************************** +// +// FileNameLineEdit class +// +//****************************************** +// +#include "icontrolmodule.h" + +#include "iggwidgetotherbutton.h" + +namespace iggWidgetKeyFileNameLineEdit_Private +{ + class OpenButton : public iggWidgetSimpleButton + { + + public: + + OpenButton(iggWidgetKeyFileNameLineEdit *owner, iggFrame *parent) : iggWidgetSimpleButton("",parent,true) + { + mOwner = owner; + mWasLaidOut = true; + this->SetBaloonHelp("Open Load File Dialog"); + } + + ibgWidgetButtonSubject* GetSubject() const { return mSubject; } + + protected: + + virtual void Execute() + { + mOwner->OpenLoadFileDialog(); + } + + iggWidgetKeyFileNameLineEdit *mOwner; + }; + + class UnloadButton : public iggWidgetSimpleButton + { + + public: + + UnloadButton(iggWidgetKeyFileNameLineEdit *owner, iggFrame *parent) : iggWidgetSimpleButton("",parent,true) + { + mOwner = owner; + mWasLaidOut = true; + this->SetBaloonHelp("Unload the file"); + } + + ibgWidgetButtonSubject* GetSubject() const { return mSubject; } + + protected: + + virtual void Execute() + { + mOwner->UnloadFile(); + } + + iggWidgetKeyFileNameLineEdit *mOwner; + }; +}; + + +iggWidgetKeyFileNameLineEdit::iggWidgetKeyFileNameLineEdit(bool render, const iString &header, const iString &location, const iString &selection, bool exists, const iString &label, bool unloadable, const iObjectKey &key, iggFrame *parent, int index, const iObjectKey *indkey) : iggWidgetKeyTextLineEdit(true,label,key,RenderMode::NoRender,parent,index,indkey) +{ + mRender = render; + mHeader = header; + mLocation = location; + mSelection = selection; + mFileExists = exists; + mUnloadable = unloadable; + + iggWidgetKeyFileNameLineEdit_Private::OpenButton *w1 = new iggWidgetKeyFileNameLineEdit_Private::OpenButton(this,parent); IERROR_ASSERT(w1); + w1->GetSubject()->SetFlat(true); + w1->GetSubject()->SetSize(18,18); + w1->GetSubject()->SetIcon(*iImageFactory::FindIcon("fileopen2.png")); + this->mSubject->AddButton(w1->GetSubject()); + + iggWidgetKeyFileNameLineEdit_Private::UnloadButton *w2 = new iggWidgetKeyFileNameLineEdit_Private::UnloadButton(this,parent); IERROR_ASSERT(w2); + w2->GetSubject()->SetFlat(true); + w2->GetSubject()->SetSize(18,18); + w2->GetSubject()->SetIcon(*iImageFactory::FindIcon(unloadable?"remove.png":"remove2.png")); + this->mSubject->AddButton(w2->GetSubject()); + w2->Enable(unloadable); + +} + + +void iggWidgetKeyFileNameLineEdit::OnVoid1Body() +{ + this->OpenLoadFileDialog(); +} + + +void iggWidgetKeyFileNameLineEdit::UnloadFile() +{ + if(mUnloadable) + { + this->SetText(""); + this->iggWidgetKeyTextLineEdit::ExecuteControl(true); + this->UpdateWidget(); + this->UpdateDependents(); + if(mRender) this->GetShell()->GetControlModule()->Render(iParameter::RenderOption::All); + } +} + + +void iggWidgetKeyFileNameLineEdit::OpenLoadFileDialog() +{ + iString name = this->GetMainWindow()->GetFileName(mHeader,mSubject->GetText().IsEmpty()?mLocation:mSubject->GetText(),mSelection,mFileExists); + if(!name.IsEmpty() || mUnloadable) + { + this->SetText(name); + this->iggWidgetKeyTextLineEdit::ExecuteControl(true); + this->UpdateWidget(); + this->UpdateDependents(); + if(mRender) this->GetShell()->GetControlModule()->Render(iParameter::RenderOption::All); + } +} + + +void iggWidgetKeyFileNameLineEdit::UpdateWidgetBody() +{ + this->iggWidgetKeyTextLineEdit::UpdateWidgetBody(); + mSubject->ShowTail(); +} + #endif diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeylineedit.h ifrit-3.4.2/shells/generic/iggwidgetkeylineedit.h --- ifrit-3.3.4/shells/generic/iggwidgetkeylineedit.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeylineedit.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -36,12 +36,14 @@ // iggWidgetKeyFloatLineEdit; // iggWidgetKeyPositionLineEdit; // iggWidgetKeySizeLineEdit; +// iggWidgetKeyFileNameLineEdit; // #include "iggwidgetkeyhandler.h" #include "istring.h" +class ibgWidgetButtonSubject; class ibgWidgetEntrySubject; @@ -136,5 +138,25 @@ iggWidgetKeySizeLineEdit(const iString &label, const iObjectKey &key, int rm, iggFrame *parent, int index = -1, const iObjectKey *indkey = 0); }; + +class iggWidgetKeyFileNameLineEdit : public iggWidgetKeyTextLineEdit +{ + +public: + + iggWidgetKeyFileNameLineEdit(bool render, const iString &header, const iString &location, const iString &selection, bool exists, const iString &label, bool unloadable, const iObjectKey &key, iggFrame *parent, int index = -1, const iObjectKey *indkey = 0); + + void OpenLoadFileDialog(); + void UnloadFile(); + +protected: + + virtual void OnVoid1Body(); + virtual void UpdateWidgetBody(); + + bool mFileExists, mUnloadable, mRender; + iString mHeader, mLocation, mSelection; +}; + #endif // IGGWIDGETKEYLINEEDIT_H diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeylineedittemplate.h ifrit-3.4.2/shells/generic/iggwidgetkeylineedittemplate.h --- ifrit-3.3.4/shells/generic/iggwidgetkeylineedittemplate.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeylineedittemplate.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -49,8 +49,17 @@ template iggWidgetKeyLineEdit::iggWidgetKeyLineEdit(bool numeric, bool readonly, const iString &label, const iObjectKey &key, int rm, iggFrame *parent, int index, const iObjectKey *indkey) : iggWidgetKeyHandler(WidgetType::Entry,key,rm,parent,index,indkey) { - this->mSubject = this->mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,(numeric)?10:0,label,(rm==RenderMode::NoRender)?0:new iggWidgetRenderModeButton(this)); IERROR_ASSERT(mSubject); + + this->mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,(numeric)?10:0,label); IERROR_ASSERT(mSubject); this->mSubject->SetEditable(!readonly); + + if(rm != RenderMode::NoRender) + { + iggWidgetRenderModeButton *rm = new iggWidgetRenderModeButton(this); IERROR_ASSERT(rm); + rm->ClearLaidOutFlag(this->mSubject); + this->mSubject->AddButton(rm->GetSubject()); + } + this->SetRenderMode(rm); } diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyselectionbox.cpp ifrit-3.4.2/shells/generic/iggwidgetkeyselectionbox.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeyselectionbox.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyselectionbox.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyselectionbox.h ifrit-3.4.2/shells/generic/iggwidgetkeyselectionbox.h --- ifrit-3.3.4/shells/generic/iggwidgetkeyselectionbox.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyselectionbox.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyslider.cpp ifrit-3.4.2/shells/generic/iggwidgetkeyslider.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeyslider.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyslider.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyslider.h ifrit-3.4.2/shells/generic/iggwidgetkeyslider.h --- ifrit-3.3.4/shells/generic/iggwidgetkeyslider.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyslider.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeyslidertemplate.h ifrit-3.4.2/shells/generic/iggwidgetkeyslidertemplate.h --- ifrit-3.3.4/shells/generic/iggwidgetkeyslidertemplate.h 2011-01-27 17:52:20.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeyslidertemplate.h 2013-07-11 01:23:55.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -47,9 +47,17 @@ template iggWidgetKeySlider::iggWidgetKeySlider(int numdig, const iString &label, const iObjectKey &key, int rm, iggFrame *parent, int index, const iObjectKey *indkey) : iggWidgetKeyHandler(WidgetType::Entry,key,rm,parent,index,indkey) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,numdig,label,(rm==RenderMode::NoRender)?0:new iggWidgetRenderModeButton(this)); + this->mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,true,numdig,label); new iggWidgetSlider(numdig,label,mSubject,this); this->mSubject->SetStretch(0,10,0); + + if(rm != RenderMode::NoRender) + { + iggWidgetRenderModeButton *rm = new iggWidgetRenderModeButton(this); IERROR_ASSERT(rm); + rm->ClearLaidOutFlag(this->mSubject); + this->mSubject->AddButton(rm->GetSubject()); + } + this->SetRenderMode(rm); this->mHighResolutionValue = false; diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeytrackball.cpp ifrit-3.4.2/shells/generic/iggwidgetkeytrackball.cpp --- ifrit-3.3.4/shells/generic/iggwidgetkeytrackball.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeytrackball.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -68,7 +68,15 @@ } mIsVectorKey = (this->GetKey().Dimension() == 3); - mSubject = iggSubjectFactory::CreateWidgetTrackBallSubject(this,followCamera,(rm==RenderMode::NoRender)?0:new iggWidgetRenderModeButton(this)); + mSubject = iggSubjectFactory::CreateWidgetTrackBallSubject(this,followCamera); + + if(rm != RenderMode::NoRender) + { + iggWidgetRenderModeButton *rm = new iggWidgetRenderModeButton(this); IERROR_ASSERT(rm); + rm->ClearLaidOutFlag(mSubject); + mSubject->AddButton(rm->GetSubject()); + } + this->SetRenderMode(rm); } diff -Nru ifrit-3.3.4/shells/generic/iggwidgetkeytrackball.h ifrit-3.4.2/shells/generic/iggwidgetkeytrackball.h --- ifrit-3.3.4/shells/generic/iggwidgetkeytrackball.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetkeytrackball.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetmisc.cpp ifrit-3.4.2/shells/generic/iggwidgetmisc.cpp --- ifrit-3.3.4/shells/generic/iggwidgetmisc.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetmisc.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -123,7 +123,7 @@ // iggWidgetNumberDisplay::iggWidgetNumberDisplay(const iString &title, iggFrame *parent) : iggWidget(parent) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,6,title,0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,6,title); mSubject->SetEditable(false); mNeedsBaloonHelp = false; @@ -156,7 +156,7 @@ // iggWidgetTextDisplay::iggWidgetTextDisplay(const iString &title, iggFrame *parent) : iggWidget(parent) { - mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,title,0); + mSubject = iggSubjectFactory::CreateWidgetEntrySubject(this,false,0,title); mSubject->SetEditable(false); mNeedsBaloonHelp = false; diff -Nru ifrit-3.3.4/shells/generic/iggwidgetmisc.h ifrit-3.4.2/shells/generic/iggwidgetmisc.h --- ifrit-3.3.4/shells/generic/iggwidgetmisc.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetmisc.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetotherbutton.cpp ifrit-3.4.2/shells/generic/iggwidgetotherbutton.cpp --- ifrit-3.3.4/shells/generic/iggwidgetotherbutton.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetotherbutton.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetotherbutton.h ifrit-3.4.2/shells/generic/iggwidgetotherbutton.h --- ifrit-3.3.4/shells/generic/iggwidgetotherbutton.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetotherbutton.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetprogressbar.cpp ifrit-3.4.2/shells/generic/iggwidgetprogressbar.cpp --- ifrit-3.3.4/shells/generic/iggwidgetprogressbar.cpp 2011-01-27 17:52:32.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetprogressbar.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetprogressbar.h ifrit-3.4.2/shells/generic/iggwidgetprogressbar.h --- ifrit-3.3.4/shells/generic/iggwidgetprogressbar.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetprogressbar.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgetrendermodebutton.cpp ifrit-3.4.2/shells/generic/iggwidgetrendermodebutton.cpp --- ifrit-3.3.4/shells/generic/iggwidgetrendermodebutton.cpp 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetrendermodebutton.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -72,7 +72,7 @@ mSubject = iggSubjectFactory::CreateWidgetButtonSubject(this,ButtonType::ToolButton,"",1); mSubject->SetFlat(true); - mSubject->SetSize(16,16); + mSubject->SetSize(18,18); // // Since the subject belongs to something else, detach it diff -Nru ifrit-3.3.4/shells/generic/iggwidgetrendermodebutton.h ifrit-3.4.2/shells/generic/iggwidgetrendermodebutton.h --- ifrit-3.3.4/shells/generic/iggwidgetrendermodebutton.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgetrendermodebutton.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/generic/iggwidgettext.cpp ifrit-3.4.2/shells/generic/iggwidgettext.cpp --- ifrit-3.3.4/shells/generic/iggwidgettext.cpp 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgettext.cpp 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -104,10 +104,10 @@ } -/*iString iggWidgetTextEditor::GetText() const +iString iggWidgetTextEditor::GetText() const { return mSubject->GetText(); -}*/ +} iString iggWidgetTextEditor::GetLine(int n) const diff -Nru ifrit-3.3.4/shells/generic/iggwidgettext.h ifrit-3.4.2/shells/generic/iggwidgettext.h --- ifrit-3.3.4/shells/generic/iggwidgettext.h 2011-01-27 17:52:21.000000000 +0000 +++ ifrit-3.4.2/shells/generic/iggwidgettext.h 2013-07-11 01:23:56.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -90,7 +90,7 @@ void Clear(); void SetModified(bool s); virtual void SetText(const iString &text); -// iString GetText() const; + iString GetText() const; // void AppendText(const iString &text); // diff -Nru ifrit-3.3.4/shells/qt/iqt.h ifrit-3.4.2/shells/qt/iqt.h --- ifrit-3.3.4/shells/qt/iqt.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqt.h 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtdialogsubject.cpp ifrit-3.4.2/shells/qt/iqtdialogsubject.cpp --- ifrit-3.3.4/shells/qt/iqtdialogsubject.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtdialogsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtdialogsubject.h ifrit-3.4.2/shells/qt/iqtdialogsubject.h --- ifrit-3.3.4/shells/qt/iqtdialogsubject.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtdialogsubject.h 2013-07-11 01:24:01.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtexplicitframesubject.cpp ifrit-3.4.2/shells/qt/iqtexplicitframesubject.cpp --- ifrit-3.3.4/shells/qt/iqtexplicitframesubject.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtexplicitframesubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -192,6 +192,7 @@ iqtWidgetHelper *tmp = iDynamicCast(INFO,child->GetWidgetHelper()); #ifdef IQT_3 mLayout->addMultiCellWidget(tmp->GetWidget(),row,row,col,col+nc-1); + this->clearWFlags(WState_Polished); #else mLayout->addWidget(tmp->GetWidget(),row,col,1,nc); #endif @@ -208,12 +209,24 @@ // void iqtExplicitFrameSubject::show() { + if(this->BeforeShow()) + { +#ifdef IQT_3 + this->Qt3Fix(); +#endif + } QGroupBox::show(); } void iqtExplicitFrameSubject::showEvent(QShowEvent *e) { + if(this->BeforeShow()) + { +#ifdef IQT_3 + this->Qt3Fix(); +#endif + } QGroupBox::showEvent(e); mFrameOwner->UpdateWidget(); } @@ -231,4 +244,14 @@ #endif } + +#ifdef IQT_3 +#include + +void iqtExplicitFrameSubject::Qt3Fix() +{ + qApp->processEvents(); +} +#endif + #endif diff -Nru ifrit-3.3.4/shells/qt/iqtexplicitframesubject.h ifrit-3.4.2/shells/qt/iqtexplicitframesubject.h --- ifrit-3.3.4/shells/qt/iqtexplicitframesubject.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtexplicitframesubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -80,6 +80,10 @@ QGridLayout *mLayout; int mNumCols, mNumRows; + +private: + + void Qt3Fix(); }; #endif // IQTEXPLICITFRAMESUBJECT_H diff -Nru ifrit-3.3.4/shells/qt/iqtextensionwindowsubject.cpp ifrit-3.4.2/shells/qt/iqtextensionwindowsubject.cpp --- ifrit-3.3.4/shells/qt/iqtextensionwindowsubject.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtextensionwindowsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtextensionwindowsubject.h ifrit-3.4.2/shells/qt/iqtextensionwindowsubject.h --- ifrit-3.3.4/shells/qt/iqtextensionwindowsubject.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtextensionwindowsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtframesubject.cpp ifrit-3.4.2/shells/qt/iqtframesubject.cpp --- ifrit-3.3.4/shells/qt/iqtframesubject.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtframesubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtframesubject.h ifrit-3.4.2/shells/qt/iqtframesubject.h --- ifrit-3.3.4/shells/qt/iqtframesubject.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtframesubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqthelper.cpp ifrit-3.4.2/shells/qt/iqthelper.cpp --- ifrit-3.3.4/shells/qt/iqthelper.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqthelper.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqthelper.h ifrit-3.4.2/shells/qt/iqthelper.h --- ifrit-3.3.4/shells/qt/iqthelper.h 2011-01-27 17:52:33.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqthelper.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtmainwindowsubject.cpp ifrit-3.4.2/shells/qt/iqtmainwindowsubject.cpp --- ifrit-3.3.4/shells/qt/iqtmainwindowsubject.cpp 2011-01-27 17:52:36.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtmainwindowsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -144,8 +144,6 @@ mMainFrame = 0; mDockingWorkspace = 0; - mIsMoveAll = false; - // // Available themes // @@ -425,26 +423,12 @@ } -void iqtMainWindowSubject::keyPressEvent(QKeyEvent *e) -{ - mIsMoveAll = (e->key() == Qt::Key_Shift); - QMainWindow::keyPressEvent(e); -} - - -void iqtMainWindowSubject::keyReleaseEvent(QKeyEvent *e) -{ - mIsMoveAll = false; - QMainWindow::keyReleaseEvent(e); -} - - void iqtMainWindowSubject::moveEvent(QMoveEvent *e) { int pos[2]; pos[0] = this->x(); pos[1] = this->y(); - mMainWindow->MoveWindows(pos,mIsMoveAll); + mMainWindow->MoveWindows(pos); QMainWindow::moveEvent(e); } diff -Nru ifrit-3.3.4/shells/qt/iqtmainwindowsubject.h ifrit-3.4.2/shells/qt/iqtmainwindowsubject.h --- ifrit-3.3.4/shells/qt/iqtmainwindowsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtmainwindowsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -83,8 +83,8 @@ virtual void moveEvent(QMoveEvent *e); virtual void closeEvent(QCloseEvent *e); virtual void resizeEvent(QResizeEvent *e); - virtual void keyPressEvent(QKeyEvent *e); - virtual void keyReleaseEvent(QKeyEvent *e); +// virtual void keyPressEvent(QKeyEvent *e); +// virtual void keyReleaseEvent(QKeyEvent *e); // virtual void focusInEvent(QFocusEvent *e); // virtual void focusOutEvent(QFocusEvent *e); @@ -94,7 +94,6 @@ QWidget *mMainFrame; QWorkspace *mDockingWorkspace; - bool mIsMoveAll; iqtMainWindowSubject(const iqtMainWindowSubject&); // Not implemented. void operator=(const iqtMainWindowSubject&); // Not implemented. diff -Nru ifrit-3.3.4/shells/qt/iqtmenuwindowsubject.cpp ifrit-3.4.2/shells/qt/iqtmenuwindowsubject.cpp --- ifrit-3.3.4/shells/qt/iqtmenuwindowsubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtmenuwindowsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtmenuwindowsubject.h ifrit-3.4.2/shells/qt/iqtmenuwindowsubject.h --- ifrit-3.3.4/shells/qt/iqtmenuwindowsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtmenuwindowsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtrenderwindowsubject.cpp ifrit-3.4.2/shells/qt/iqtrenderwindowsubject.cpp --- ifrit-3.3.4/shells/qt/iqtrenderwindowsubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtrenderwindowsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -194,7 +194,7 @@ } -void* iqtRenderWindowSubject::GetDisplayId() const +void* iqtRenderWindowSubject::GetDisplay() const { #if defined(Q_WS_X11) #ifdef IQT_3 @@ -208,6 +208,12 @@ } +void* iqtRenderWindowSubject::GetContext() const +{ + return (void *)this->context(); +} + + void* iqtRenderWindowSubject::GetWindowId() const { return (void *)this->winId(); @@ -385,6 +391,12 @@ } +bool iqtRenderWindowSubject::IsDirect() const +{ + return this->format().directRendering(); +} + + bool iqtRenderWindowSubject::IsCurrent() const { return this->context() == QGLContext::currentContext(); diff -Nru ifrit-3.3.4/shells/qt/iqtrenderwindowsubject.h ifrit-3.4.2/shells/qt/iqtrenderwindowsubject.h --- ifrit-3.3.4/shells/qt/iqtrenderwindowsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtrenderwindowsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -74,13 +74,15 @@ virtual void SetFullScreen(bool); virtual void MakeCurrent(); - virtual void* GetDisplayId() const; + virtual void* GetDisplay() const; + virtual void* GetContext() const; virtual void* GetWindowId() const; virtual void SetWindowName(const iString &s); virtual void RenderIntoMemory(iImage &image); virtual bool IsReadyForDumpingImage(); + virtual bool IsDirect() const; virtual bool IsCurrent() const; virtual void RequestStereo(bool s); diff -Nru ifrit-3.3.4/shells/qt/iqtshellsubject.cpp ifrit-3.4.2/shells/qt/iqtshellsubject.cpp --- ifrit-3.3.4/shells/qt/iqtshellsubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtshellsubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtshellsubject.h ifrit-3.4.2/shells/qt/iqtshellsubject.h --- ifrit-3.3.4/shells/qt/iqtshellsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtshellsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetareasubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetareasubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetareasubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetareasubject.cpp 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetareasubject.h ifrit-3.4.2/shells/qt/iqtwidgetareasubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetareasubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetareasubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetbuttonsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetbuttonsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetbuttonsubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetbuttonsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetbuttonsubject.h ifrit-3.4.2/shells/qt/iqtwidgetbuttonsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetbuttonsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetbuttonsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetcolorselectionsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetcolorselectionsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetcolorselectionsubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetcolorselectionsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -58,7 +58,7 @@ #endif -iqtWidgetColorSelectionSubject::iqtWidgetColorSelectionSubject(iggWidget *owner, bool horizontal) : QWidget(iqtHelper::Convert(owner->GetParent())), ibgWidgetColorSelectionSubject(owner,horizontal) +iqtWidgetColorSelectionSubject::iqtWidgetColorSelectionSubject(iggWidget *owner) : QWidget(iqtHelper::Convert(owner->GetParent())), ibgWidgetColorSelectionSubject(owner), mSize(16) { mWidgetHelper = new iqtWidgetHelper(this,owner); IERROR_ASSERT(mWidgetHelper); @@ -66,38 +66,11 @@ // Create a layout // if(this->layout() != 0) delete this->layout(); - QGridLayout *l; - if(horizontal) l = iqtHelper::NewLayout(this,2); else - { - l = iqtHelper::NewLayout(this,1); -#ifdef IQT_3 - l->expand(3,1); -#endif - } - - mLabel = new QLabel(this); - mLabel->setFrameStyle(QFrame::Panel | QFrame::Sunken); - mLabel->setLineWidth(2); -#ifndef IQT_3 -#ifndef IQT_40 - mLabel->setAutoFillBackground(true); -#endif -#endif - mLabel->setScaledContents(true); - mLabel->setMinimumSize(24,24); - if(horizontal) - { - l->addWidget(mLabel,0,0); - } - else - { - l->addWidget(mLabel,1,0); - l->setRowStretch(0,10); - } + QGridLayout *l = iqtHelper::NewLayout(this,1); mButton = new QPushButton(this); mButton->setText("Color"); - if(horizontal) l->addWidget(mButton,0,1); else l->addWidget(mButton,2,0); + l->addWidget(mButton,0,0); this->setSizePolicy(QSizePolicy(QSizePolicy::Minimum,QSizePolicy::Minimum)); @@ -112,25 +85,44 @@ const iColor iqtWidgetColorSelectionSubject::GetColor() const { -#ifdef IQT_3 - QColor c0 = mLabel->paletteBackgroundColor(); -#else - QColor c0 = mLabel->palette().color(mLabel->backgroundRole()); -#endif - - QColor c = QColorDialog::getColor(c0); + QColor c = QColorDialog::getColor(mColor); if(c.isValid()) { - iqtHelper::SetBackground(mLabel,c); + mColor = c; + this->DisplayColor(); } - else c = c0; - return iqtHelper::Convert(c); + return iqtHelper::Convert(mColor); } void iqtWidgetColorSelectionSubject::SetColor(const iColor &v) { - iqtHelper::SetBackground(mLabel,iqtHelper::Convert(v)); + mColor = iqtHelper::Convert(v); + this->DisplayColor(); +} + + +#ifdef IQT_3 +#include +#include +#else +//#include +#include +#endif + + +void iqtWidgetColorSelectionSubject::DisplayColor() const +{ + QPixmap p(mSize,mSize); + p.fill(mColor); + QPainter w(&p); +#ifdef IQT_3 + qDrawShadePanel(&w,0,0,mSize,mSize,mButton->colorGroup(),true,2,0); + mButton->setIconSet(QIconSet(p)); +#else + qDrawShadePanel(&w,0,0,mSize,mSize,mButton->palette(),true,2,0); + mButton->setIcon(QIcon(p)); +#endif } diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetcolorselectionsubject.h ifrit-3.4.2/shells/qt/iqtwidgetcolorselectionsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetcolorselectionsubject.h 2011-01-27 17:52:34.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetcolorselectionsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -64,12 +64,15 @@ protected: - iqtWidgetColorSelectionSubject(iggWidget *owner, bool horizontal); + iqtWidgetColorSelectionSubject(iggWidget *owner); + + void DisplayColor() const; iqtCallbackHelper *mCallbackHelper; - QLabel *mLabel; QPushButton *mButton; + mutable QColor mColor; + const int mSize; }; #endif // IQTWIDGETKEYCOLORSELECTIONSUBJECT_H diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetentrysubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetentrysubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetentrysubject.cpp 2011-01-27 17:52:37.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetentrysubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -123,6 +123,12 @@ protected: + virtual void mouseDoubleClickEvent(QMouseEvent *e) + { + e->accept(); + emit returnPressed(); + } + virtual void keyPressEvent(QKeyEvent *e) { if(mDelayed && !this->text().isEmpty() && e->key()!=Qt::Key_Up && e->key()!=Qt::Key_Down) @@ -176,7 +182,7 @@ }; -iqtWidgetEntrySubject::iqtWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb) : QWidget(iqtHelper::Convert(owner->GetParent())), ibgWidgetEntrySubject(owner,slider,numdig,label,rmb) +iqtWidgetEntrySubject::iqtWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label) : QWidget(iqtHelper::Convert(owner->GetParent())), ibgWidgetEntrySubject(owner,slider,numdig,label) { mWidgetHelper = new iqtWidgetHelper(this,owner); IERROR_ASSERT(mWidgetHelper); @@ -233,17 +239,7 @@ iqtHelper::SetBackground(mView,0); if(numdig <= 0) mView->hide(); - if(rmb != 0) - { - iqtWidgetButtonSubject *rmbs = iDynamicCast(INFO,rmb->GetSubject()); - iqtHelper::SetParent(rmbs,this); -#ifdef IQT_3 - w->expand(1,4); - w->addWidget(rmbs,0,3); -#else - w->addWidget(rmbs,0,4); -#endif - } + mNumButtons = 0; this->setSizePolicy(QSizePolicy(QSizePolicy::Expanding,QSizePolicy::Minimum)); } @@ -254,6 +250,25 @@ } +void iqtWidgetEntrySubject::AddButton(ibgWidgetButtonSubject* button) +{ + if(button != 0) + { + QGridLayout *w = iDynamicCast(INFO,this->layout()); + iqtWidgetButtonSubject *bs = iDynamicCast(INFO,button); + iqtHelper::SetParent(bs,this); + + mNumButtons++; +#ifdef IQT_3 + w->expand(1,mNumButtons+3); + w->addWidget(bs,0,mNumButtons+2); +#else + w->addWidget(bs,0,mNumButtons+3); +#endif + } +} + + int iqtWidgetEntrySubject::GetValue() const { return mSlider->value(); @@ -366,6 +381,12 @@ } +void iqtWidgetEntrySubject::ShowTail() +{ + mEdit->end(false); +} + + void iqtWidgetEntrySubject::SetStretch(int label, int slider, int number) { QGridLayout *l = iDynamicCast(INFO,this->layout()); diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetentrysubject.h ifrit-3.4.2/shells/qt/iqtwidgetentrysubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetentrysubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetentrysubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -59,6 +59,7 @@ virtual ~iqtWidgetEntrySubject(); + virtual void AddButton(ibgWidgetButtonSubject* button); virtual void SetEditable(bool s); virtual void SetDelayedEdit(bool s); @@ -77,18 +78,22 @@ virtual void SetText(const iString &text); virtual void SelectText(int start, int len = -1); + virtual void ShowTail(); + virtual void SetStretch(int label, int slider, int number = 0); void OnKeyUpDown(bool up); protected: - iqtWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label, iggWidgetRenderModeButton* rmb); + iqtWidgetEntrySubject(iggWidget *owner, bool slider, int numdig, const iString &label); void SetDoubleValue(int v, double dv, bool withEdit); iqtCallbackHelper *mCallbackHelper; + int mNumButtons; + QLCDNumber *mView; QLineEdit *mEdit; QSlider *mSlider; diff -Nru ifrit-3.3.4/shells/qt/iqtwidgethelpbrowsersubject.cpp ifrit-3.4.2/shells/qt/iqtwidgethelpbrowsersubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgethelpbrowsersubject.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgethelpbrowsersubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgethelpbrowsersubject.h ifrit-3.4.2/shells/qt/iqtwidgethelpbrowsersubject.h --- ifrit-3.3.4/shells/qt/iqtwidgethelpbrowsersubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgethelpbrowsersubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgethelper.cpp ifrit-3.4.2/shells/qt/iqtwidgethelper.cpp --- ifrit-3.3.4/shells/qt/iqtwidgethelper.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgethelper.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgethelper.h ifrit-3.4.2/shells/qt/iqtwidgethelper.h --- ifrit-3.3.4/shells/qt/iqtwidgethelper.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgethelper.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetprogressbarsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetprogressbarsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetprogressbarsubject.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetprogressbarsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetprogressbarsubject.h ifrit-3.4.2/shells/qt/iqtwidgetprogressbarsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetprogressbarsubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetprogressbarsubject.h 2013-07-11 01:24:02.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetselectionboxsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgetselectionboxsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgetselectionboxsubject.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetselectionboxsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgetselectionboxsubject.h ifrit-3.4.2/shells/qt/iqtwidgetselectionboxsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgetselectionboxsubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgetselectionboxsubject.h 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgettexteditorsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgettexteditorsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgettexteditorsubject.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgettexteditorsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgettexteditorsubject.h ifrit-3.4.2/shells/qt/iqtwidgettexteditorsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgettexteditorsubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgettexteditorsubject.h 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwidgettrackballsubject.cpp ifrit-3.4.2/shells/qt/iqtwidgettrackballsubject.cpp --- ifrit-3.3.4/shells/qt/iqtwidgettrackballsubject.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgettrackballsubject.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -82,11 +82,11 @@ // // Constructs a iTrackball. // -iqtWidgetTrackBallSubject::iqtWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb) : QWidget(iqtHelper::Convert(owner->GetParent()) +iqtWidgetTrackBallSubject::iqtWidgetTrackBallSubject(iggWidget *owner, bool followCamera) : QWidget(iqtHelper::Convert(owner->GetParent()) #ifdef IQT_3 ,0,Qt::WRepaintNoErase #endif - ), ibgWidgetTrackBallSubject(owner,followCamera,rmb) + ), ibgWidgetTrackBallSubject(owner,followCamera) { mWidgetHelper = new iqtWidgetHelper(this,owner); IERROR_ASSERT(mWidgetHelper); // @@ -103,22 +103,6 @@ this->setSizePolicy(QSizePolicy(QSizePolicy::Expanding,QSizePolicy::Expanding)); this->setMinimumSize(mFixedSize,mFixedSize); - if(rmb != 0) - { -#ifdef IQT_3 - l->expand(2,2); -#endif - iqtWidgetButtonSubject *rmbs = iDynamicCast(INFO,rmb->GetSubject()); - iqtHelper::SetParent(rmbs,this); - l->addWidget(rmbs,0,1); -#ifdef IQT_3 - l->setColStretch(0,10); -#else - l->setColumnStretch(0,10); -#endif - l->setRowStretch(1,10); - } - mInUpdate = false; } @@ -142,6 +126,27 @@ } +void iqtWidgetTrackBallSubject::AddButton(ibgWidgetButtonSubject* button) +{ + if(button != 0) + { + QGridLayout *l = iDynamicCast(INFO,this->layout()); +#ifdef IQT_3 + l->expand(2,2); +#endif + iqtWidgetButtonSubject *bs = iDynamicCast(INFO,button); + iqtHelper::SetParent(bs,this); + l->addWidget(bs,0,1); +#ifdef IQT_3 + l->setColStretch(0,10); +#else + l->setColumnStretch(0,10); +#endif + l->setRowStretch(1,10); + } +} + + void iqtWidgetTrackBallSubject::Repaint() { this->update(); diff -Nru ifrit-3.3.4/shells/qt/iqtwidgettrackballsubject.h ifrit-3.4.2/shells/qt/iqtwidgettrackballsubject.h --- ifrit-3.3.4/shells/qt/iqtwidgettrackballsubject.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwidgettrackballsubject.h 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the @@ -62,8 +62,9 @@ protected: - iqtWidgetTrackBallSubject(iggWidget *owner, bool followCamera, iggWidgetRenderModeButton* rmb); + iqtWidgetTrackBallSubject(iggWidget *owner, bool followCamera); + virtual void AddButton(ibgWidgetButtonSubject* button); virtual void GetSizes(int &w0, int &h0, int &rad, int &cor); virtual void Repaint(); diff -Nru ifrit-3.3.4/shells/qt/iqtwindowhelper.cpp ifrit-3.4.2/shells/qt/iqtwindowhelper.cpp --- ifrit-3.3.4/shells/qt/iqtwindowhelper.cpp 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwindowhelper.cpp 2013-07-11 01:24:04.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/shells/qt/iqtwindowhelper.h ifrit-3.4.2/shells/qt/iqtwindowhelper.h --- ifrit-3.3.4/shells/qt/iqtwindowhelper.h 2011-01-27 17:52:35.000000000 +0000 +++ ifrit-3.4.2/shells/qt/iqtwindowhelper.h 2013-07-11 01:24:03.000000000 +0000 @@ -4,7 +4,7 @@ Language: C++ -Copyright (c) 2002-2011 Nick Gnedin +Copyright (c) 2002-2012 Nick Gnedin All rights reserved. This file may be distributed and/or modified under the terms of the diff -Nru ifrit-3.3.4/special/artio/artio.c ifrit-3.4.2/special/artio/artio.c --- ifrit-3.3.4/special/artio/artio.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,189 @@ +/* + * artio.c + * + * Created on: Feb 21, 2010 + * Author: Yongen Yu + */ + +#include +#include +#include +#include +#include + +#include "artio.h" +#include "artio_internal.h" + +#ifdef ARTIO_MPI +#include "artio_mpi.h" +#endif + +artio_file artio_fileset_open(char * file_prefix, int type, artio_context context) { + artio_fh head_fh; + char filename[256]; + int my_rank, num_procs; + int re; + + artio_file handle = (artio_file)malloc(sizeof(struct artio_file_struct)); + artio_parameter_list_init(&handle->param_list); + +#ifdef ARTIO_MPI + if(context == NULL) + { + fprintf(stderr,"Context cannot be NULL in the MPI mode.\n"); + return NULL; + } + MPI_Comm_size(context->comm, &num_procs); + MPI_Comm_rank(context->comm, &my_rank); +#else + num_procs = 1; + my_rank = 0; +#endif /* MPI */ + + handle->open_mode = ARTIO_FILESET_READ; + handle->open_type = type; + + handle->rank = my_rank; + handle->num_procs = num_procs; + handle->context = context; + strncpy(handle->file_prefix, file_prefix, 250); + + /* open header file */ + sprintf(filename, "%s.art", handle->file_prefix); + head_fh = artio_file_fopen(filename, + ARTIO_MODE_READ | ARTIO_MODE_ACCESS | ARTIO_MODE_DIRECT, context); + + if ( head_fh == NULL ) { + return NULL; + } + + re = artio_parameter_read(head_fh, &handle->param_list); + if ( re != ARTIO_SUCCESS ) { + return NULL; + } + + artio_file_fclose(head_fh); + + artio_parameter_get_long(handle, "num_root_cells", &handle->num_root_cells); + + /* default to accessing all sfc indices */ + handle->proc_sfc_begin = 0; + handle->proc_sfc_end = handle->num_root_cells-1; + handle->proc_sfc_index = NULL; + + /* open data files */ + if (type & ARTIO_OPEN_PARTICLES) { + re = artio_particle_open(handle); + if ( re != ARTIO_SUCCESS ) { + return NULL; + } + } + + if (type & ARTIO_OPEN_GRID) { + re = artio_grid_open(handle); + if ( re != ARTIO_SUCCESS ) { + return NULL; + } + } + + return handle; +} + +artio_file artio_fileset_create(char * file_prefix, int64_t root_cells, + int64_t proc_sfc_begin, int64_t proc_sfc_end, artio_context context) { + int my_rank, num_procs; + int64_t *proc_sfc_index; + artio_file handle; + +#ifdef ARTIO_MPI + if(context == NULL) + { + fprintf(stderr,"Context cannot be NULL in the MPI mode.\n"); + return NULL; + } + + MPI_Comm_size(context->comm, &num_procs); + MPI_Comm_rank(context->comm, &my_rank); + + if ( proc_sfc_begin < 0 || proc_sfc_end > root_cells ) { + return NULL; + } +#else + num_procs = 1; + my_rank = 0; + + if ( proc_sfc_begin != 0 || proc_sfc_end != root_cells-1 ) { + return NULL; + } +#endif /* MPI */ + + handle = (artio_file)malloc(sizeof(struct artio_file_struct)); + artio_parameter_list_init(&handle->param_list); + + handle->open_mode = ARTIO_FILESET_WRITE; + handle->open_type = 0; + + handle->rank = my_rank; + handle->num_procs = num_procs; + handle->context = context; + handle->num_root_cells = root_cells; + + strncpy(handle->file_prefix, file_prefix, 255); + + proc_sfc_index = (int64_t*)malloc((num_procs+1)*sizeof(int64_t)); + if ( proc_sfc_index == NULL ) { + fprintf(stderr, "ERROR ALLOCATING MEMORY!\n"); + exit(1); + } +#ifdef ARTIO_MPI + MPI_Allgather( &proc_sfc_begin, 1, MPI_LONG_LONG, proc_sfc_index, 1, MPI_LONG_LONG, context->comm ); +#else + proc_sfc_index[0] = 0; +#endif /* ARTIO_MPI */ + proc_sfc_index[handle->num_procs] = root_cells; + handle->proc_sfc_index = proc_sfc_index; + handle->proc_sfc_begin = proc_sfc_begin; + handle->proc_sfc_end = proc_sfc_end; + + artio_parameter_set_long(handle, "num_root_cells", root_cells); + + return handle; +} + +int artio_fileset_close(artio_file handle) { + char header_filename[256]; + artio_fh head_fh; + + if (handle->open_mode == ARTIO_FILESET_WRITE) { + sprintf(header_filename, "%s.art", handle->file_prefix); + head_fh = artio_file_fopen(header_filename, + ARTIO_MODE_WRITE | ARTIO_MODE_DIRECT | + ((handle->rank == 0) ? ARTIO_MODE_ACCESS : 0), handle->context); + + if (head_fh == NULL) { + return ARTIO_ERR_FILE_CREATE; + } + + if (0 == handle->rank) { + artio_parameter_write(head_fh, &handle->param_list); + } + + artio_file_fclose(head_fh); + free(handle->proc_sfc_index); + } + + if (handle->open_type & ARTIO_OPEN_GRID) { + artio_grid_close(handle); + free(handle->grid); + } + + if (handle->open_type & ARTIO_OPEN_PARTICLES) { + artio_particle_close(handle); + free(handle->particle); + } + + artio_parameter_free_list(&handle->param_list); + free(handle); + + return ARTIO_SUCCESS; +} diff -Nru ifrit-3.3.4/special/artio/artio.h ifrit-3.4.2/special/artio/artio.h --- ifrit-3.3.4/special/artio/artio.h 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio.h 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,368 @@ +/* + * artio.h + * + * Created on: Feb 21, 2010 + * Author: Yongen Yu + * Modified: Jun 6, 2010 - Doug Rudd + * Nov 18, 2010 - Doug Rudd + */ + +#ifndef __ARTIO_H__ +#define __ARTIO_H__ + +#include +#ifdef _WIN32 +typedef __int64 int64_t; +#endif + +#define ARTIO_FILESET_READ 0 +#define ARTIO_FILESET_WRITE 1 + +#define ARTIO_OPEN_PARTICLES 1 +#define ARTIO_OPEN_GRID 2 + +#define ARTIO_READ_LEAFS 1 +#define ARTIO_READ_REFINED 2 +#define ARTIO_READ_ALL 3 + +/* allocation strategy */ +#define ARTIO_ALLOC_EQUAL_SFC 0 +#define ARTIO_ALLOC_EQUAL_PROC 1 +#define ARTIO_ALLOC_MAX_FILE_SIZE 2 + +#define ARTIO_TYPE_STRING 0 +#define ARTIO_TYPE_CHAR 1 +#define ARTIO_TYPE_INT 2 +#define ARTIO_TYPE_FLOAT 3 +#define ARTIO_TYPE_DOUBLE 4 +#define ARTIO_TYPE_LONG 5 + +/* error codes */ +#define ARTIO_SUCCESS 0 + +#define ARTIO_ERR_PARAM_NOT_FOUND 1 +#define ARTIO_ERR_PARAM_INVALID_LENGTH 2 +#define ARTIO_ERR_PARAM_TYPE_MISMATCH 3 +#define ARTIO_ERR_PARAM_LENGTH_MISMATCH 4 +#define ARTIO_ERR_PARAM_LENGTH_INVALID 5 +#define ARTIO_ERR_PARAM_DUPLICATE 6 + +#define ARTIO_ERR_INVALID_FILESET_MODE 100 +#define ARTIO_ERR_INVALID_FILE_NUMBER 101 +#define ARTIO_ERR_INVALID_FILE_MODE 102 +#define ARTIO_ERR_INVALID_SFC_RANGE 103 +#define ARTIO_ERR_INVALID_SFC 104 +#define ARTIO_ERR_INVALID_STATE 105 +#define ARTIO_ERR_INVALID_SEEK 106 +#define ARTIO_ERR_INVALID_OCT_LEVELS 107 +#define ARTIO_ERR_INVALID_SPECIES 108 +#define ARTIO_ERR_INVALID_ALLOC_STRATEGY 109 +#define ARTIO_ERR_INVALID_LEVEL 110 +#define ARTIO_ERR_INVALID_PARAM_LIST 111 +#define ARTIO_ERR_INVALID_DATATYPE 112 + +#define ARTIO_ERR_DATA_EXISTS 200 +#define ARTIO_ERR_INSUFFICIENT_DATA 201 +#define ARTIO_ERR_FILE_CREATE 202 +#define ARTIO_ERR_PARTICLE_FILE_NOT_FOUND 203 +#define ARTIO_ERR_GRID_FILE_NOT_FOUND 204 +#define ARTIO_ERR_PARTICLE_CORRUPTED 205 +#define ARTIO_ERR_GRID_CORRUPTED 206 + +#define ARTIO_ERR_PARAM_CORRUPTED 207 +#define ARTIO_ERR_PARAM_CORRUPTED_MAGIC 208 + +#define ARTIO_ERR_64_TO_32_BIT_TRUNCATION 209 + +#define ARTIO_PARAMETER_EXHAUSTED 300 + +typedef struct artio_file_struct * artio_file; +typedef struct artio_param_list * artio_parameters; +typedef struct artio_context_struct * artio_context; + +/* + * Description: Open the file + * + * filename The file prefix + * type combination of ARTIO_OPEN_PARTICLES and ARTIO_OPEN_GRID flags + */ +artio_file artio_fileset_open(char * file_name, int type, artio_context context); + +/** + * Description: Create fileset and begin populating header information + * + * file_name file name of refined cells + * root_cells the number of root level cells + * proc_sfc_begin-end the range of local space-filling-curve indices + * handle the artio file handle + * + */ +artio_file artio_fileset_create(char * file_prefix, + int64_t root_cells, int64_t proc_sfc_begin, int64_t proc_sfc_end, artio_context context); + +/* + * Description Close the file + */ +int artio_fileset_close(artio_file handle); + +/* public parameter interface */ +int artio_parameter_iterate( artio_file handle, char *key, int *type, int *length ); +int artio_parameter_get_array_length(artio_file handle, char * key, int *length); + +void artio_parameter_set_int(artio_file handle, char * key, int32_t value); +int artio_parameter_get_int(artio_file handle, char * key, int32_t * value); + +void artio_parameter_set_int_array(artio_file handle, char * key, int length, + int32_t *values); +int artio_parameter_get_int_array(artio_file handle, char * key, int length, + int32_t *values); + +void artio_parameter_set_string(artio_file handle, char * key, char * value); +int artio_parameter_get_string(artio_file handle, char * key, char * value, int max_length); + +void artio_parameter_set_string_array(artio_file handle, char * key, + int length, char ** values); +int artio_parameter_get_string_array(artio_file handle, char * key, + int length, char ** values, int max_length); + +void artio_parameter_set_float(artio_file handle, char * key, float value); +int artio_parameter_get_float(artio_file handle, char * key, float * value); + +void artio_parameter_set_float_array(artio_file handle, char * key, + int length, float *values); +int artio_parameter_get_float_array(artio_file handle, char * key, + int length, float * values); + +void artio_parameter_set_double(artio_file handle, char * key, double value); +int artio_parameter_get_double(artio_file handle, char * key, double * value); + +void artio_parameter_set_double_array(artio_file handle, char * key, + int length, double * values); +int artio_parameter_get_double_array(artio_file handle, char * key, + int length, double *values); + +void artio_parameter_set_long(artio_file handle, char * key, int64_t value); +int artio_parameter_get_long(artio_file handle, char * key, int64_t *value); + +void artio_parameter_set_long_array(artio_file handle, char * key, + int length, int64_t *values); +int artio_parameter_get_long_array(artio_file handle, char * key, + int length, int64_t *values); + +/* public grid interface */ +typedef void (* GridCallBack)(float * variables, int level, int refined, + int64_t sfc_index); + +/* + * Description: Add a grid component to a fileset open for writing + * + * handle The fileset handle + * num_grid_files The number of grid files to create + * allocation_strategy How to apportion sfc indices to each grid file + * num_grid_variables The number of variables per cell + * grid_variable_labels Identifying labels for each variable + * num_levels_per_root_tree Maximum tree depth for each oct tree + * num_octs_per_root_tree Total octs in each oct tree + */ +int artio_fileset_add_grid(artio_file handle, + int num_grid_files, int allocation_strategy, + int num_grid_variables, + char ** grid_variable_labels, + int * num_levels_per_root_tree, + int * num_octs_per_root_tree ); + +/* + * Description: Output the variables of the root level cell and the hierarchy of the Oct tree correlated with this root level cell + * + * handle The File handle + * sfc The sfc index of root cell + * variables The variables of the root level cell + * level The depth of the Oct tree correlated to the root level cell + * num_level_octs The array store the number of Oct nodes each level + */ +int artio_grid_write_root_cell_begin(artio_file handle, int64_t sfc, + float * variables, int level, int * num_octs_per_level); + +/* + * Description: Do something at the end of writing the root level cell + */ +int artio_grid_write_root_cell_end(artio_file handle); + +/* + * Description: Do something at the beginning of each level + */ +int artio_grid_write_level_begin(artio_file handle, int level ); + +/* + * Description: Do something at the end of each level + */ +int artio_grid_write_level_end(artio_file handle); + +/* + * Description: Output the data of a special oct tree node to the file + * + * handle The handle of the file + * variables The array recording the variables of the eight cells belonging to this Octree node. + */ +int artio_grid_write_oct(artio_file handle, float *variables, int *refined); + +/* + * Description: Read the variables of the root level cell and the hierarchy of the Octtree + * correlated with this root level cell + * + * handle The File handle + * variables The variables of the root level cell + * level The depth of the OCT tree + * num_octs_per_level The number of node of each oct level + * + */ +int artio_grid_read_root_cell_begin(artio_file handle, int64_t sfc, float *variables, + int *num_tree_levels, int *num_octs_per_level); + +/* + * Description: Do something at the end of reading the root level cell + */ +int artio_grid_read_root_cell_end(artio_file handle); + +/* + * Description: Do something at the beginning of each level + */ +int artio_grid_read_level_begin(artio_file handle, int level ); + +/* + * Description: Do something at the end of each level + */ +int artio_grid_read_level_end(artio_file handle); + +/* + * Description: Read the data of a special oct tree node from the file + */ +int artio_grid_read_oct(artio_file handle, float *variables, int *refined); + +int artio_grid_cache_sfc_range(artio_file handle, int64_t sfc_start, int64_t sfc_end); + +/* + * Description: Read a segment of oct nodes + * + * handle file pointer + * sfc1 the start sfc index + * sfc2 the end sfc index + * max_level_to_read max level to read for each oct tree + * option 1. refined nodes; 2 leaf nodes; 3 all nodes + * callback callback function + */ +int artio_grid_read_sfc_range(artio_file handle, int64_t sfc1, int64_t sfc2, int min_level_to_read, + int max_level_to_read, int options, GridCallBack callback); + + +typedef void (* ParticleCallBack)(int64_t pid, + double *primary_variables, float *secondary_variables, + int species, int subspecies, int64_t sfc_index); + +/** + * header head file name + * num_particle_files the number of files to record refined cells + * allocation_strategy + * num_species number of particle species + * species_labels string identifier for each species + * handle the artio file handle + * + */ +int artio_fileset_add_particles(artio_file handle, + int num_particle_files, int allocation_strategy, + int num_species, char **species_labels, + int *num_primary_variables, + int *num_secondary_variables, + char ***primary_variable_labels_per_species, + char ***secondary_variable_labels_per_species, + int *num_particles_per_species_per_root_tree ); + +/* + * Description: Output the variables of the root level cell and the hierarchy of + * the oct-tree correlated with this root level cell + * + * handle The File handle + * sfc The sfc index of root cell + * variables The variables of the root level cell + * level The depth of the Oct tree correlated to the root level cell + * num_level_octs The array store the number of Oct nodes each level + */ +int artio_particle_write_root_cell_begin(artio_file handle, int64_t sfc, + int *num_particles_per_species); + +/* + * Description: Do something at the end of writing the root level cell + */ +int artio_particle_write_root_cell_end(artio_file handle); + +/* + * Description: Do something at the beginning of each level + */ +int artio_particle_write_species_begin(artio_file handle, int species ); + +/* + * Description: Do something at the end of each level + */ +int artio_particle_write_species_end(artio_file handle); + +/* + * Description: Output the data of a special oct tree node to the file + * + * handle The handle of the file + * variables The array recording the variables of the eight cells belonging to this Octree node. + */ +int artio_particle_write_particle(artio_file handle, int64_t pid, int subspecies, + double* primary_variables, float *secondary_variables); + +/* + * Description: Read the variables of the root level cell and the hierarchy of the Octtree + * correlated with this root level cell + * + * handle The File handle + * variables The variables of the root level cell + * level The depth of the OCT tree + * num_octs_per_level The number of node of each oct level + * + */ +int artio_particle_read_root_cell_begin(artio_file handle, int64_t sfc, + int * num_particle_per_species); + +/* + * Description: Do something at the end of reading the root level cell + */ +int artio_particle_read_root_cell_end(artio_file handle); + +/* + * Description: Do something at the beginning of each level + */ +int artio_particle_read_species_begin(artio_file handle, int species ); + +/* + * Description: Do something at the end of each level + */ +int artio_particle_read_species_end(artio_file handle); + +/* + * Description: Read the data of a single particle from the file + */ +int artio_particle_read_particle(artio_file handle, int64_t *pid, int *subspecies, + double *primary_variables, float *secondary_variables); + +int artio_particle_cache_sfc_range(artio_file handle, int64_t sfc_start, int64_t sfc_end); + +/* + * Description: Read a segment of particles + * + * handle file pointer + * sfc1 the start sfc index + * sfc2 the end sfc index + * start_species the first particle species to read + * end_species the last particle species to read + * callback callback function + */ +int artio_particle_read_sfc_range(artio_file handle, + int64_t sfc1, int64_t sfc2, + int start_species, int end_species, + ParticleCallBack callback); + +#endif /* __ARTIO_H__ */ diff -Nru ifrit-3.3.4/special/artio/artio_endian.c ifrit-3.4.2/special/artio/artio_endian.c --- ifrit-3.3.4/special/artio/artio_endian.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_endian.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,81 @@ +#include "artio_endian.h" + +#include + +void artio_int_swap(int32_t *src, int count) { + int i; + union { + int32_t f; + unsigned char c[4]; + } d1, d2; + + for ( i = 0; i < count; i++ ) { + d1.f = src[i]; + d2.c[0] = d1.c[3]; + d2.c[1] = d1.c[2]; + d2.c[2] = d1.c[1]; + d2.c[3] = d1.c[0]; + src[i] = d2.f; + } +} + +void artio_float_swap(float *src, int count) { + int i; + union { + float f; + unsigned char c[4]; + } d1, d2; + + for ( i = 0; i < count; i++ ) { + d1.f = src[i]; + d2.c[0] = d1.c[3]; + d2.c[1] = d1.c[2]; + d2.c[2] = d1.c[1]; + d2.c[3] = d1.c[0]; + src[i] = d2.f; + } +} + +void artio_double_swap(double *src, int count) { + int i; + union + { + double d; + unsigned char c[8]; + } d1, d2; + + for ( i = 0; i < count; i++ ) { + d1.d = src[i]; + d2.c[0] = d1.c[7]; + d2.c[1] = d1.c[6]; + d2.c[2] = d1.c[5]; + d2.c[3] = d1.c[4]; + d2.c[4] = d1.c[3]; + d2.c[5] = d1.c[2]; + d2.c[6] = d1.c[1]; + d2.c[7] = d1.c[0]; + src[i] = d2.d; + } +} + +void artio_long_swap(int64_t *src, int count) { + int i; + union + { + int64_t d; + unsigned char c[8]; + } d1, d2; + + for ( i = 0; i < count; i++ ) { + d1.d = src[i]; + d2.c[0] = d1.c[7]; + d2.c[1] = d1.c[6]; + d2.c[2] = d1.c[5]; + d2.c[3] = d1.c[4]; + d2.c[4] = d1.c[3]; + d2.c[5] = d1.c[2]; + d2.c[6] = d1.c[1]; + d2.c[7] = d1.c[0]; + src[i] = d2.d; + } +} diff -Nru ifrit-3.3.4/special/artio/artio_endian.h ifrit-3.4.2/special/artio/artio_endian.h --- ifrit-3.3.4/special/artio/artio_endian.h 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_endian.h 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,11 @@ +#ifndef __ARTIO_EDIAN_H__ +#define __ARTIO_EDIAN_H__ + +#include + +void artio_int_swap(int32_t *src, int count); +void artio_float_swap(float *src, int count); +void artio_double_swap(double *src, int count); +void artio_long_swap(int64_t *src, int count); + +#endif /* __ARTIO_ENDIAN_H__ */ diff -Nru ifrit-3.3.4/special/artio/artio_grid.c ifrit-3.4.2/special/artio/artio_grid.c --- ifrit-3.3.4/special/artio/artio_grid.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_grid.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,688 @@ +/* + * artio_grid.c + * + * Created on: May 10, 2011 + * Author: Yongen Yu + */ +#include +#include +#include +#include + +#ifdef ARTIO_MPI +#include "artio_mpi.h" +#endif /* ARTIO_MPI */ + +#include "artio.h" +#include "artio_internal.h" + +int artio_grid_find_file(artio_file handle, int start, int end, int64_t sfc); + +/* + * Open grid component of the fileset + */ +int artio_grid_open(artio_file handle) { + int i; + char filename[256]; + int first_file, last_file; + int mode; + artio_grid_file ghandle; + + /* check that the fileset contains a grid component */ + if ( !(handle->open_type & ARTIO_OPEN_GRID) || + handle->open_mode != ARTIO_FILESET_READ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + ghandle = (artio_grid_file)malloc(sizeof(struct artio_grid_file_struct)); + handle->grid = ghandle; + + /* load grid parameters from header file (should be doing error handling...) */ + artio_parameter_get_int(handle, "num_grid_variables", &ghandle->num_grid_variables); + artio_parameter_get_int(handle, "num_grid_files", &ghandle->num_grid_files); + ghandle->file_sfc_index = (int64_t *)malloc(sizeof(int64_t) * (ghandle->num_grid_files + 1)); + artio_parameter_get_long_array(handle, "grid_file_sfc_index", + ghandle->num_grid_files + 1, ghandle->file_sfc_index); + artio_parameter_get_int(handle, "grid_max_level", + &ghandle->file_max_level); + + ghandle->octs_per_level = (int *)malloc(ghandle->file_max_level * sizeof(int)); + + /* allocate file handles */ + ghandle->ffh = (artio_fh *)malloc(ghandle->num_grid_files * sizeof(artio_fh)); + + first_file = artio_grid_find_file(handle, 0, + ghandle->num_grid_files, handle->proc_sfc_begin); + last_file = artio_grid_find_file(handle, first_file, + ghandle->num_grid_files, handle->proc_sfc_end); + + /* open files on all processes */ + for (i = 0; i < ghandle->num_grid_files; i++) { + sprintf(filename, "%s.g%03d", handle->file_prefix, i); + + mode = ARTIO_MODE_READ; + if (i >= first_file && i <= last_file) { + mode |= ARTIO_MODE_ACCESS; + } + + if(handle->param_list.endian_swap) { + mode |= ARTIO_MODE_ENDIAN_SWAP; + } + + ghandle->ffh[i] = artio_file_fopen(filename, mode, handle->context); + + if ( ghandle->ffh[i] == NULL ) { + return ARTIO_ERR_GRID_FILE_NOT_FOUND; + } + } + + ghandle->cache_sfc_begin = -1; + ghandle->cache_sfc_end = -1; + ghandle->sfc_offset_table = NULL; + + ghandle->cur_file = -1; + ghandle->cur_sfc = -1; + ghandle->cur_level = -1; + ghandle->cur_num_levels = -1; + ghandle->cur_octs = -1; + + handle->grid = ghandle; + return ARTIO_SUCCESS; +} + +int artio_fileset_add_grid(artio_file handle, + int num_grid_files, int allocation_strategy, + int num_grid_variables, + char ** grid_variable_labels, + int * num_levels_per_root_tree, + int * num_octs_per_root_tree ) { + + int i; + int *file_parent; + int64_t *file_sfc_index; + int file_max_level, local_max_level; + int64_t cur, sfc, l; + int64_t first_file_sfc, last_file_sfc; + int first_file, last_file; + char filename[256]; + int mode; + artio_grid_file ghandle; + + if ( handle->open_mode != ARTIO_FILESET_WRITE ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( handle->open_type & ARTIO_OPEN_GRID) { + return ARTIO_ERR_DATA_EXISTS; + } + handle->open_type |= ARTIO_OPEN_GRID; + + artio_parameter_set_int(handle, "num_grid_files", num_grid_files); + artio_parameter_set_int(handle, "num_grid_variables", num_grid_variables); + artio_parameter_set_string_array(handle, "grid_variable_labels", + num_grid_variables, grid_variable_labels); + + ghandle = (artio_grid_file)malloc(sizeof(struct artio_grid_file_struct)); + handle->grid = ghandle; + + file_parent = (int *)malloc(sizeof(int) * num_grid_files); + file_sfc_index = (int64_t *)malloc(sizeof(int64_t) * (num_grid_files + 1)); + + /* compute global maximum level */ + local_max_level = 0; + for (sfc = 0; sfc < handle->proc_sfc_end - handle->proc_sfc_begin + 1; sfc++) { + if (num_levels_per_root_tree[sfc] > local_max_level) { + local_max_level = num_levels_per_root_tree[sfc]; + } + } + +#ifdef ARTIO_MPI + MPI_Allreduce( &local_max_level, &file_max_level, 1, MPI_INT, MPI_MAX, handle->context->comm ); +#else + file_max_level = local_max_level; +#endif /* ARTIO_MPI */ + + switch (allocation_strategy) { + case ARTIO_ALLOC_EQUAL_PROC: + if (num_grid_files > handle->num_procs) { + return ARTIO_ERR_INVALID_FILE_NUMBER; + } + + for (i = 0; i < num_grid_files; i++) { + file_parent[i] = (handle->num_procs*i+num_grid_files-1) / num_grid_files; + file_sfc_index[i] = handle->proc_sfc_index[file_parent[i]]; + } + file_sfc_index[num_grid_files] = handle->proc_sfc_index[handle->num_procs]; + break; + case ARTIO_ALLOC_EQUAL_SFC: + file_sfc_index[0] = 0; + file_parent[0] = 0; + + for (i = 1; i < num_grid_files; i++) { + file_sfc_index[i] = (handle->num_root_cells*i+num_grid_files-1) / num_grid_files; + file_parent[i] = file_parent[i - 1]; + while (file_parent[i] < handle->num_procs && + handle->proc_sfc_index[file_parent[i]+ 1] <= file_sfc_index[i]) { + file_parent[i]++; + } + } + file_sfc_index[num_grid_files] = handle->num_root_cells; + break; + default: + return ARTIO_ERR_INVALID_ALLOC_STRATEGY; + } + + ghandle->num_grid_files = num_grid_files; + ghandle->file_sfc_index = file_sfc_index; + ghandle->num_grid_variables = num_grid_variables; + ghandle->file_max_level = file_max_level; + + /* allocate space for sfc offset cache */ + ghandle->cache_sfc_begin = handle->proc_sfc_begin; + ghandle->cache_sfc_end = handle->proc_sfc_end; + ghandle->sfc_offset_table = + (int64_t *)malloc((size_t)(ghandle->cache_sfc_end - ghandle->cache_sfc_begin + 1) * sizeof(int64_t)); + + ghandle->octs_per_level = (int *)malloc(ghandle->file_max_level * sizeof(int)); + + /* allocate file handles */ + ghandle->ffh = (artio_fh *)malloc(num_grid_files * sizeof(artio_fh)); + + /* open file handles */ + first_file = artio_grid_find_file(handle, 0, num_grid_files, + handle->proc_sfc_begin); + last_file = artio_grid_find_file(handle, first_file, num_grid_files, + handle->proc_sfc_end); + + for (i = 0; i < num_grid_files; i++) { + sprintf(filename, "%s.g%03d", handle->file_prefix, i); + + mode = ARTIO_MODE_WRITE; + if (i >= first_file && i <= last_file) { + mode |= ARTIO_MODE_ACCESS; + } + + ghandle->ffh[i] = artio_file_fopen(filename, mode, handle->context); + + /* write sfc offset header if we contribute to this file */ + if (i >= first_file && i <= last_file) { +#ifdef ARTIO_MPI + if (file_parent[i] == handle->rank) { + cur = (file_sfc_index[i + 1] - file_sfc_index[i]) * sizeof(int64_t); + } else { + /* obtain offset from previous process */ + MPI_Recv( &cur, 1, MPI_LONG_LONG_INT, handle->rank - 1, i, + handle->context->comm, MPI_STATUS_IGNORE ); + } +#else + cur = (file_sfc_index[i + 1] - file_sfc_index[i]) * sizeof(int64_t); +#endif /* ARTIO_MPI */ + + first_file_sfc = MAX( handle->proc_sfc_begin, file_sfc_index[i] ); + last_file_sfc = MIN( handle->proc_sfc_end, file_sfc_index[i+1]-1 ); + + for (l = first_file_sfc - ghandle->cache_sfc_begin; + l < last_file_sfc - ghandle->cache_sfc_begin + 1; l++) { + ghandle->sfc_offset_table[l] = cur; + cur += sizeof(float) * ghandle->num_grid_variables + sizeof(int) * (1 + + num_levels_per_root_tree[l]) + + num_octs_per_root_tree[l] * 8 * (sizeof(float) + * ghandle->num_grid_variables + sizeof(int)); + } + +#ifdef ARTIO_MPI + if ( file_sfc_index[i+1] > handle->proc_sfc_end+1 ) { + MPI_Send( &cur, 1, MPI_LONG_LONG_INT, handle->rank + 1, i, handle->context->comm ); + } +#endif /* ARTIO_MPI */ + + /* seek and write our portion of sfc table */ + artio_file_fseek(ghandle->ffh[i], + (first_file_sfc - file_sfc_index[i]) * sizeof(int64_t), ARTIO_SEEK_SET); + artio_file_fwrite(ghandle->ffh[i], + &ghandle->sfc_offset_table[first_file_sfc - ghandle->cache_sfc_begin], + last_file_sfc - first_file_sfc + 1, ARTIO_TYPE_LONG); + } + } + + free(file_parent); + + ghandle->cur_file = -1; + ghandle->cur_sfc = -1; + ghandle->cur_level = -1; + ghandle->cur_num_levels = -1; + ghandle->cur_octs = -1; + + handle->grid = ghandle; + + artio_parameter_set_long_array(handle, "grid_file_sfc_index", + ghandle->num_grid_files + 1, ghandle->file_sfc_index); + artio_parameter_set_int(handle, "grid_max_level", ghandle->file_max_level); + + return ARTIO_SUCCESS; +} + +int artio_grid_close(artio_file handle) { + int i; + artio_grid_file ghandle = handle->grid; + for (i = 0; i < ghandle->num_grid_files; i++) { + artio_file_fclose(ghandle->ffh[i]); + } + free(ghandle->ffh); + + if ( ghandle->sfc_offset_table != NULL ) { + free(ghandle->sfc_offset_table); + } + + free(ghandle->octs_per_level); + free(ghandle->file_sfc_index); + return ARTIO_SUCCESS; +} + +int artio_grid_cache_sfc_range(artio_file handle, int64_t start, int64_t end) { + int i; + int first_file, last_file; + int64_t first, count, cur; + artio_grid_file ghandle = handle->grid; + + if ( start > end || start < handle->proc_sfc_begin || + end > handle->proc_sfc_end ) { + return ARTIO_ERR_INVALID_SFC_RANGE; + } + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->sfc_offset_table != NULL) { + free(ghandle->sfc_offset_table); + } + + first_file = artio_grid_find_file(handle, 0, ghandle->num_grid_files, start); + last_file = artio_grid_find_file(handle, first_file, ghandle->num_grid_files, end); + + ghandle->cache_sfc_begin = start; + ghandle->cache_sfc_end = end; + ghandle->sfc_offset_table = (int64_t *)malloc(sizeof(int64_t) * (size_t)(end - start + 1)); + + cur = 0; + for (i = first_file; i <= last_file; i++) { + first = MAX( 0, start - ghandle->file_sfc_index[i] ); + count = MIN( ghandle->file_sfc_index[i+1], end+1 ) + - MAX( start, ghandle->file_sfc_index[i]); + artio_file_fseek(ghandle->ffh[i], + sizeof(int64_t) * first, + ARTIO_SEEK_SET); + artio_file_fread(ghandle->ffh[i], + &ghandle->sfc_offset_table[cur], + count, ARTIO_TYPE_LONG); + cur += count; + } + + return ARTIO_SUCCESS; +} + +int artio_grid_find_file(artio_file handle, int start, int end, int64_t sfc) { + int j; + artio_grid_file ghandle = handle->grid; + + if ( start < 0 || start > ghandle->num_grid_files || + end < 0 || end > ghandle->num_grid_files || + sfc < ghandle->file_sfc_index[start] || + sfc >= ghandle->file_sfc_index[end] ) { + return -1; + } + + if (start == end || sfc == ghandle->file_sfc_index[start]) { + return start; + } + + if (1 == end - start) { + if (sfc < ghandle->file_sfc_index[end]) { + return start; + } else { + return end; + } + } + + j = start + (end - start) / 2; + if (sfc > ghandle->file_sfc_index[j]) { + return artio_grid_find_file(handle, j, end, sfc); + } else if (sfc < ghandle->file_sfc_index[j]) { + return artio_grid_find_file(handle, start, j, sfc); + } else { + return j; + } +} + +int artio_grid_seek_to_sfc(artio_file handle, int64_t sfc) { + int re; + int64_t offset; + artio_grid_file ghandle = handle->grid; + + if (ghandle->cache_sfc_begin == -1 || + sfc < ghandle->cache_sfc_begin || + sfc > ghandle->cache_sfc_end) { + return ARTIO_ERR_INVALID_SFC; + } + + ghandle->cur_file = artio_grid_find_file(handle, 0, ghandle->num_grid_files, sfc); + offset = ghandle->sfc_offset_table[sfc - ghandle->cache_sfc_begin]; + re = artio_file_fseek(ghandle->ffh[ghandle->cur_file], offset, ARTIO_SEEK_SET); + + if ( re != ARTIO_SUCCESS ) { + fprintf(stderr,"unable to seek to %ld in file %d for sfc %ld\n", + offset, ghandle->cur_file, sfc ); fflush(stderr); + exit(1); + } + + return ARTIO_SUCCESS; +} + +int artio_grid_write_root_cell_begin(artio_file handle, int64_t sfc, + float *variables, int num_oct_levels, int *num_octs_per_level) { + int i; + + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (num_oct_levels < 0 || num_oct_levels > ghandle->file_max_level) { + return ARTIO_ERR_INVALID_OCT_LEVELS; + } + + artio_grid_seek_to_sfc(handle, sfc); + artio_file_fwrite(ghandle->ffh[ghandle->cur_file], variables, ghandle->num_grid_variables, + ARTIO_TYPE_FLOAT); + artio_file_fwrite(ghandle->ffh[ghandle->cur_file], &num_oct_levels, 1, ARTIO_TYPE_INT); + artio_file_fwrite(ghandle->ffh[ghandle->cur_file], num_octs_per_level, num_oct_levels, + ARTIO_TYPE_INT); + + for (i = 0; i < num_oct_levels; i++) { + ghandle->octs_per_level[i] = num_octs_per_level[i]; + } + + ghandle->cur_sfc = sfc; + ghandle->cur_num_levels = num_oct_levels; + ghandle->cur_level = -1; + ghandle->cur_octs = 0; + + return ARTIO_SUCCESS; +} + +int artio_grid_write_root_cell_end(artio_file handle) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + ghandle->cur_sfc = -1; + return ARTIO_SUCCESS; +} + +int artio_grid_write_level_begin(artio_file handle, int level) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->cur_sfc == -1 || + level <= 0 || level > ghandle->cur_num_levels) { + return ARTIO_ERR_INVALID_STATE; + } + + ghandle->cur_level = level; + return ARTIO_SUCCESS; +} + +int artio_grid_write_level_end(artio_file handle) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->cur_level == -1 || + ghandle->cur_octs != ghandle->octs_per_level[ghandle->cur_level - 1] ) { + return ARTIO_ERR_INVALID_STATE; + } + + ghandle->cur_level = -1; + ghandle->cur_octs = 0; + + return ARTIO_SUCCESS; +} + +int artio_grid_write_oct(artio_file handle, float *variables, + int *cellrefined) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->cur_level == -1 || + ghandle->cur_octs >= ghandle->octs_per_level[ghandle->cur_level - 1]) { + return ARTIO_ERR_INVALID_STATE; + } + + artio_file_fwrite(ghandle->ffh[ghandle->cur_file], + variables, 8 * ghandle->num_grid_variables, + ARTIO_TYPE_FLOAT); + artio_file_fwrite(ghandle->ffh[ghandle->cur_file], + cellrefined, 8, ARTIO_TYPE_INT); + ghandle->cur_octs++; + return ARTIO_SUCCESS; +} + +/* + * + */ +int artio_grid_read_root_cell_begin(artio_file handle, int64_t sfc, + float *variables, int *num_oct_levels, int *num_octs_per_level) { + int i; + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + artio_grid_seek_to_sfc(handle, sfc); + artio_file_fread(ghandle->ffh[ghandle->cur_file], + variables, ghandle->num_grid_variables, + ARTIO_TYPE_FLOAT); + artio_file_fread(ghandle->ffh[ghandle->cur_file], + num_oct_levels, 1, ARTIO_TYPE_INT); + if ( *num_oct_levels > ghandle->file_max_level ) { + fprintf(stderr,"%d: error reading root num_oct_levels\n", handle->rank ); + exit(1); + } + + if (*num_oct_levels > 0) { + artio_file_fread(ghandle->ffh[ghandle->cur_file], + num_octs_per_level, *num_oct_levels, + ARTIO_TYPE_INT); + for (i = 0; i < *num_oct_levels; i++) { + ghandle->octs_per_level[i] = num_octs_per_level[i]; + } + } + + ghandle->cur_sfc = sfc; + ghandle->cur_num_levels = *num_oct_levels; + ghandle->cur_level = -1; + + return ARTIO_SUCCESS; +} + +/* Description */ +int artio_grid_read_oct(artio_file handle, float *variables, + int *refined) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->cur_level == -1 || + ghandle->cur_octs > ghandle->octs_per_level[ghandle->cur_level - 1]) { + return ARTIO_ERR_INVALID_STATE; + } + + artio_file_fread(ghandle->ffh[ghandle->cur_file], + variables, 8 * ghandle->num_grid_variables, + ARTIO_TYPE_FLOAT); + artio_file_fread(ghandle->ffh[ghandle->cur_file], + refined, 8, ARTIO_TYPE_INT); + ghandle->cur_octs++; + + return ARTIO_SUCCESS; +} + +/* + * Description Obtain data from an appointed level tree node + */ +int artio_grid_read_level_begin(artio_file handle, int level) { + int i; + int64_t offset = 0; + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( ghandle->cur_sfc == -1 || level <= 0 || level > ghandle->cur_num_levels ) { + return ARTIO_ERR_INVALID_STATE; + } + + offset = ghandle->sfc_offset_table[ghandle->cur_sfc - ghandle->cache_sfc_begin]; + offset += sizeof(float) * ghandle->num_grid_variables + sizeof(int) + * (ghandle->cur_num_levels + 1); + for (i = 0; i < level - 1; i++) { + offset += 8 * (sizeof(float) * ghandle->num_grid_variables + sizeof(int)) + * ghandle->octs_per_level[i]; + } + + artio_file_fseek(ghandle->ffh[ghandle->cur_file], offset, ARTIO_SEEK_SET); + ghandle->cur_level = level; + ghandle->cur_octs = 0; + + return ARTIO_SUCCESS; +} + +/* + * Description Do something at the end of each kind of read operation + */ +int artio_grid_read_level_end(artio_file handle) { + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (ghandle->cur_level == -1) { + return ARTIO_ERR_INVALID_STATE; + } + + ghandle->cur_level = -1; + ghandle->cur_octs = -1; + + return ARTIO_SUCCESS; +} + +int artio_grid_read_root_cell_end(artio_file handle) { + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + handle->grid->cur_sfc = -1; + return ARTIO_SUCCESS; +} + +int artio_grid_read_sfc_range(artio_file handle, + int64_t sfc1, int64_t sfc2, + int min_level_to_read, int max_level_to_read, + int options, + GridCallBack callback) { + int64_t sfc; + int oct, level, j; + int *octs_per_level; + int refined; + int oct_refined[8]; + int root_tree_levels; + float * variable_of_root; + float * variable_of_oct = 0; + + artio_grid_file ghandle = handle->grid; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_GRID) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ((min_level_to_read < 0) | (min_level_to_read > max_level_to_read)) { + return ARTIO_ERR_INVALID_LEVEL; + } + + octs_per_level = (int *)malloc(ghandle->file_max_level * sizeof(int)); + variable_of_root = (float *)malloc(ghandle->num_grid_variables * sizeof(float)); + + if (max_level_to_read > 0) { + variable_of_oct = (float *)malloc(8 * ghandle->num_grid_variables * sizeof(float)); + } + + artio_grid_cache_sfc_range(handle, sfc1, sfc2); + + for (sfc = sfc1; sfc <= sfc2; sfc++) { + artio_grid_read_root_cell_begin(handle, sfc, variable_of_root, + &root_tree_levels, octs_per_level); + + if (min_level_to_read == 0 && (options == ARTIO_READ_ALL || + options == ARTIO_READ_REFINED && root_tree_levels > 0 || + options == ARTIO_READ_LEAFS && root_tree_levels == 0)) { + refined = (root_tree_levels > 0) ? 1 : 0; + callback(variable_of_root, 0, refined, sfc); + } + + for (level = MAX(min_level_to_read,1); + level <= MIN(root_tree_levels,max_level_to_read); level++) { + artio_grid_read_level_begin(handle, level); + for (oct = 0; oct < octs_per_level[level - 1]; oct++) { + artio_grid_read_oct(handle, variable_of_oct, oct_refined); + + for (j = 0; j < 8; j++) { + if (options == ARTIO_READ_ALL || + options == ARTIO_READ_REFINED && oct_refined[j] || + options == ARTIO_READ_LEAFS && !oct_refined[j] ) { + callback(&variable_of_oct[j * ghandle->num_grid_variables], + level, oct_refined[j], sfc); + } + } + } + artio_grid_read_level_end(handle); + } + artio_grid_read_root_cell_end(handle); + } + + if (max_level_to_read > 0) { + free(variable_of_oct); + } + + free(variable_of_root); + free(octs_per_level); + + return ARTIO_SUCCESS; +} diff -Nru ifrit-3.3.4/special/artio/artio_internal.h ifrit-3.4.2/special/artio/artio_internal.h --- ifrit-3.3.4/special/artio/artio_internal.h 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_internal.h 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,152 @@ +/* + * artio_internal.h + * + * Created on: Apr 9, 2010 + * Author: Yongen Yu + * Renamed/Modified: Nov 18, 2010 - Douglas Rudd + */ + +#ifndef __ARTIO_INTERNAL_H__ +#define __ARTIO_INTERNAL_H__ + +#include +#include + +#include "artio.h" +#include "artio_endian.h" + +#ifndef MIN +#define MIN(x,y) (((x) < (y)) ? (x): (y)) +#endif +#ifndef MAX +#define MAX(x,y) (((x) > (y)) ? (x): (y)) +#endif + +typedef struct ARTIO_FH *artio_fh; + +typedef struct artio_particle_file_struct +{ + artio_fh *ffh; + int num_particle_files; + int64_t *file_sfc_index; + int64_t cache_sfc_begin; + int64_t cache_sfc_end; + int64_t *sfc_offset_table; + + /* maintained for consistency and user-error detection */ + int num_species; + int cur_file; + int cur_species; + int cur_particle; + int64_t cur_sfc; + int *num_primary_variables; + int *num_secondary_variables; + int *num_particles_per_species; +} *artio_particle_file; + +typedef struct artio_grid_file_struct +{ + artio_fh *ffh; + int num_grid_variables; + int num_grid_files; + int64_t *file_sfc_index; + int64_t cache_sfc_begin; + int64_t cache_sfc_end; + int64_t *sfc_offset_table; + + int file_max_level; + /* maintained for consistency and user-error detection */ + int cur_file; + int cur_num_levels; + int cur_level; + int cur_octs; + int64_t cur_sfc; + int *octs_per_level; +} *artio_grid_file; + +typedef struct param_struct +{ + int key_length; + char key[64]; + int val_length; + int type; + char *value; + struct param_struct * next; +} param; + +typedef struct list_struct +{ + param * head; + param * tail; + param * cursor; + int iterate_flag; + int endian_swap; +} list; + +struct artio_file_struct +{ + char file_prefix[256]; + int endian_swap; + int open_type; + int open_mode; + int rank; + int num_procs; + artio_context context; + + int64_t *proc_sfc_index; + int64_t proc_sfc_begin; + int64_t proc_sfc_end; + int64_t num_root_cells; + + list param_list; + artio_grid_file grid; + artio_particle_file particle; +}; + + +#define ARTIO_MODE_READ 1 +#define ARTIO_MODE_WRITE 2 +#define ARTIO_MODE_DIRECT 4 +#define ARTIO_MODE_ACCESS 8 +#define ARTIO_MODE_ENDIAN_SWAP 16 + +#define ARTIO_SEEK_SET 0 +#define ARTIO_SEEK_CUR 1 + +artio_fh artio_file_fopen( char * filename, int amode, artio_context context ); +int artio_file_fwrite(artio_fh handle, void *buf, int64_t count, int type ); +int artio_file_fflush(artio_fh handle); +int artio_file_fseek(artio_fh ffh, int64_t offset, int whence); +int artio_file_fread(artio_fh handle, void *buf, int64_t count, int type ); +int artio_file_fclose(artio_fh handle); +void artio_set_endian_swap_tag(artio_fh handle); + + +#define ARTIO_ENDIAN_MAGIC 0x1234 + +void artio_parameter_list_init( list *param_list ); + +param * artio_parameter_list_search(list * param_list, char * key); + +int param_array_length( param *item ); + +int artio_parameter_list_insert(list * param_list, char * key, int length, + void * value, int type); + +int artio_parameter_read(artio_fh handle, list * param_list); + +int artio_parameter_write(artio_fh handle, list * param_list); + +int artio_parameter_list_print(list * param_list); +int artio_parameter_free_list(list * param_list); +int artio_parameter_list_print(list * param_list); + +size_t artio_type_size( int type ); +int artio_parameter_list_unpack(list *param_list, char *key, int length, void *value, int type ); + +int artio_grid_open(artio_file handle); +int artio_grid_close(artio_file handle); +int artio_particle_open(artio_file handle); +int artio_particle_close(artio_file handle); + +#endif /* __ARTIO_INTERNAL_H__ */ diff -Nru ifrit-3.3.4/special/artio/artio_mpi.c ifrit-3.4.2/special/artio/artio_mpi.c --- ifrit-3.3.4/special/artio/artio_mpi.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_mpi.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,296 @@ +/* + * artio_mpi.c + * + * Created on: Apr 9, 2010 + * Author: Yongen Yu + * Modified: Nov 18, 2010 - Douglas Rudd + */ + +#include "artio.h" +#include "artio_internal.h" + +#include +#include +#include +#include + +#ifdef ARTIO_MPI + +#include "artio_mpi.h" + +#define MPI_FH_BUFFERSIZE 16384 + +struct ARTIO_FH { + MPI_File fh; + MPI_Comm comm; + char *data; + int mode; + int bfptr; + int bfsize; + int bfend; +}; + +artio_fh artio_file_fopen( char * filename, int mode, artio_context context) { + int status; + int flag; + int rank; + int amode; + + if ( mode & ARTIO_MODE_WRITE && + mode & ARTIO_MODE_READ ) { + return NULL; + } else if ( mode & ARTIO_MODE_WRITE ) { + amode = MPI_MODE_CREATE | MPI_MODE_WRONLY; + } else if ( mode & ARTIO_MODE_READ ) { + amode = MPI_MODE_RDONLY; + } else { + return NULL; + } + + artio_fh ffh = (artio_fh)malloc(sizeof(struct ARTIO_FH)); + + ffh->mode = mode; + flag = mode & ARTIO_MODE_ACCESS; + + MPI_Comm_rank( context->comm, &rank ); + MPI_Comm_split( context->comm, flag, rank, &ffh->comm ); + + if ( flag ) { + status = MPI_File_open( ffh->comm, filename, amode, MPI_INFO_NULL, &ffh->fh); + if (status != MPI_SUCCESS) { + return NULL; + } + + /* truncate the file on write */ + if ( mode & ARTIO_MODE_WRITE ) { + MPI_File_set_size(ffh->fh, 0); + } + + if ( mode & ARTIO_MODE_DIRECT) { + ffh->bfsize = 0; + ffh->bfend = 0; + ffh->bfptr = 0; + } else { + ffh->data = (char *)malloc(MPI_FH_BUFFERSIZE); + memset(ffh->data, 0, MPI_FH_BUFFERSIZE); + ffh->bfptr = 0; + ffh->bfsize = MPI_FH_BUFFERSIZE; + ffh->bfend = -1; + } + } + + return ffh; +} + +int artio_file_fwrite(artio_fh handle, void *buf, int64_t count, int type ) { + int size, part, remain; + int64_t size64; + + if ( !(handle->mode & ARTIO_MODE_WRITE) || + !(handle->mode & ARTIO_MODE_ACCESS) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + size = count*artio_type_size( type ); + size64 = count*artio_type_size( type ); + if((int64_t)size != size64) + { + return ARTIO_ERR_64_TO_32_BIT_TRUNCATION; + } + + if ( handle->mode & ARTIO_MODE_DIRECT ) { + MPI_File_write( handle->fh, buf, size, + MPI_BYTE, MPI_STATUS_IGNORE ); + } else { + if ( handle->bfptr + size < handle->bfsize) { + memcpy( handle->data + handle->bfptr, buf, size ); + handle->bfptr += size; + } else { + part = handle->bfsize - handle->bfptr; + remain = handle->bfptr + size - handle->bfsize; + + memcpy( handle->data + handle->bfptr, buf, part); + MPI_File_write(handle->fh, handle->data, handle->bfsize, + MPI_BYTE, MPI_STATUS_IGNORE ); + + while ( remain > handle->bfsize ) { + memcpy( handle->data, (char *)buf + part, handle->bfsize); + MPI_File_write(handle->fh, handle->data, handle->bfsize, + MPI_BYTE, MPI_STATUS_IGNORE ); + remain -= handle->bfsize; + part += handle->bfsize; + } + + memcpy( handle->data, (char *)buf + part, remain); + handle->bfptr = remain; + } + } + + return ARTIO_SUCCESS; +} + +int artio_file_fflush(artio_fh handle) { + if ( !(handle->mode & ARTIO_MODE_ACCESS) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + if ( handle->mode & ARTIO_MODE_WRITE ) { + if ( handle->bfptr > 0 ) { + MPI_File_write(handle->fh, handle->data, handle->bfptr, + MPI_BYTE, MPI_STATUS_IGNORE ); + handle->bfptr = 0; + } + } else if ( handle->mode & ARTIO_MODE_READ ) { + handle->bfptr = 0; + handle->bfend = -1; + } else { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + return ARTIO_SUCCESS; +} + +int artio_file_fread(artio_fh handle, void *buf, int64_t count, int type ) { + MPI_Status status; + + int size, avail, remain, size_read; + int64_t size64; + char *curbuf; + + if ( !(handle->mode & ARTIO_MODE_READ) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + size = count*artio_type_size( type ); + size64 = count*artio_type_size( type ); + if((int64_t)size != size64) + { + return ARTIO_ERR_64_TO_32_BIT_TRUNCATION; + } + + if ( handle->mode & ARTIO_MODE_DIRECT ) { + MPI_File_read(handle->fh, buf, size, MPI_BYTE, &status ); + MPI_Get_count( &status, MPI_BYTE, &size_read ); + if ( size_read != size ) { + return ARTIO_ERR_INSUFFICIENT_DATA; + } + } else { + if ( handle->bfend == -1 ) { + /* load initial data into buffer */ + MPI_File_read(handle->fh, handle->data, handle->bfsize, MPI_BYTE, &status); + MPI_Get_count(&status, MPI_BYTE, &handle->bfend); + handle->bfptr = 0; + } + + /* read from buffer */ + curbuf = (char *)buf; + remain = size; + while ( remain > 0 && + handle->bfend > 0 && + handle->bfptr + remain >= handle->bfend ) { + avail = handle->bfend - handle->bfptr; + memcpy( curbuf, (char *)handle->data + handle->bfptr, avail ); + curbuf += avail; + remain -= avail; + + /* refill buffer */ + MPI_File_read(handle->fh, handle->data, handle->bfsize, + MPI_BYTE, &status ); + MPI_Get_count(&status, MPI_BYTE, &handle->bfend ); + handle->bfptr = 0; + } + + if ( handle->bfend == 0 ) { + /* ran out of data, eof */ + return ARTIO_ERR_INSUFFICIENT_DATA; + } + + memcpy( curbuf, (char *)handle->data + handle->bfptr, remain ); + handle->bfptr += remain; + } + + if(handle->mode & ARTIO_MODE_ENDIAN_SWAP){ + switch (type) { + case ARTIO_TYPE_INT : + artio_int_swap( (int32_t *)buf, count ); + break; + case ARTIO_TYPE_FLOAT : + artio_float_swap( (float *)buf, count ); + break; + case ARTIO_TYPE_DOUBLE : + artio_double_swap( (double *)buf, count ); + break; + case ARTIO_TYPE_LONG : + artio_long_swap( (int64_t *)buf, count ); + break; + default : + return ARTIO_ERR_INVALID_DATATYPE; + } + } + + return ARTIO_SUCCESS; +} + +int artio_file_fseek(artio_fh handle, int64_t offset, int whence ) { + MPI_Offset current; + + if ( handle->mode & ARTIO_MODE_ACCESS ) { + if ( whence == ARTIO_SEEK_CUR ) { + if ( offset == 0 ) { + return ARTIO_SUCCESS; + } else if ( handle->mode & ARTIO_MODE_READ && + handle->bfptr + offset >= 0 && + handle->bfptr + offset < handle->bfsize ) { + handle->bfptr += offset; + return ARTIO_SUCCESS; + } else { + artio_file_fflush( handle ); + current = (MPI_Offset)offset; + MPI_File_seek( handle->fh, current, MPI_SEEK_CUR ); + } + } else if ( whence == ARTIO_SEEK_SET ) { + MPI_File_get_position( handle->fh, ¤t ); + if (handle->mode & ARTIO_MODE_WRITE && + current<=offset && offset<(current + handle->bfsize) && + handle->bfptr==(offset - current)) { + return ARTIO_SUCCESS; + } else if ( handle->mode & ARTIO_MODE_READ && + handle->bfend > 0 && + offset >= (current - handle->bfend) && + offset < current ) { + handle->bfptr = offset - current + handle->bfend; + } else { + artio_file_fflush( handle ); + current = (MPI_Offset)offset; + MPI_File_seek( handle->fh, current, MPI_SEEK_SET ); + } + } else { + /* unknown whence */ + return ARTIO_ERR_INVALID_SEEK; + } + } else { + /* seek on non-active file handle */ + return ARTIO_ERR_INVALID_FILE_MODE; + } + + return ARTIO_SUCCESS; +} + +int artio_file_fclose(artio_fh handle) { + if ( handle->mode & ARTIO_MODE_ACCESS ) { + artio_file_fflush(handle); + MPI_File_close(&handle->fh); + + if ( handle->bfsize > 0 ) { + free(handle->data); + } + } + MPI_Comm_free(&handle->comm); + return ARTIO_SUCCESS; +} + +void artio_set_endian_swap_tag(artio_fh handle) { + handle->mode |= ARTIO_MODE_ENDIAN_SWAP; +} + +#endif /* MPI */ diff -Nru ifrit-3.3.4/special/artio/artio_mpi.h ifrit-3.4.2/special/artio/artio_mpi.h --- ifrit-3.3.4/special/artio/artio_mpi.h 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_mpi.h 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,17 @@ +/* + * artio_mpi.h + * + * Created on: Mar 6, 2012 + * Author: Nick Gnedin + */ + +#ifndef __ARTIO_MPI_H__ +#define __ARTIO_MPI_H__ + +#include + +struct artio_context_struct { + MPI_Comm comm; +}; + +#endif /* __ARTIO_MPI_H__ */ diff -Nru ifrit-3.3.4/special/artio/artio_parameter.c ifrit-3.4.2/special/artio/artio_parameter.c --- ifrit-3.3.4/special/artio/artio_parameter.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_parameter.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,475 @@ +/* + * artio_parameter.c + * + * Created on: Jun 8, 2010 + * Author: Yongen Yu + */ + +#include +#include +#include +#include + +#include "artio.h" +#include "artio_internal.h" + +size_t artio_type_size(int type) { + size_t t_len=0; + + switch (type) { + case ARTIO_TYPE_STRING: + case ARTIO_TYPE_CHAR: + t_len = 1; + break; + case ARTIO_TYPE_INT: + t_len = sizeof(int32_t); + break; + case ARTIO_TYPE_FLOAT: + t_len = sizeof(float); + break; + case ARTIO_TYPE_DOUBLE: + t_len = sizeof(double); + break; + case ARTIO_TYPE_LONG: + t_len = sizeof(int64_t); + break; + default: + t_len = (size_t)-1; + break; + } + + return t_len; +} + +void artio_parameter_list_init(list *param_list) { + param_list->head = NULL; + param_list->tail = NULL; + param_list->cursor = NULL; + param_list->iterate_flag = 0; +} + +int artio_parameter_read(artio_fh handle, list * param_list) { + param * param_item; + int i; + int length, re; + int t_len; + int32_t endian_tag; + + /* endian check */ + re = artio_file_fread(handle, &endian_tag, 1, ARTIO_TYPE_INT); + if ( re != ARTIO_SUCCESS ) { + return ARTIO_ERR_PARAM_CORRUPTED; + } + + if ( endian_tag != ARTIO_ENDIAN_MAGIC ) { + artio_int_swap( &endian_tag, 1 ); + if ( endian_tag == ARTIO_ENDIAN_MAGIC ) { + param_list->endian_swap = 1; + artio_set_endian_swap_tag(handle); + } else { + return ARTIO_ERR_PARAM_CORRUPTED_MAGIC; + } + } else { + param_list->endian_swap = 0; + } + re = artio_file_fread(handle, &length, 1, ARTIO_TYPE_INT); + if ( re != ARTIO_SUCCESS ) { + return ARTIO_ERR_PARAM_CORRUPTED; + } + + for ( i = 0; i < length; i++ ) { + param_item = (param *)malloc(sizeof(param)); + artio_file_fread(handle, ¶m_item->key_length, 1, ARTIO_TYPE_INT); + artio_file_fread(handle, param_item->key, param_item->key_length, ARTIO_TYPE_CHAR); + param_item->key[param_item->key_length] = 0; + + artio_file_fread(handle, ¶m_item->val_length, 1, ARTIO_TYPE_INT); + artio_file_fread(handle, ¶m_item->type, 1, ARTIO_TYPE_INT); + + t_len = artio_type_size(param_item->type); + param_item->value = (char *)malloc(param_item->val_length * t_len); + + re = artio_file_fread(handle, param_item->value, + param_item->val_length, param_item->type); + if ( re != ARTIO_SUCCESS ) { + return ARTIO_ERR_PARAM_CORRUPTED; + } + + param_item->next = NULL; + if (NULL == param_list->tail) { + param_list->tail = param_item; + param_list->head = param_item; + } else { + param_list->tail->next = param_item; + param_list->tail = param_item; + } + } + + return ARTIO_SUCCESS; +} + +int artio_parameter_write(artio_fh handle, list * param_list) { + param * item; + + /* retain a number for endian check */ + int32_t endian_tag = ARTIO_ENDIAN_MAGIC; + int32_t length = 0; + + item = param_list->head; + while (NULL != item) { + length++; + item = item->next; + } + + artio_file_fwrite(handle, &endian_tag, + 1, ARTIO_TYPE_INT); + artio_file_fwrite(handle, &length, + 1, ARTIO_TYPE_INT); + + item = param_list->head; + while (NULL != item) { + artio_file_fwrite(handle, &item->key_length, + 1, ARTIO_TYPE_INT); + artio_file_fwrite(handle, item->key, + item->key_length, ARTIO_TYPE_CHAR); + artio_file_fwrite(handle, &item->val_length, + 1, ARTIO_TYPE_INT); + artio_file_fwrite(handle, &item->type, + 1, ARTIO_TYPE_INT); + artio_file_fwrite(handle, item->value, + item->val_length, item->type); + item = item->next; + } + + return ARTIO_SUCCESS; +} + +int artio_parameter_iterate( artio_file handle, char *key, int *type, int *length ) { + param *item; + list *param_list = &handle->param_list; + + if ( param_list->iterate_flag == 0 ) { + param_list->cursor = param_list->head; + param_list->iterate_flag = 1; + } + + if ( param_list->cursor == NULL ) { + param_list->iterate_flag = 0; + return ARTIO_PARAMETER_EXHAUSTED; + } + + item = param_list->cursor; + strncpy( key, item->key, 64 ); + *type = item->type; + *length = param_array_length(item); + + param_list->cursor = item->next; + return ARTIO_SUCCESS; +} + +param *artio_parameter_list_search(list * param_list, char *key ) { + param * item = param_list->head; + while ( NULL != item && strcmp(item->key, key) ) { + item = item->next; + } + return item; +} + +int artio_parameter_list_insert(list * param_list, char * key, + int length, void *value, int type) { + int key_len, val_len = 0; + param * item; + + if ( length <= 0 ) { + return ARTIO_ERR_PARAM_LENGTH_INVALID; + } + + item = artio_parameter_list_search(param_list, key); + if (NULL != item) { + return ARTIO_ERR_PARAM_DUPLICATE; + } + + /* create the list node */ + item = (param *)malloc(sizeof(param)); + key_len = strlen(key); + item->key_length = key_len; + strcpy(item->key, key); + item->val_length = length; + item->type = type; + val_len = artio_type_size(type); + item->value = (char *)malloc(length * val_len); + + memcpy(item->value, value, length * val_len); + + item->next = NULL; + /* add to the list */ + if (NULL == param_list->tail) { + param_list->tail = item; + param_list->head = item; + } else { + param_list->tail->next = item; + param_list->tail = item; + } + + return ARTIO_SUCCESS; +} + +int artio_parameter_list_unpack(list *param_list, char *key, int length, + void *value, int type) { + size_t t_len; + + param *item = artio_parameter_list_search(param_list, key); + + if (item != NULL) { + if (length != item->val_length ) { + return ARTIO_ERR_PARAM_LENGTH_MISMATCH; + } else if ( type != item->type ) { + return ARTIO_ERR_PARAM_TYPE_MISMATCH; + } else { + t_len = artio_type_size(type); + memcpy(value, item->value, item->val_length * t_len); + } + } else { + return ARTIO_ERR_PARAM_NOT_FOUND; + } + + return ARTIO_SUCCESS; +} + +int param_array_length( param *item ) { + int i, length; + + if ( item->type == ARTIO_TYPE_STRING ) { + length = 0; + for ( i = 0; i < item->val_length; i++ ) { + if ( item->value[i] == '\0' ) { + length++; + } + } + } else { + length = item->val_length; + } + + return length; +} + +int artio_parameter_get_array_length(artio_file handle, char * key, int *length) { + param * item = artio_parameter_list_search(&handle->param_list, key); + + if (item != NULL) { + *length = param_array_length(item); + } else { + return ARTIO_ERR_PARAM_NOT_FOUND; + } + + return ARTIO_SUCCESS; +} + +int artio_parameter_free_list(list * param_list) { + param * tmp; + param * param_item = param_list->head; + + if ( param_list == NULL ) { + return ARTIO_ERR_INVALID_PARAM_LIST; + } + + while (NULL != param_item) { + tmp = param_item; + param_item = param_item->next; + free(tmp->value); + free(tmp); + } + + param_list->head = NULL; + param_list->tail = NULL; + + return ARTIO_SUCCESS; +} + +int artio_parameter_list_print(list * param_list) { + int32_t a; + float b; + double c; + int64_t d; + + param * item = param_list->head; + while (NULL != item) { + switch ( item->type ) { + case ARTIO_TYPE_STRING: + printf("string: key %s %s\n", item->key, item->value); + break; + case ARTIO_TYPE_CHAR: + printf("char: key %s %c\n", item->key, *item->value); + break; + case ARTIO_TYPE_INT: + memcpy(&a, item->value, sizeof(int32_t)); + printf("int: key %s %d\n", item->key, a); + break; + case ARTIO_TYPE_FLOAT: + memcpy(&b, item->value, sizeof(float)); + printf("float: key %s %f\n", item->key, b); + break; + case ARTIO_TYPE_DOUBLE: + memcpy(&c, item->value, sizeof(double)); + printf("double: key %s %f\n", item->key, c); + break; + case ARTIO_TYPE_LONG: + memcpy(&d, item->value, sizeof(int64_t)); + printf("long: %ld\n", d); + break; + default: + printf("unrecognized type %d\n", item->type); + } + item = item->next; + } + + return ARTIO_SUCCESS; +} + +void artio_parameter_set_int(artio_file handle, char * key, int32_t value) { + int32_t tmp = value; + artio_parameter_set_int_array(handle, key, 1, &tmp); +} + +int artio_parameter_get_int(artio_file handle, char * key, int32_t * value) { + return artio_parameter_get_int_array(handle, key, 1, value); +} + +void artio_parameter_set_int_array(artio_file handle, char * key, int length, + int32_t * value) { + artio_parameter_list_insert(&handle->param_list, key, length, value, + ARTIO_TYPE_INT); +} + +int artio_parameter_get_int_array(artio_file handle, char * key, int length, + int32_t * value) { + return artio_parameter_list_unpack(&handle->param_list, key, length, + value, ARTIO_TYPE_INT); +} + +void artio_parameter_set_float(artio_file handle, char * key, float value) { + float tmp = value; + artio_parameter_set_float_array(handle, key, 1, &tmp); +} + +int artio_parameter_get_float(artio_file handle, char * key, float * value) { + return artio_parameter_get_float_array(handle, key, 1, value); +} + +void artio_parameter_set_float_array(artio_file handle, char * key, + int length, float * value) { + artio_parameter_list_insert(&handle->param_list, key, length, value, + ARTIO_TYPE_FLOAT); +} + +int artio_parameter_get_float_array(artio_file handle, char * key, + int length, float * value) { + return artio_parameter_list_unpack(&handle->param_list, key, length, + value, ARTIO_TYPE_FLOAT); +} + +void artio_parameter_set_double(artio_file handle, char * key, double value) { + double tmp = value; + artio_parameter_set_double_array(handle, key, 1, &tmp); +} + +int artio_parameter_get_double(artio_file handle, char * key, double * value) { + return artio_parameter_get_double_array(handle, key, 1, value); +} + +void artio_parameter_set_double_array(artio_file handle, char * key, + int length, double * value) { + artio_parameter_list_insert(&handle->param_list, key, length, value, + ARTIO_TYPE_DOUBLE); +} + +int artio_parameter_get_double_array(artio_file handle, char * key, + int length, double * value) { + return artio_parameter_list_unpack(&handle->param_list, key, length, + value, ARTIO_TYPE_DOUBLE); +} + +void artio_parameter_set_long(artio_file handle, char * key, int64_t value) { + int64_t tmp = value; + artio_parameter_set_long_array(handle, key, 1, &tmp); +} + +int artio_parameter_get_long(artio_file handle, char * key, int64_t * value) { + return artio_parameter_get_long_array(handle, key, 1, value); +} + +void artio_parameter_set_long_array(artio_file handle, char * key, + int length, int64_t * value) { + artio_parameter_list_insert(&handle->param_list, key, length, value, + ARTIO_TYPE_LONG); +} + +int artio_parameter_get_long_array(artio_file handle, char * key, + int length, int64_t * value) { + return artio_parameter_list_unpack(&handle->param_list, key, length, + value, ARTIO_TYPE_LONG); +} + +void artio_parameter_set_string(artio_file handle, char *key, char *value) { + artio_parameter_set_string_array(handle, key, 1, &value); +} + +void artio_parameter_set_string_array(artio_file handle, char *key, + int length, char **value) { + int i; + int loc_length; + char *loc_value; + char *p; + + for (i = 0, loc_length = 0; i < length; i++) { + loc_length += strlen(value[i]) + 1; + } + + loc_value = (char *)malloc(loc_length * sizeof(char)); + + for (i = 0, p = loc_value; i < length; i++) { + strcpy(p, value[i]); + p += strlen(value[i]) + 1; + } + + artio_parameter_list_insert(&handle->param_list, key, + loc_length, loc_value, ARTIO_TYPE_STRING); + free(loc_value); +} + +int artio_parameter_get_string(artio_file handle, char *key, char *value, int max_length) { + return artio_parameter_get_string_array(handle, key, 1, &value, max_length); +} + +int artio_parameter_get_string_array(artio_file handle, char *key, + int length, char **value, int max_length) { + int i; + char *p; + int count; + + param *item = artio_parameter_list_search(&handle->param_list, key); + + if (item != NULL) { + /* count string items in item->value */ + count = 0; + p = item->value; + while (p < item->value + item->val_length) { + p += strlen(p) + 1; + count++; + } + + if (count != length) { + return ARTIO_ERR_PARAM_LENGTH_MISMATCH; + } + + for (i = 0, p = item->value; i < length; i++) { + strncpy(value[i], p, max_length-1); + value[i][max_length-1] = 0; + p += strlen(p) + 1; + } + } else { + return ARTIO_ERR_PARAM_NOT_FOUND; + } + + return ARTIO_SUCCESS; +} diff -Nru ifrit-3.3.4/special/artio/artio_particle.c ifrit-3.4.2/special/artio/artio_particle.c --- ifrit-3.3.4/special/artio/artio_particle.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_particle.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,751 @@ +/* + * artio_particle.c + * + * Created on: May 10, 2011 + * Author: eric + */ +#include +#include +#include +#include + +#ifdef ARTIO_MPI +#include "artio_mpi.h" +#endif /* ARTIO_MPI */ + +#include "artio.h" +#include "artio_internal.h" + +int artio_particle_find_file(artio_file handle, int start, int end, int64_t sfc); + +/* + * Open existing particle files and add to fileset + */ +int artio_particle_open(artio_file handle) { + int i; + char filename[256]; + int first_file, last_file; + int mode; + artio_particle_file phandle; + + if ( !(handle->open_type & ARTIO_OPEN_PARTICLES) || + handle->open_mode != ARTIO_FILESET_READ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + phandle = (artio_particle_file)malloc(sizeof(struct artio_particle_file_struct)); + handle->particle = phandle; + + artio_parameter_get_int(handle, "num_particle_species", &phandle->num_species); + + phandle->num_primary_variables = (int *)malloc(sizeof(int) * phandle->num_species); + phandle->num_secondary_variables = (int *)malloc(sizeof(int) * phandle->num_species); + phandle->num_particles_per_species + = (int *)malloc(phandle->num_species * sizeof(int)); + + artio_parameter_get_int_array(handle, "num_primary_variables", + phandle->num_species, phandle->num_primary_variables); + artio_parameter_get_int_array(handle, "num_secondary_variables", + phandle->num_species, phandle->num_secondary_variables); + + artio_parameter_get_int(handle, "num_particle_files", &phandle->num_particle_files); + + phandle->file_sfc_index = (int64_t *)malloc(sizeof(int64_t) * (phandle->num_particle_files + 1)); + artio_parameter_get_long_array(handle, "particle_file_sfc_index", + phandle->num_particle_files + 1, phandle->file_sfc_index); + + first_file = artio_particle_find_file(handle, 0, + phandle->num_particle_files, handle->proc_sfc_begin); + last_file = artio_particle_find_file(handle, first_file, + phandle->num_particle_files, handle->proc_sfc_end); + + /* allocate file handles */ + phandle->ffh = (artio_fh *)malloc(phandle->num_particle_files * sizeof(artio_fh)); + + /* open files on all processes */ + for (i = 0; i < phandle->num_particle_files; i++) { + sprintf(filename, "%s.p%03d", handle->file_prefix, i); + + mode = ARTIO_MODE_READ; + if (i >= first_file && i <= last_file) { + mode |= ARTIO_MODE_ACCESS; + } + if (handle->param_list.endian_swap) { + mode |= ARTIO_MODE_ENDIAN_SWAP; + } + phandle->ffh[i] = artio_file_fopen(filename, mode, handle->context); + + if ( phandle->ffh[i] == NULL ) { + return ARTIO_ERR_PARTICLE_FILE_NOT_FOUND; + } + } + + phandle->cache_sfc_begin = -1; + phandle->cache_sfc_end = -1; + phandle->sfc_offset_table = NULL; + + phandle->cur_file = -1; + phandle->cur_sfc = -1; + phandle->cur_species = -1; + phandle->cur_particle = -1; + + return ARTIO_SUCCESS; +} + +int artio_fileset_add_particles( artio_file handle, + int num_particle_files, int allocation_strategy, + int num_species, char ** species_labels, + int * num_primary_variables, + int * num_secondary_variables, + char *** primary_variable_labels_per_species, + char *** secondary_variable_labels_per_species, + int * num_particles_per_species_per_root_tree ) { + + int i, k; + + int *file_parent; + int64_t *file_sfc_index; + int64_t l, cur; + int64_t first_file_sfc, last_file_sfc; + + int first_file, last_file; + char filename[256]; + char species_label[64]; + int mode; + int64_t *local_particles_per_species, *total_particles_per_species; + artio_particle_file phandle; + + if ( handle->open_mode != ARTIO_FILESET_WRITE ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( handle->open_type & ARTIO_OPEN_PARTICLES ) { + return ARTIO_ERR_DATA_EXISTS; + } + handle->open_type |= ARTIO_OPEN_PARTICLES; + + /* compute total number of particles per species */ + local_particles_per_species = (int64_t *)malloc( num_species * sizeof(int64_t)); + total_particles_per_species = (int64_t *)malloc( num_species * sizeof(int64_t)); + + for ( i = 0; i < num_species; i++ ) { + local_particles_per_species[i] = 0; + } + + for ( l = 0; l < handle->proc_sfc_end-handle->proc_sfc_begin+1; l++ ) { + for ( i = 0; i < num_species; i++ ) { + local_particles_per_species[i] += num_particles_per_species_per_root_tree[num_species*l+i]; + } + } + +#ifdef ARTIO_MPI + MPI_Allreduce( local_particles_per_species, total_particles_per_species, num_species, + MPI_LONG_LONG_INT, MPI_SUM, handle->context->comm ); +#else + for ( i = 0; i < num_species; i++ ) { + total_particles_per_species[i] = local_particles_per_species[i]; + } +#endif + + artio_parameter_set_long_array(handle, + "num_particles_per_species", num_species, + total_particles_per_species ); + + free( local_particles_per_species ); + free( total_particles_per_species ); + + artio_parameter_set_int(handle, "num_particle_files", num_particle_files); + artio_parameter_set_int(handle, "num_particle_species", num_species); + artio_parameter_set_string_array(handle, "particle_species_labels", + num_species, species_labels); + artio_parameter_set_int_array(handle, "num_primary_variables", num_species, + num_primary_variables); + artio_parameter_set_int_array(handle, "num_secondary_variables", + num_species, num_secondary_variables); + + for(i=0;iparticle = phandle; + + file_parent = (int *)malloc(sizeof(int) * num_particle_files); + file_sfc_index = (int64_t *)malloc(sizeof(int64_t) * (num_particle_files + 1)); + if ( file_parent == NULL || file_sfc_index == NULL ) { + fprintf(stderr, "ERROR allocating memory!"); + exit(1); + } + + switch (allocation_strategy) { + case ARTIO_ALLOC_EQUAL_PROC: + if (num_particle_files > handle->num_procs) { + return ARTIO_ERR_INVALID_FILE_NUMBER; + } + + for (i = 0; i < num_particle_files; i++) { + file_parent[i] = (handle->num_procs*i+num_particle_files-1) / num_particle_files; + file_sfc_index[i] = handle->proc_sfc_index[file_parent[i]]; + } + file_sfc_index[num_particle_files] = handle->proc_sfc_index[handle->num_procs]; + break; + case ARTIO_ALLOC_EQUAL_SFC: + file_sfc_index[0] = 0; + file_parent[0] = 0; + + for (i = 1; i < num_particle_files; i++) { + file_sfc_index[i] = (handle->num_root_cells*i+num_particle_files-1) / num_particle_files; + file_parent[i] = file_parent[i - 1]; + while (file_parent[i] < handle->num_procs && + handle->proc_sfc_index[file_parent[i] + 1] <= file_sfc_index[i]) { + file_parent[i]++; + } + } + file_sfc_index[num_particle_files] = handle->num_root_cells; + break; + default: + return ARTIO_ERR_INVALID_ALLOC_STRATEGY; + } + + phandle->num_particle_files = num_particle_files; + phandle->num_species = num_species; + phandle->file_sfc_index = file_sfc_index; + phandle->num_primary_variables = (int *)malloc(sizeof(int) * num_species); + phandle->num_secondary_variables = (int *)malloc(sizeof(int) * num_species); + phandle->num_particles_per_species = + (int *)malloc(phandle->num_species * sizeof(int)); + + for (i = 0; i < num_species; i++) { + phandle->num_primary_variables[i] = num_primary_variables[i]; + phandle->num_secondary_variables[i] = num_secondary_variables[i]; + } + + /* allocate space for sfc offset cache */ + phandle->cache_sfc_begin = handle->proc_sfc_begin; + phandle->cache_sfc_end = handle->proc_sfc_end; + phandle->sfc_offset_table = + (int64_t *)malloc( (size_t)(handle->proc_sfc_end - handle->proc_sfc_begin + 1) * sizeof(int64_t)); + + /* allocate file handles */ + phandle->ffh = (artio_fh *)malloc(num_particle_files * sizeof(artio_fh)); + + /* open file handles */ + first_file = artio_particle_find_file(handle, 0, + num_particle_files, handle->proc_sfc_begin); + last_file = artio_particle_find_file(handle, first_file, + num_particle_files, handle->proc_sfc_end); + + for (i = 0; i < num_particle_files; i++) { + sprintf(filename, "%s.p%03d", handle->file_prefix, i); + mode = ARTIO_MODE_WRITE; + if (i >= first_file && i <= last_file) { + mode |= ARTIO_MODE_ACCESS; + } + + phandle->ffh[i] = artio_file_fopen(filename, mode, handle->context); + + if ( phandle->ffh[i] == NULL ) { + return ARTIO_ERR_FILE_CREATE; + } + + /* write sfc offset header if we contribute to this file */ + if (i >= first_file && i <= last_file) { +#ifdef ARTIO_MPI + if (file_parent[i] == handle->rank) { + cur = (file_sfc_index[i+1] - file_sfc_index[i]) * sizeof(int64_t); + } else { + /* obtain offset from previous process */ + MPI_Recv( &cur, 1, MPI_LONG_LONG_INT, handle->rank - 1, i, + handle->context->comm, MPI_STATUS_IGNORE ); + } +#else + cur = (file_sfc_index[i+1] - file_sfc_index[i]) * sizeof(int64_t); +#endif /* ARTIO_MPI */ + + first_file_sfc = MAX( phandle->cache_sfc_begin, file_sfc_index[i] ); + last_file_sfc = MIN( phandle->cache_sfc_end, file_sfc_index[i+1]-1 ); + + for (l = first_file_sfc - phandle->cache_sfc_begin; + l < last_file_sfc - phandle->cache_sfc_begin + 1; l++) { + + phandle->sfc_offset_table[l] = cur; + cur += sizeof(int) * num_species; + + for (k = 0; k < num_species; k++) { + cur += num_particles_per_species_per_root_tree[l*num_species+k] + * (sizeof(int64_t) + sizeof(int) + + num_primary_variables[k] * sizeof(double) + + num_secondary_variables[k] * sizeof(float)); + } + } + +#ifdef ARTIO_MPI + if ( file_sfc_index[i+1] > handle->proc_sfc_end+1 ) { + MPI_Send( &cur, 1, MPI_LONG_LONG_INT, handle->rank+1, i, handle->context->comm ); + } +#endif /* ARTIO_MPI */ + + /* seek and write our portion of sfc table */ + artio_file_fseek(phandle->ffh[i], + (first_file_sfc - file_sfc_index[i]) * sizeof(int64_t), ARTIO_SEEK_SET); + artio_file_fwrite(phandle->ffh[i], + &phandle->sfc_offset_table[first_file_sfc - phandle->cache_sfc_begin], + last_file_sfc - first_file_sfc + 1, ARTIO_TYPE_LONG); + } + } + + free(file_parent); + + phandle->cur_file = -1; + phandle->cur_sfc = -1; + phandle->cur_species = -1; + phandle->cur_particle = -1; + + artio_parameter_set_long_array(handle, "particle_file_sfc_index", + handle->particle->num_particle_files + 1, + handle->particle->file_sfc_index); + + return ARTIO_SUCCESS; +} + +int artio_particle_close(artio_file handle) { + int i; + artio_particle_file phandle = handle->particle; + for (i = 0; i < phandle->num_particle_files; i++) { + artio_file_fclose(phandle->ffh[i]); + } + free(phandle->ffh); + + if (phandle->sfc_offset_table != NULL) { + free(phandle->sfc_offset_table); + } + + free(phandle->num_particles_per_species); + free(phandle->num_primary_variables); + free(phandle->num_secondary_variables); + free(phandle->file_sfc_index); + return ARTIO_SUCCESS; +} + +int artio_particle_cache_sfc_range(artio_file handle, + int64_t start, int64_t end) { + int i; + int first_file, last_file; + int64_t min, count, cur; + artio_particle_file phandle = handle->particle; + + if ( start > end || start < handle->proc_sfc_begin || + end > handle->proc_sfc_end) { + return ARTIO_ERR_INVALID_SFC_RANGE; + } + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( phandle->sfc_offset_table != NULL ) { + free(phandle->sfc_offset_table); + } + + first_file = artio_particle_find_file(handle, 0, + phandle->num_particle_files, start); + last_file = artio_particle_find_file(handle, first_file, + phandle->num_particle_files, end); + + phandle->cache_sfc_begin = start; + phandle->cache_sfc_end = end; + phandle->sfc_offset_table = (int64_t *)malloc(sizeof(int64_t) * (size_t)(end - start + 1)); + + cur = 0; + for (i = first_file; i <= last_file; i++) { + min = MAX( 0, start - phandle->file_sfc_index[i] ); + count = MIN( phandle->file_sfc_index[i+1], end+1 ) + - MAX( start, phandle->file_sfc_index[i] ); + + artio_file_fseek(phandle->ffh[i], + sizeof(int64_t) * min, + ARTIO_SEEK_SET); + artio_file_fread(phandle->ffh[i], + &phandle->sfc_offset_table[cur], + count, ARTIO_TYPE_LONG); + cur += count; + } + + return ARTIO_SUCCESS; +} + +int artio_particle_find_file(artio_file handle, + int start, int end, int64_t sfc) { + int j; + artio_particle_file phandle = handle->particle; + + if ( start < 0 || start > phandle->num_particle_files || + end < 0 || end > phandle->num_particle_files || + sfc < phandle->file_sfc_index[start] || + sfc >= phandle->file_sfc_index[end] ) { + return -1; + } + + if (start == end || + sfc == phandle->file_sfc_index[start] ) { + return start; + } + + if (1 == end - start) { + if (sfc < phandle->file_sfc_index[end]) { + return start; + } else { + return end; + } + } + + j = start + (end - start) / 2; + if (sfc > phandle->file_sfc_index[j]) { + return artio_particle_find_file(handle, j, end, sfc); + } else if (sfc < phandle->file_sfc_index[j]) { + return artio_particle_find_file(handle, start, j, sfc); + } else { + return j; + } +} + +int artio_particle_seek_to_sfc(artio_file handle, int64_t sfc) { + int64_t offset; + artio_particle_file phandle = handle->particle; + + if (phandle->cache_sfc_begin == -1 || + sfc < phandle->cache_sfc_begin || + sfc > phandle->cache_sfc_end) { + return ARTIO_ERR_INVALID_SFC; + } + + phandle->cur_file = artio_particle_find_file(handle, 0, phandle->num_particle_files, sfc); + offset = phandle->sfc_offset_table[sfc - phandle->cache_sfc_begin]; + artio_file_fseek(phandle->ffh[phandle->cur_file], offset, ARTIO_SEEK_SET); + + return ARTIO_SUCCESS; +} + +int artio_particle_write_root_cell_begin(artio_file handle, int64_t sfc, + int * num_particles_per_species) { + int i; + artio_particle_file phandle=handle->particle; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( phandle->cur_sfc != -1 ) { + return ARTIO_ERR_INVALID_STATE; + } + + artio_particle_seek_to_sfc(handle, sfc); + artio_file_fwrite(phandle->ffh[phandle->cur_file], num_particles_per_species, + phandle->num_species, ARTIO_TYPE_INT); + for (i = 0; i < phandle->num_species; i++) { + phandle->num_particles_per_species[i] = num_particles_per_species[i]; + } + + phandle->cur_sfc = sfc; + phandle->cur_species = -1; + phandle->cur_particle = -1; + + return ARTIO_SUCCESS; +} + +int artio_particle_write_root_cell_end(artio_file handle) { + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( handle->particle->cur_sfc == -1 || + handle->particle->cur_species != -1 ) { + return ARTIO_ERR_INVALID_STATE; + } +; + handle->particle->cur_sfc = -1; + return ARTIO_SUCCESS; +} + +int artio_particle_write_species_begin(artio_file handle, + int species) { + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_sfc == -1 || phandle->cur_species != -1 ) { + return ARTIO_ERR_INVALID_STATE; + } + + if ( species < 0 || species >= phandle->num_species) { + return ARTIO_ERR_INVALID_SPECIES; + } + + phandle->cur_species = species; + phandle->cur_particle = 0; + + return ARTIO_SUCCESS; +} + +int artio_particle_write_species_end(artio_file handle) { + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_species == -1 || + phandle->cur_particle != + phandle->num_particles_per_species[phandle->cur_species]) { + return ARTIO_ERR_INVALID_STATE; + } + + phandle->cur_species = -1; + phandle->cur_particle = -1; + + return ARTIO_SUCCESS; +} + +int artio_particle_write_particle(artio_file handle, int64_t pid, int subspecies, + double * primary_variables, float *secondary_variables) { + + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_WRITE || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_species == -1 || + phandle->cur_particle >= phandle->num_particles_per_species[phandle->cur_species]) { + return ARTIO_ERR_INVALID_STATE; + } + + artio_file_fwrite(phandle->ffh[phandle->cur_file], &pid, 1, ARTIO_TYPE_LONG); + artio_file_fwrite(phandle->ffh[phandle->cur_file], &subspecies, 1, ARTIO_TYPE_INT); + + artio_file_fwrite(phandle->ffh[phandle->cur_file], primary_variables, + phandle->num_primary_variables[phandle->cur_species], + ARTIO_TYPE_DOUBLE); + + artio_file_fwrite(phandle->ffh[phandle->cur_file], secondary_variables, + phandle->num_secondary_variables[phandle->cur_species], + ARTIO_TYPE_FLOAT); + + phandle->cur_particle++; + return ARTIO_SUCCESS; +} + +/* + * + */ +int artio_particle_read_root_cell_begin(artio_file handle, int64_t sfc, + int * num_particles_per_species) { + int i; + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + artio_particle_seek_to_sfc(handle, sfc); + artio_file_fread(phandle->ffh[phandle->cur_file], num_particles_per_species, + phandle->num_species, ARTIO_TYPE_INT); + + for (i = 0; i < phandle->num_species; i++) { + phandle->num_particles_per_species[i] = num_particles_per_species[i]; + } + + phandle->cur_sfc = sfc; + phandle->cur_species = -1; + phandle->cur_particle = 0; + return ARTIO_SUCCESS; +} + +/* Description */ +int artio_particle_read_particle(artio_file handle, int64_t * pid, int *subspecies, + double * primary_variables, float * secondary_variables) { + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_species == -1 || + phandle->cur_particle >= phandle->num_particles_per_species[phandle->cur_species]) { + return ARTIO_ERR_INVALID_STATE; + } + + artio_file_fread(phandle->ffh[phandle->cur_file], pid, 1, ARTIO_TYPE_LONG); + artio_file_fread(phandle->ffh[phandle->cur_file], subspecies, 1, ARTIO_TYPE_INT); + artio_file_fread(phandle->ffh[phandle->cur_file], primary_variables, + phandle->num_primary_variables[phandle->cur_species], + ARTIO_TYPE_DOUBLE); + artio_file_fread(phandle->ffh[phandle->cur_file], secondary_variables, + phandle->num_secondary_variables[phandle->cur_species], + ARTIO_TYPE_FLOAT); + + phandle->cur_particle++; + return ARTIO_SUCCESS; +} + +/* + * Description Start reading particle species + */ +int artio_particle_read_species_begin(artio_file handle, int species) { + int i; + int64_t offset = 0; + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_sfc == -1) { + return ARTIO_ERR_INVALID_STATE; + } + + if (species < 0 || species >= phandle->num_species) { + return ARTIO_ERR_INVALID_SPECIES; + } + + offset = phandle->sfc_offset_table[phandle->cur_sfc - phandle->cache_sfc_begin]; + offset += sizeof(int32_t) * (phandle->num_species); + + for (i = 0; i < species; i++) { + offset += ( sizeof(int64_t) + sizeof(int) + + phandle->num_primary_variables[i] * sizeof(double) + + phandle->num_secondary_variables[i] * sizeof(float) ) * + phandle->num_particles_per_species[i]; + } + + artio_file_fseek(phandle->ffh[phandle->cur_file], offset, ARTIO_SEEK_SET); + phandle->cur_species = species; + phandle->cur_particle = 0; + + return ARTIO_SUCCESS; +} + +/* + * Description Do something at the end of each kind of read operation + */ +int artio_particle_read_species_end(artio_file handle) { + artio_particle_file phandle = handle->particle; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if (phandle->cur_species == -1) { + return ARTIO_ERR_INVALID_STATE; + } + + phandle->cur_species = -1; + phandle->cur_particle = 0; + + return ARTIO_SUCCESS; +} + +int artio_particle_read_root_cell_end(artio_file handle) { + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( handle->particle->cur_sfc == -1 ) { + return ARTIO_ERR_INVALID_STATE; + } + + handle->particle->cur_sfc = -1; + return ARTIO_SUCCESS; +} + +int artio_particle_read_sfc_range(artio_file handle, + int64_t sfc1, int64_t sfc2, + int start_species, int end_species, + ParticleCallBack callback) { + + int64_t sfc; + int particle, species; + int *num_particles_per_species; + artio_particle_file phandle = handle->particle; + int64_t pid = 0l; + int subspecies; + double * primary_variables = NULL; + float * secondary_variables = NULL; + int num_primary, num_secondary; + int ret; + + if (handle->open_mode != ARTIO_FILESET_READ || + !(handle->open_type & ARTIO_OPEN_PARTICLES) ) { + return ARTIO_ERR_INVALID_FILESET_MODE; + } + + if ( start_species < 0 || start_species > end_species || + end_species > phandle->num_species-1 ) { + return ARTIO_ERR_INVALID_SPECIES; + } + + num_particles_per_species = (int *)malloc(phandle->num_species * sizeof(int)); + artio_particle_cache_sfc_range(handle, sfc1, sfc2); + + num_primary = num_secondary = 0; + for ( species = start_species; species <= end_species; species++ ) { + num_primary = MAX( phandle->num_primary_variables[species], num_primary ); + num_secondary = MAX( phandle->num_secondary_variables[species], num_secondary ); + } + + primary_variables = (double *)malloc(num_primary * sizeof(double)); + secondary_variables = (float *)malloc(num_secondary * sizeof(float)); + + for ( sfc = sfc1; sfc <= sfc2; sfc++ ) { + artio_particle_read_root_cell_begin(handle, sfc, + num_particles_per_species); + + for ( species = start_species; species <= end_species; species++) { + artio_particle_read_species_begin(handle, species); + + for (particle = 0; particle < num_particles_per_species[species]; particle++) { + ret = artio_particle_read_particle(handle, + &pid, + &subspecies, + primary_variables, + secondary_variables); + + if ( ret != ARTIO_SUCCESS ) { + return ARTIO_ERR_PARTICLE_CORRUPTED; + } + + callback(pid, + primary_variables, + secondary_variables, + species, subspecies, sfc); + } + artio_particle_read_species_end(handle); + } + artio_particle_read_root_cell_end(handle); + } + + free(primary_variables); + free(secondary_variables); + free(num_particles_per_species); + + return ARTIO_SUCCESS; +} diff -Nru ifrit-3.3.4/special/artio/artio_posix.c ifrit-3.4.2/special/artio/artio_posix.c --- ifrit-3.3.4/special/artio/artio_posix.c 1970-01-01 00:00:00.000000000 +0000 +++ ifrit-3.4.2/special/artio/artio_posix.c 2013-07-11 01:23:15.000000000 +0000 @@ -0,0 +1,131 @@ +/* + * artio_posix.c + * + * Created on: Apr 9, 2010 + * Author: Yongen Yu + * Modified: Nov 18, 2010 - Douglas Rudd + */ + +#include "artio.h" +#include "artio_internal.h" + +#include +#include +#include + +#ifndef ARTIO_MPI + +struct ARTIO_FH { + FILE *fh; + int mode; +}; + + +#ifdef _WIN32 +#define FOPEN_FLAGS "b" +#define fseek _fseeki64 +#else +#define FOPEN_FLAGS "" +#endif + + +artio_fh artio_file_fopen( char * filename, int mode, artio_context not_used ) { + int flag; + + artio_fh ffh = (artio_fh)malloc(sizeof(struct ARTIO_FH)); + + ffh->mode = mode; + flag = mode & ARTIO_MODE_ACCESS; + + if ( flag ) { + ffh->fh = fopen( filename, ( mode & ARTIO_MODE_WRITE ) ? "w"FOPEN_FLAGS : "r"FOPEN_FLAGS ); + if ( ffh->fh == NULL ) { + free( ffh ); + return NULL; + } + } + + return ffh; +} + +int artio_file_fwrite(artio_fh handle, void *buf, int64_t count, int type ) { + int size; + + if ( !(handle->mode & ARTIO_MODE_WRITE) || + !(handle->mode & ARTIO_MODE_ACCESS) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + size = artio_type_size( type ); + fwrite( buf, (size_t)count, size, handle->fh ); + return ARTIO_SUCCESS; +} + +int artio_file_fflush(artio_fh handle) { + if ( !(handle->mode & ARTIO_MODE_ACCESS) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + fflush(handle->fh); + return ARTIO_SUCCESS; +} + +int artio_file_fread(artio_fh handle, void *buf, int64_t count, int type ) { + int size; + + if ( !(handle->mode & ARTIO_MODE_READ) ) { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + size = artio_type_size( type ); + if ( fread( buf, size, (size_t)count, handle->fh ) == count ) { + return ARTIO_SUCCESS; + } else { + return ARTIO_ERR_INSUFFICIENT_DATA; + } +} + +int artio_file_fseek(artio_fh handle, int64_t offset, int whence ) { + int64_t current; + + if ( handle->mode & ARTIO_MODE_ACCESS ) { + if ( whence == ARTIO_SEEK_CUR ) { + if ( offset == 0 ) { + return ARTIO_SUCCESS; + } else { + fseek( handle->fh, offset, SEEK_CUR ); + } + } else if ( whence == ARTIO_SEEK_SET ) { + current = ftell( handle->fh ); + + if ( handle->mode & ARTIO_MODE_WRITE && + current == offset ) { + return ARTIO_SUCCESS; + } else { + artio_file_fflush( handle ); + fseek( handle->fh, offset, SEEK_SET ); + } + } else { + /* unknown whence */ + return ARTIO_ERR_INVALID_SEEK; + } + } else { + return ARTIO_ERR_INVALID_FILE_MODE; + } + + return ARTIO_SUCCESS; +} + +int artio_file_fclose(artio_fh handle) { + if ( handle->mode & ARTIO_MODE_ACCESS ) { + artio_file_fflush(handle); + fclose(handle->fh); + } + return ARTIO_SUCCESS; +} + +void artio_set_endian_swap_tag(artio_fh handle) { + handle->mode |= ARTIO_MODE_ENDIAN_SWAP; +} + +#endif /* ifndef ARTIO_MPI */ diff -Nru ifrit-3.3.4/special/vp1000/iopenglvolumeprovp1000mapper.cpp ifrit-3.4.2/special/vp1000/iopenglvolumeprovp1000mapper.cpp --- ifrit-3.3.4/special/vp1000/iopenglvolumeprovp1000mapper.cpp 2011-01-27 17:52:39.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/iopenglvolumeprovp1000mapper.cpp 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++ @@ -36,7 +37,7 @@ void reportNullPointer(int); -//vtkCxxRevisionMacro(iOpenGLVolumeProVP1000Mapper, "$Revision: 1.1.1.1 $"); +//vtkCxxRevisionMacro(iOpenGLVolumeProVP1000Mapper, "$Revision$"); //vtkStandardNewMacro(iOpenGLVolumeProVP1000Mapper); iOpenGLVolumeProVP1000Mapper* iOpenGLVolumeProVP1000Mapper::New() diff -Nru ifrit-3.3.4/special/vp1000/iopenglvolumeprovp1000mapper.h ifrit-3.4.2/special/vp1000/iopenglvolumeprovp1000mapper.h --- ifrit-3.3.4/special/vp1000/iopenglvolumeprovp1000mapper.h 2011-01-27 17:52:38.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/iopenglvolumeprovp1000mapper.h 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++ diff -Nru ifrit-3.3.4/special/vp1000/ivolumepromapper.cpp ifrit-3.4.2/special/vp1000/ivolumepromapper.cpp --- ifrit-3.3.4/special/vp1000/ivolumepromapper.cpp 2011-01-27 17:52:39.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/ivolumepromapper.cpp 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++ @@ -31,7 +32,7 @@ #include -//vtkCxxRevisionMacro(iVolumeProMapper, "$Revision: 1.1.1.1 $"); +//vtkCxxRevisionMacro(iVolumeProMapper, "$Revision$"); //---------------------------------------------------------------------------- // Needed when we don't use the vtkStandardNewMacro. diff -Nru ifrit-3.3.4/special/vp1000/ivolumepromapper.h ifrit-3.4.2/special/vp1000/ivolumepromapper.h --- ifrit-3.3.4/special/vp1000/ivolumepromapper.h 2011-01-27 17:52:39.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/ivolumepromapper.h 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++ diff -Nru ifrit-3.3.4/special/vp1000/ivolumeprovp1000mapper.cpp ifrit-3.4.2/special/vp1000/ivolumeprovp1000mapper.cpp --- ifrit-3.3.4/special/vp1000/ivolumeprovp1000mapper.cpp 2011-01-27 17:52:39.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/ivolumeprovp1000mapper.cpp 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++ @@ -91,7 +92,7 @@ -//vtkCxxRevisionMacro(iVolumeProVP1000Mapper, "$Revision: 1.1.1.1 $"); +//vtkCxxRevisionMacro(iVolumeProVP1000Mapper, "$Revision$"); //---------------------------------------------------------------------------- // Needed when we don't use the vtkStandardNewMacro. diff -Nru ifrit-3.3.4/special/vp1000/ivolumeprovp1000mapper.h ifrit-3.4.2/special/vp1000/ivolumeprovp1000mapper.h --- ifrit-3.3.4/special/vp1000/ivolumeprovp1000mapper.h 2011-01-27 17:52:39.000000000 +0000 +++ ifrit-3.4.2/special/vp1000/ivolumeprovp1000mapper.h 2013-07-11 01:23:15.000000000 +0000 @@ -1,3 +1,4 @@ +/*========================================================================= Program: Visualization Toolkit Language: C++