B0371 16MPix imx519 real region of image vs. resolution

Hi,
when I change the resolution, the region of captured image is changed.
I expected that it was fixed and only resolution in pixels would change.
Why it is like that?
How can I determine real region?

Regards,
Piotr

@Piotr_Romaniuk

Maybe the picture below can answer your question :point_down:

Hi Edward,

Can you describe a formula or an algorithm that describes dependency between selected resolution and real capture region?
The function is not trivial. When I set up 640x480 I have the same region height as for 1280x720.

Regards,
Piotr Romaniuk

@Piotr_Romaniuk

I can make some explanations:
We will provide several resolutions, which we tuned through the sensor manual.

We generally do not recommend using resolutions other than this. If you use other resolutions, this part is actually libcamera made related tools, probably the principle is to crop or binned from a higher resolution. For details, you may have to look at the source code. I may not be able to explain the specific technical details at once.

Hi Edward,

I still don’t understand what is the relationship between resolution that I set up, true capturing region and hardware resolution.
Let’s take 640x480pix that I setup in python. In the log I see that 1280x720 is used.
Why this resolution is selected? What entity is responsible for this selection driver or libcamera2?
What region it will take from full scale image?

I need to obtain two features:

  1. to take small part (640x480) of the center of the image having the full resolution
  2. optimize selected mode in order to transfer no more data than it needs to be for [1]

Regards,
Piotr