Skip to content

Conversation

@agalasso
Copy link
Contributor

@agalasso agalasso commented Dec 22, 2025

GuideCamera::Capture CaptureParams argument

Update GuideCamera::Capture method replacing individual capture parameter arguments
with a struct wrapping all the capture parameters.

This will make it easier to transform the arguments for software binning #738.

No functional changes in this PR - just the arguments structure refactor.

@bwdev01
Copy link
Contributor

bwdev01 commented Dec 22, 2025

I'm missing something here. What is the benefit of pushing all these additional properties - gain, binning, bpp, etc - into the Capture() interface. Those things are already known to the underlying function because they are just properties of the camera. The new struct just looks to me like it has a bunch of tramp properties that, as a caller of Capture, I don't need to know about.

@agalasso
Copy link
Contributor Author

This change accomplishes two things:

  1. primarily: this makes it easier to transform the capture parameters for software binning. The capture params can be modified and passed along (this happens in the final pr of the series.) In that case we start with software-binned coordinates, transform to non-software binned camera coordinates in the call to the camera Capture instance method.
  2. secondary benefit: This will allow a cleaner implementation of the capture_single_frame server API which currently has to modify GuideCamera settings, call Capture, then restore the camera settings afterwards. The new implementation (not yet implemented) can leave GuideCamera settings as-is, and only pass along customized CaptureParams. Changing and restoring the camera settings is not ideal since the code has to make sure the settings get set back under all circumstances, and must ensure they do not change after capture_single_frame is called and before the frame capture completes.

Copy link
Contributor

@bwdev01 bwdev01 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

@agalasso agalasso force-pushed the andy/capture-params branch from 47b1933 to 915feae Compare December 24, 2025 17:58
@agalasso agalasso force-pushed the andy/camera-Binning-accessor-method branch from f2b0863 to 5f98640 Compare December 25, 2025 02:28
@agalasso agalasso force-pushed the andy/capture-params branch from 915feae to 501c4fd Compare December 25, 2025 02:28
@agalasso agalasso force-pushed the andy/camera-Binning-accessor-method branch from 5f98640 to 6c1e074 Compare December 31, 2025 22:07
Base automatically changed from andy/camera-Binning-accessor-method to master December 31, 2025 22:07
Update GuideCamera::Capture method replacing individual capture parameter arguments
with a struct wrapping all the capture parameters.

This will make it easier to transform the arguments for software binning.

No functional changes in this PR - just the arguments structure refactor.
@agalasso agalasso force-pushed the andy/capture-params branch from 501c4fd to c4c2f06 Compare December 31, 2025 22:07
@agalasso agalasso merged commit 78c0962 into master Dec 31, 2025
4 checks passed
@agalasso agalasso deleted the andy/capture-params branch December 31, 2025 22:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants