Notes on using xrtGlow¶


Examine a few examples in …/examples/withRaycing/_QookBeamlines.
Export to image is available under the context menu -> File. You can save and load the scene settings (camera position, model orientation, rays opacity and so on) as well.
From xrtGlow, press F1 to see the available keyboard shortcuts. Also observe the available pop-up menu by right mouse click.
Move the model across the view with Shift-MouseLeft, or along view depth with Alt-MouseLeft. Horizontal dragging has no effect. From above, drag up to move the model away from the camera or down to bring it closer. From below, these directions reverse. At zero elevation, up brings it closer. Centering can be done by (a) right click on the element name in Selection and then “Center here” or (b) right click on the element itself in the scene and then “Center view”.
The color plot shows the global color map: the correspondence between the selected physical parameter (e.g. energy) and the colors. A sub-band can be selected on the color plot with the mouse; the vertical extent of this selection is ignored. If Global color span is disabled, each beam’s colors are normalized to that beam’s local minimum and maximum. This is useful for inspecting local height profiles. In this mode, the global color map and global color-span controls are disabled.
Examine dynamic properties of an optical elements or a screen by right-clicking it. The plot in the inspectror panel shows a local footprint or a screen view.
Virtual Screen is instantiated by F3 nearly at the view center. It can be moved along the beamline by Ctrl-MouseLeft drag.
Rays or footprints visualisation can be enabled/disabled either by setting corresponding checkboxes in the Navigation Panel for individual elements or globally by changing the opacity of the lines and points in the Color Panel. The same applies for the Projections.
Intensity cut-off allows to omit the visualisation of the darkest/weakest rays. It is especially important if Intensity defines the Value key in HSV color space when dark rays can shadow the whole beam.
A convenient way to inspect a detailed beam footprint on the coordinate grid is to use Projections: disable the Perspective, select only the footprint of interest on the Navigation Panel (or disable all and just leave the Virtual Screen on), enable the projection, set to zero the Projection Line Opacity, increase the Projection Point Opacity to improve the visibility, enable the Fine Grid. Increase the number of rays in the source if necessary.
If you have any doubts regarding the orientation of the optical element or trying to identify the directions, you can plot local coordinate axes by checking the corresponding option on the Scene panel or in the context menu. Make sure that the surface rendering is enabled for this element in the Navigation panel. Orientation of the diffraction planes will be represented by the yellow arrow in case of crystals with asymmetric cut.


A powerful exploration feature is the alignment of any chosen beamline propagation leg with the global Y direction. This enables (a) independent zooming along the global axes, (b) disentangled side-view projections, and (c) color-coding based on positional (x, z) or angular (x′, z′) coordinates.
Depth test is disabled by default for Points. Enable it if you do not want the footprints to shine through solid surfaces of optical elements. Be aware that Points may be obscured by Lines (rays) in this case.
Antialiasing can improve the visual quality of the scene, but it seriously affects the performance (depending on the number of rays / elements in the model), only enable it after all modifications to the scene are applied, prior the Export to file. Nevertheless antialiasing is always enabled for the coordinate grid.
Default Zoom does not involve the coordinate grid, if you want to Zoom In/Out the whole scene, use Ctrl-MouseWheel.
You can scan the scene properties such as scale or camera position, and properties of beamline elements like target energy of a crystal or monochromator, mirror position/orientation, slit opening etc. Scans tracks can be added to the table in the Scan Control widget by selecting a property from the tree and providing starting and ending points and a span in frames. Multiple tracks can span over independent or overlapping frame intervals supporting multi-parametric scans. The scans can be “played” immediately in xrtGlow, exported as JSON configuration, or included in an auto-generated script by selecting the glow_scan option under “Job Settings – generator”. For a provided filename template, the scan started in xrtGlow will save the 3D scene for every frame, script-based scans will instead save every plot in the list of plots under a name composed of the plot title and scan filename template.
Not only can a scan produce scene animations, it can also generate signal plots similar to alignment scans at a beamline. To create such a plot, use the “Create Scan” command from the context menu of a property in the main xrtQook tree or in a live object inspector in xrtGlow. In the scan dialog, click “Add target”, select a beam from the list of local and global beams and choose a beam property, most commonly “intensity”.
The following example demonstrates how to create a rocking curve from the Balder.xml project.









