Dear all,
I have a problem with creating a hardcopy/image of my model when I am running Trelis by a python script. Here is a simple example:
[code]import sys
sys.path.append(’/opt/Trelis-15.2/bin’)
try:
import cubit
except:
print ‘error importing cubit, check if cubit is installed’
pass
cubit.init([’’])
cubit.cmd(‘reset’)
cubit.cmd(‘brick x 10 y 10 z 10’)
cubit.cmd(‘mesh volume 1’)
screen shot
cubit.cmd(‘hardcopy ‘test.png’ png’)[/code]
This is the content of my python script “test.py” which I am running in the command line of my Linux terminal. In the terminal it says ‘Journaled Command: hardcopy “test.png” png’ – but no image is created.
Can anyone tell me why? Do I somehow have to activate graphics?
If yes, how could I run Trelis with a GUI in the command line?
Best regards,
Max