set pixel format in camera settings
This commit is contained in:
+3
-4
@@ -98,8 +98,8 @@ if __name__ == '__main__':
|
||||
print(f"{item}: Not implemented")
|
||||
|
||||
# Config
|
||||
camera_config = picam2.create_preview_configuration({'size': picam2.sensor_modes[0]['size']})
|
||||
camera_config = picam2.create_preview_configuration({'size': (800, 600)})
|
||||
camera_config = picam2.create_preview_configuration({'format': 'XRGB8888', 'size': picam2.sensor_modes[0]['size']})
|
||||
camera_config = picam2.create_preview_configuration({'format': 'XRGB8888', 'size': (800, 600)})
|
||||
picam2.configure(camera_config)
|
||||
|
||||
|
||||
@@ -121,8 +121,7 @@ if __name__ == '__main__':
|
||||
# Start timer
|
||||
timer = cv2.getTickCount()
|
||||
|
||||
rgb = picam2.capture_array("main")
|
||||
frame = cv2.cvtColor(rgb, cv2.COLOR_RGB2BGR)
|
||||
frame = picam2.capture_array("main")
|
||||
|
||||
# Process the frame using OpenCV operations
|
||||
cv2.imshow('Frame', frame)
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"NoiseReductionMode": 0,
|
||||
"AeExposureMode": 0,
|
||||
"ExposureTime": 13929,
|
||||
"ExposureTime": 75030,
|
||||
"AnalogueGain": 1.0,
|
||||
"FrameRate": 60.38
|
||||
"FrameRate": 10.580000000000002
|
||||
}
|
||||
Reference in New Issue
Block a user