[Gate-users] Visual on a MAC
Martin Hjellström
martin.hjellstrom at gu.se
Tue Jun 18 11:23:02 CEST 2019
Hello Michael and you other guys!
I hope I'm not crashing your thread now Michael, but I think I have a similar problem. I'm totally new to GATE and currently struggling with the installation, the visualisation of geometries to be exact. I have installed Geant4 and it works perfect with visualisation of geometries and all, using Qt.
I then installed GATE, using the same Qt, but I can't get the visualisation of the geometry to work. Qt appears to work good and I can open the OGL and visualise the world box, but when I'm defining a geometry it doesn't appear, the world box remains empty. I tried to follow the first example in the GATE user guide when I'm trying to visualise a geometry, meaning that I run the commands in the below in this email. I tried to install Qt via Anaconda as you recommended in this thread, but it didn't work for me. Instead Geant4 nor GATE didn't work at all, displaying "Segmentation fault: 11". Do you guys have input in what can be wrong with my installation or with my set up? How can it be that the visualisation of the world box works, but not a geometry? Do I miss some command maybe? As I said before I'm totally new to GATE and don't know much about the coding or basically anything.
Thank you very much for your time and I'm very sorry Michael if this is irrelevant for your problem and I'm crashing your thread, that wasn't my intention.
Kind regards,
Martin
# V I S U A L I Z A T I O N
/vis/open OGL
/vis/viewer/reset
/vis/viewer/set/viewpointThetaPhi 60 60
/vis/viewer/zoom 1
/vis/viewer/set/style surface
/vis/drawVolume /tracking/storeTrajectory 1
/vis/scene/endOfEventAction accumulate
/vis/viewer/update
/gate/geometry/setMaterialDatabase GateMaterials.db
# W O R L D
/gate/world/geometry/setXLength 40. cm
/gate/world/geometry/setYLength 40. cm
/gate/world/geometry/setZLength 40. cm
# S Y S T E M
/gate/world/daughters/name cylindricalPET
/gate/world/daughters/insert cylinder
/gate/cylindricalPET/setMaterial Water
/gate/cylindricalPET/geometry/setRmax 100 mm
/gate/cylindricalPET/geometry/setRmin 86 mm
gate/cylindricalPET/geometry/setHeight 18 mm
/gate/cylindricalPET/vis/forceWireframe
/vis/viewer/zoom 3
This gives me an empty world box, zoomed in.
Martin Hjellström, PhD. Student
www.radfys.gu.se<http://www.radfys.gu.se/>
Department of Radiation Physics, Institute of Clinical Sciences
Sahlgrenska Academy at University of Gothenburg
Sahlgrenska University Hospital
________________________________
Från: Gate-users <gate-users-bounces at lists.opengatecollaboration.org> för Nils Krah <nils.krah at creatis.insa-lyon.fr>
Skickat: den 17 juni 2019 22:53:00
Till: gate-users at lists.opengatecollaboration.org
Ämne: Re: [Gate-users] Visual on a MAC
Hi Michael,
I had similar issues. What worked for me was installing QT using conda. (https://anaconda.org) So you would do something like
$ conda install qt
My ccmake configuration then is:
Qt5Core_DIR /Users/nkrah/anaconda2/lib/cmake/Qt5Core
Qt5Gui_DIR /Users/nkrah/anaconda2/lib/cmake/Qt5Gui
Qt5OpenGL_DIR /Users/nkrah/anaconda2/lib/cmake/Qt5OpenGL
Qt5PrintSupport_DIR /Users/nkrah/anaconda2/lib/cmake/Qt5PrintSupport
Qt5Widgets_DIR /Users/nkrah/anaconda2/lib/cmake/Qt5Widgets
The same for the Geant4 compilation. On the other hand, using QT installed with brew did not work for me because of some dynamic library issues which I was unable to figure out.
I also installed XQuartz (https://www.xquartz.org) to have X11 on the MacOS system. This appears to be used by Geant4:
OPENGL_X11_INCLUDE_DIR /usr/X11R6/include
Let me know. We can also try to fiddle around together. I cannot really recall all the details - it was a bit of trial and error. Maybe other Gate on MacOS users have a technically more sound explanation than mine.
Hope it helps,
Nils
On 17 Jun 2019 at 16:21 -0400, Michael Ljungberg <michael.ljungberg at med.lu.se>, wrote:
Hi
I wonder what selection I should do on the ccmake of geant4 and gate in order to be able to visualize the geometry? I know one can use QT but how should I install this? I have the latest MacOS.
Hälsningar / Best Regards
Michael
________________________
Michael Ljungberg, PhD, professor
Department of Medical Radiation Physics
Lund University
Barngatan 4
SE-221 85 Lund
Phone: +46 46 173565
Cellular: +46 708 173115
http://www.msf.lu.se<http://www.msf.lu.se/>
_______________________________________________
Gate-users mailing list
Gate-users at lists.opengatecollaboration.org
http://lists.opengatecollaboration.org/mailman/listinfo/gate-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20190618/14721f15/attachment.html>
More information about the Gate-users
mailing list