Hi there,
I am trying to set the resolution for the final video file through VideoCapture, the code is:
mVideoCapture = new VideoCapture.Builder()
.setTargetResolution(new Size(1920, 1080))
.build();
But the resolution I got is 1088 * 1088, and when I put break point at void setupEncoder(@NonNull String cameraId, @NonNull Size resolution), I found the suggest resolution is 1088 * 1088 (BTW, it is the same for the ImageCapture).
However, if I set the aspect ratio instead of setting target resolution like:
mVideoCapture = new VideoCapture.Builder()
.setTargetAspectRatio(AspectRatio.RATIO_16_9)
.build();
The resolution can be 1920 * 1080, so I wonder why the suggest resolution or the final resolution is not we set, and why VideoCapture not using target resolution to setup encoder?