aboutsummaryrefslogtreecommitdiff
path: root/rro_overlays
diff options
context:
space:
mode:
authorAdarshGrewal <adarshgrewal@gmail.com>2022-03-09 17:42:05 -0300
committersinanmohd <pcmsinan@gmail.com>2023-01-05 21:30:23 +0530
commit4cf16bbd170fe1c837cc8eea5cda7c11bceebf21 (patch)
tree221ff913a8c32e30d6c226fba356323298493434 /rro_overlays
parent207dbbae90d1b2127cd24a86eb9dbe371e99a503 (diff)
veux: overlay: Configure camera cutout
Diffstat (limited to 'rro_overlays')
-rw-r--r--rro_overlays/FrameworksResOverlayVeux/res/values/config.xml64
1 files changed, 41 insertions, 23 deletions
diff --git a/rro_overlays/FrameworksResOverlayVeux/res/values/config.xml b/rro_overlays/FrameworksResOverlayVeux/res/values/config.xml
index 60ee329..2cd9842 100644
--- a/rro_overlays/FrameworksResOverlayVeux/res/values/config.xml
+++ b/rro_overlays/FrameworksResOverlayVeux/res/values/config.xml
@@ -408,31 +408,49 @@
<item>10</item>
</integer-array>
- <!-- The bounding path of the cutout region of the main built-in display.
- Must either be empty if there is no cutout region, or a string that is parsable by
- {@link android.util.PathParser}.
- The path is assumed to be specified in display coordinates with pixel units and in
- the display's native orientation, with the origin of the coordinate system at the
- center top of the display.
- To facilitate writing device-independent emulation overlays, the marker `@dp` can be
- appended after the path string to interpret coordinates in dp instead of px units.
- Note that a physical cutout should be configured in pixels for the best results.
- Example for a 10px x 10px square top-center cutout:
- <string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z</string>
- Example for a 10dp x 10dp square top-center cutout:
- <string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z @dp</string>
- @see https://www.w3.org/TR/SVG/paths.html#PathData
- -->
- <string name="config_mainBuiltInDisplayCutout">
- M 25,20
- h -50
- v 80
- h 50
+ <!--The bounding path of the cutout region of the main built-in display.
+ Must either be empty if there is no cutout region, or a string that is parsable by
+ {@link android.util.PathParser}.
+ The path is assumed to be specified in display coordinates with pixel units and in
+ the display's native orientation, with the origin of the coordinate system at the
+ center top of the display. Optionally, you can append either `@left` or `@right` to the
+ end of the path string, in order to change the path origin to either the top left,
+ To facilitate writing device-independent emulation overlays, the marker `@dp` can be
+ appended after the path string to interpret coordinates in dp instead of px units.
+ Note that a physical cutout should be configured in pixels for the best results.
+ Example for a 10px x 10px square top-center cutout:
+ <string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z</string>
+ Example for a 10dp x 10dp square top-center cutout:
+ <string ...>M -5,0 L -5,10 L 5,10 L 5,0 Z @dp</string>
+ @see https://www.w3.org/TR/SVG/paths.html#PathData
+ -->
+
+ <!-- The hole punch dimensions are this:
+ M -24 51.75 a 24 24 0 1 0 48 0 a 24 24 0 1 0 -48 0
+ but using a radius 24.5 circle to see the antialiasing.
+ -->
+ <string name="config_mainBuiltInDisplayCutout">M -24.5 51.75 a 24.5 24.5 0 1 0 49 0 a 24.5 24.5 0 1 0 -49 0 Z</string>
+
+ <!--Like config_mainBuiltInDisplayCutout, but this path is used to report the
+ one single bounding rect per device edge to the app via
+ {@link DisplayCutout#getBoundingRect}. Note that this path should try to match the visual
+ appearance of the cutout as much as possible, and may be smaller than
+ config_mainBuiltInDisplayCutout
+ -->
+ <string translatable="false" name="config_mainBuiltInDisplayCutoutRectApproximation">
+ M 0,0
+ H -33
+ V 93
+ H 33
+ V 0
+ H 0
Z
- </string>
+ </string>
- <!-- Whether device has a physical display cutout -->
- <bool name="config_physicalDisplayCutout">true</bool>
+ <!--Whether the display cutout region of the main built-in display should be forced to
+ black in software (to avoid aliasing or emulate a cutout that is not physically existent).
+ -->
+ <bool name="config_fillMainBuiltInDisplayCutout">true</bool>
<!-- The default refresh rate. veux manages this using the peak refresh rate setting, so set
this value to 0 so it has no effect. -->