@@ -87,7 +87,7 @@ list_picam_resolution() {
87
87
local prefix
88
88
prefix=" $( date +' [%D %T]' ) crowsnest:"
89
89
log_msg " 'libcamera' device(s) resolution(s) :"
90
- while read -r i; do
90
+ while IFS= read -r i; do
91
91
printf " %s\t\t%s\n" " ${prefix} " " ${i} " >> " ${CROWSNEST_LOG_PATH} "
92
92
done < <( libcamera-hello --list-cameras | sed ' 1,2d;s/Modes:/Colorspace:/' )
93
93
}
@@ -101,8 +101,8 @@ get_libcamera_controls() {
101
101
sed ' s/device//g;/^SNAPSHOT/q' | sed ' /^SNAPSHOT/d' | \
102
102
sed ' /^CAMERA/d;/- property/d' | sed ' /camera-streamer Version:/d' | \
103
103
sed ' s/- available option: //g' | sed ' /^$/d;' | \
104
- sed ' s/([0-9]*[a-z,0-9]\,/ /g' | sed ' /type=7/d;/type=4/d' | \
105
- sed ' s/type=1/ ( bool/g;s/type=3/ ( int/g;s/type=5/ ( float/g' | \
104
+ sed ' s/([0-9]*[a-z,0-9]\, /( /g' | sed ' /type=7/d;/type=4/d;/type=Rectangle /d' | \
105
+ sed ' s/type=1/bool/g;s/type=3/int/g;s/type=5/float/g' | sed ' s/type=//g; ' | \
106
106
sed ' s/\[/min=/g;s/\.\./ max=/g;s/\]$//g'
107
107
else
108
108
log_msg " WARN: 'libcamera' device option can not be displayed, because"
@@ -114,7 +114,7 @@ list_picam_controls() {
114
114
local prefix
115
115
prefix=" $( date +' [%D %T]' ) crowsnest:"
116
116
log_msg " 'libcamera' device controls :"
117
- while read -r i; do
117
+ while IFS= read -r i; do
118
118
if [[ ! " ${i} " =~ " INFO" ]]; then
119
119
printf " %s\t\t%s\n" " ${prefix} " " ${i} " >> " ${CROWSNEST_LOG_PATH} "
120
120
fi
0 commit comments