aboutsummaryrefslogtreecommitdiff
path: root/docs/user_guide/gaze_analysis_pipeline/background.md
diff options
context:
space:
mode:
authorThéo de la Hogue2023-09-04 14:49:27 +0200
committerThéo de la Hogue2023-09-04 14:49:27 +0200
commit01378ae467b6399a13042f02a67010dfc820aee2 (patch)
tree538522601eb3456035341b8e3284b11fc33abadf /docs/user_guide/gaze_analysis_pipeline/background.md
parenta1a189674d7ca0dbd5a5d84f3715084f41eec012 (diff)
downloadargaze-01378ae467b6399a13042f02a67010dfc820aee2.zip
argaze-01378ae467b6399a13042f02a67010dfc820aee2.tar.gz
argaze-01378ae467b6399a13042f02a67010dfc820aee2.tar.bz2
argaze-01378ae467b6399a13042f02a67010dfc820aee2.tar.xz
Moving scripting features into a dedicated advanced chapter.
Diffstat (limited to 'docs/user_guide/gaze_analysis_pipeline/background.md')
-rw-r--r--docs/user_guide/gaze_analysis_pipeline/background.md31
1 files changed, 7 insertions, 24 deletions
diff --git a/docs/user_guide/gaze_analysis_pipeline/background.md b/docs/user_guide/gaze_analysis_pipeline/background.md
index 420dbdf..a7d59f6 100644
--- a/docs/user_guide/gaze_analysis_pipeline/background.md
+++ b/docs/user_guide/gaze_analysis_pipeline/background.md
@@ -1,7 +1,7 @@
-Add Background
-==============
+Add a background
+================
-Background is an optional [ArFrame](../../argaze.md/#argaze.ArFeatures.ArFrame) attribute to display any image.
+Background is an optional [ArFrame](../../argaze.md/#argaze.ArFeatures.ArFrame) attribute to display any image behind pipeline visualisation.
![Background](../../img/ar_frame_background.png)
@@ -9,7 +9,7 @@ Background is an optional [ArFrame](../../argaze.md/#argaze.ArFeatures.ArFrame)
[ArFrame.background](../../argaze.md/#argaze.ArFeatures.ArFrame.background) can be enabled thanks to a dedicated JSON entry.
-Here is the JSON ArFrame configuration file example where a background picture is loaded and displayed:
+Here is an extract from the JSON ArFrame configuration file where a background picture is loaded and displayed:
```json
{
@@ -25,6 +25,9 @@ Here is the JSON ArFrame configuration file example where a background picture i
}
```
+!!! note
+ As explained in [visualisation chapter](visualisation.md), the resulting image is accessible thanks to [ArFrame.image](../../argaze.md/#argaze.ArFeatures.ArFrame.image) method.
+
Now, let's understand the meaning of each JSON entry.
### Background
@@ -34,23 +37,3 @@ The path to an image file on disk.
### Background weight
The weight of background overlay in [ArFrame.image](../../argaze.md/#argaze.ArFeatures.ArFrame.image) between 0 and 1.
-
-## Edit ArFrame background
-
-It is also possible to set background image and display it from script:
-
-```python
-import numpy
-
-# Assuming an ArFrame is loaded
-...
-
-# Set ArFrame background as gray
-ar_frame.background = numpy.full((ar_frame.size[1], ar_frame.size[0], 3), 127).astype(numpy.uint8)
-
-# Get ArFrame image with background and any other options
-ar_frame_image = ar_frame.image(background_weight = 1, ...)
-
-# Do something with ArFrame image
-...
-```