You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Write on a wiki page about how to call OpenFOAM/blueCFD-Core applications from an external application/GUI #94
The simplest is to simply launch the external application from within the blueCFD-Core (MSys2) terminal or from within the Windows Command Line (called from the file DOS_mode.bat), which will allow to already have the shell environment pre-loaded with the necessary paths.
The next possibility is to hard-code the environment variables that are provided in the file setvars.bat, which is provided as of blueCFD-Core 2016-2. This means that your external application will have to set the environment variables through whichever process launching mechanism you are using. For example, on Qt's QProcess there is a method for exactly that.
The other possibility is to generate a batch file inside the case folder, which you call from within your application, via cmd.exe. Said batch file would then need something like this:
cd "C:\Program Files\blueCFD-Core-2017"
call setvars.bat
set PATH=%HOME%\msys64\usr\bin;%PATH%
cd "FULL PATH TO YOUR CASE FOLDER"
YOUR COMMANDS HERE
Activity