wip: refactor came to use properties #453
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This is a DRAFT to show how the code base COULD be refactored to leverage properties and propose an API that might be more user friendly. This is clearly subjective and I might have missed some of the required changes but it would at least give a good idea of how to do things.
The main idea is that we:
Camera
into public classes.Note that the changes imply that:
_create()
where kernel information is automatically propagated;Photometric
I need aCamera
instance, to create aColor
I need aPhotometric
instance, ...Those changes are just a draft of what we could do and I didn't touch the
BaseSensor
orWavelengthsRange
which should also be updated.Do you see any limitations or side effects about the current changes ?
Issue linked
None
Checklist
feat: add optical property
)