Add a heatmap
Heatmap is an optional ArFrame pipeline step. It is executed at each new gaze position to update heatmap image.
Enable and display ArFrame heatmap
ArFrame.heatmap can be enabled with a dedicated JSON entry.
Here is an extract from the JSON ArFrame configuration file where heatmap is enabled and displayed:
{
"argaze.ArFeatures.ArFrame": {
"name": "My FullHD screen",
"size": [1920, 1080],
...
"heatmap": {
"size": [320, 180],
"sigma": 0.025,
"buffer": 0
},
...
"image_parameters": {
...
"heatmap_weight": 1
}
}
}
Note
ArFrame.heatmap is automatically updated each time the ArFrame.look method is called. As explained in visualization chapter, the resulting image is accessible with ArFrame.image method.
Now, let's understand the meaning of each JSON entry.
size
The heatmap image size in pixel. Higher size implies higher CPU load.
sigma
The gaussian point spreading to draw at each gaze position.
buffer
The size of point spread images buffer (0 means no buffering) to visualize only last N gaze positions.
heatmap_weight
The weight of heatmap overlay in ArFrame.image between 0 and 1.