The image below illustrates the problem:
The problem is probably caused because you're using the sample transformations which don't work in some configurations. SAFR SDK returns face coordinates based on the input frame resolution, but how the frame is rendered is completely up to the client app.
To resolve this problem, you need to implement 2 things:
- CameraSourcePreview - Displays the frame and also corrects the aspect ratio so the image doesn't look skewed. It stores any transformations that have been applied in the process. (i.e. scale factor & offsets which may depend on whether the frame is displayed aspect-fill or aspect-fit.)
- GraphicOverlay - Applies the transformations (i.e. scale factor & offsets) from the CameraSourcePreview when rendering overlays.