Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ianohara committed Jan 20, 2025
1 parent 9148e80 commit 166ae9b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion software/squid/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ def _old_camera_type_to_enum(old_string) -> CameraType:
return CameraType.IDS
raise ValueError(f"Unknown old camera type {old_string=}")


class CameraPixelFormat(enum.Enum):
"""
This is all known Pixel Formats in the Cephla world, but not all cameras will support
Expand All @@ -179,6 +180,7 @@ class CameraPixelFormat(enum.Enum):
RGB32 = "RGB32"
RGB48 = "RGB48"


class CameraConfig(pydantic.BaseModel):
"""
Most camera parameters are runtime configurable, so CameraConfig is more about defining what
Expand All @@ -195,10 +197,11 @@ class CameraConfig(pydantic.BaseModel):

default_pixel_format: CameraPixelFormat


_camera_config = CameraConfig(
camera_type=_old_camera_type_to_enum(_def.CAMERA_TYPE),
default_resolution=(_def.Acquisition.CROP_WIDTH, _def.Acquisition.CROP_HEIGHT),
default_pixel_format=(_def.DEFAULT_PIXEL_FORMAT)
default_pixel_format=(_def.DEFAULT_PIXEL_FORMAT),
)


Expand Down

0 comments on commit 166ae9b

Please sign in to comment.