Holzmann
Subscriber
I want to post my solution here as it has some nice benefits (at least for me).
I built a bash script that reads all *.cxa files at the current directory and built a corresponding journal file for each *.cxa file
Based on two input-parameters, it sets the view (camera)
Furthermore, it deactivates the "lightning" and "headlights"
The nice thing is, that one can use the "cat *.jou \> executeAllJournals.jou" command to combine each single journal file to one single guy which will create all the pictures for all *.cxa files.
The bash script is given as follows (you might adapt it to your needs)...

#!/bin/bash
#==============================================================================
#
# A bash script that creates a journal file for creating single frames of an
# animation to be used for a batch-mode-generation of the frames
#
# 16.07.2021
# Tobias Holzmann
#
# Usage:
#a) Copy this script into your folder in which the cxa files are located
#b) Simply provide the viewFile and the viewName for the animations
#Create these data in Fluent GUI
#c) Finally, define which *.cxa file should be used. If the cxaFile="*.cxa"
#each cxa File is analyzed and a corresponding journal file is written
#d) Execute the bash script in a terminal by typing
#./fluentAnimationJournalGeneration
#e) After the journal files are created, you start fluent in batch-mode
#fluent211 -gu -driver null -t11 3ddp
#
#-t11 tells fluent to start with 11 processors (parallel)
#3ddp := start fluent in 3d and double precision
#3d:= start fluent in 3d and single precision
#
#f) Load the journal file:
#> file/read-journal "myJournalFile.jou"
#
#Note: if the cxaFile="*.cxa" each animation has the same view port
#
#Note: If you have more journal files you can simply copy-paste the
#data of each file into one large file and execute only one journal
#file that does all the jop. Alternative one command:
#cat *.jou > myNewJournalFile.jou
#
#==============================================================================

viewFile="viewPosition.vw"
viewName="view-0"
cxaFiles="*.cxa"

#==============================================================================
clear

for i in `ls $cxaFiles`
do
echo "Analyzing the files $i"
echo \
"
;==============================================================================
; A script that does a batch-mode-rendering job
; 16.07.2021
; Tobias Holzmann
;==============================================================================

/display/views read-views \"$viewFile\"
" > ${i::-4}.jou


# Now read the cxa file, take the *hsf files and create the commands in the
# journal file to save each single frame
while IFS= read -r line
do
if [ "$(echo $line | grep -c "hsf")" -eq 1 ]
then
frameName=$(echo $line | xargs | cut -d' ' -f4)
echo \
"
/display/hsf-file \"$frameName\"
/display/set/lights headlight-on no
/display/set/lights lights-on no
/display/views restore-view $viewName
/display/set/picture/driver png
/display/save-picture \"${frameName::-4}\"" >> ${i::-4}.jou
fi

done < "$i"

echo "${i::-4}.jou created sucessfully..."
done

echo "-------------------------------------------------------"
echo "Open fluent in batch mode by providing the journal file"
echo "fluent211 -gu -driver null -t10"
echo "After that load 3d or 3ddp and read the journal file in the TUI"
echo ">file/read-journal \"yourFile.jou\""
echo "Note: t10 means -> parallel execution using 10 cores"